Embed a flash .swf file?

BlitzMax Forums/BlitzMax Programming/Embed a flash .swf file?

MGE(Posted 2009) [#1]
Anyone know if it's possible to embed a flash program (.swf) directly in a blitzmax app? Thx.


plash(Posted 2009) [#2]
I believe there are libraries that could allow such a thing, but none have been wrapped (afaik).


Czar Flavius(Posted 2009) [#3]
Quick, turn on the Brucey Sign!




ImaginaryHuman(Posted 2009) [#4]
I think brucey or someone already did it


theHand(Posted 2009) [#5]
There's GTK+Gnash, not much else.


popcade(Posted 2009) [#6]
I requested Brucey for GameSWF wrapper before but Brucey is too busy to do that, the library url is:

http://tulrich.com/geekstuff/gameswf.html

The library itself has stopped maintenance for a long time, but seems enough for game UI or simple animation.


markcw(Posted 2009) [#7]
What use do you have for this? Maybe you could use the htmlview (except on Fltk linux).


theHand(Posted 2009) [#8]
Oh, who knows, Mark. I think that Max2D would be orders of magnitude faster.
There are the BaH.Cairo, BaH.LibSVG BaH.LibXML, and BaH.LibXSLT modules Brucey made for that can be used to work with vector graphics (SVGs or PDFs), which would be much easier to work with(in the long run (and it would be smaller overall, storing SVG files separately)). And there is BaH.GTKWebMozilla to fall back on, so, technically, you can embed a flash .swf file (as an isolated "graphic"), but you get more power and control if you work with SVGs, as mentioned before. SVGs can also be animated. Only SVG-standard-compliant viewers will correctly show the animation here (one of them being Opera).
The person who made the animated SVGs at design-ireland.net did use SMIL to do so.

@CyBeRGoth
Yeah, include, or maybe engraft would be a better word. "Link into" sounds most appropriate to me, as engraft kind of implies that Flash will eventually be a part of BlitzMax.


slenkar(Posted 2009) [#9]
yeah why would you want to embed flash into bmax


CyBeRGoth(Posted 2009) [#10]
"yeah why would you want to embed flash into bmax"

Various reasons, cut scenes (world of goo's cutscenes are done in flash), creating a vector based game (loco roco etc).

I am not sure if embedding is the correct word to use though, as that implies that you make the game in flash and just want to play it in blitzmax, I think intergrating max and flash would be better, but then again with the work involved in doing that you could probably create a full working vector based engine in the same time.


Brucey(Posted 2009) [#11]
Given that the swf spec is now public, there's nothing stopping one of you writing your own compatible renderer :-)

There's a small BlitzMax SVG viewer tech-demo here - talking of svg... (built on top of Qt, rather than Cairo).


slenkar(Posted 2009) [#12]
embedding blitz into flash would be useful