search for: swfblock

Displaying 19 results from an estimated 19 matches for "swfblock".

Did you mean: subblock
2007 Jul 12
0
Branch 'as' - 6 commits - libswfdec/swfdec_as_interpret.c libswfdec/swfdec_movie.c libswfdec/swfdec_sprite_movie_as.c test/trace
...+{ + SWFMovie movie; + SWFMovieClip clip; + SWFDisplayItem item; + char name[100]; + + movie = newSWFMovieWithVersion (version); + movie = newSWFMovie(); + SWFMovie_setRate (movie, 1); + SWFMovie_setDimension (movie, 200, 150); + + clip = newSWFMovieClip (); + item = SWFMovie_add (movie, (SWFBlock) clip); + SWFDisplayItem_setName (item, "movie"); + SWFDisplayItem_addAction (item, newSWFAction ("trace (this + \": init\");"), SWFACTION_INIT); + SWFDisplayItem_addAction (item, newSWFAction ("trace (this + \": construct\");"), SWFACTION_CONSTR...
2007 Nov 20
0
7 commits - libswfdec/swfdec_movie.c libswfdec/swfdec_sprite_movie_as.c test/image
...ge/clip-change.c new file mode 100644 index 0000000..9e7da16 --- /dev/null +++ b/test/image/clip-change.c @@ -0,0 +1,75 @@ +/* gcc `pkg-config --libs --cflags libming` clip-change.c -o clip-change && ./clip-change + */ + +#include <ming.h> + +static SWFBlock +get_rectangle (int r, int g, int b) +{ + SWFShape shape; + SWFFillStyle fill; + + shape = newSWFShape (); + fill = SWFShape_addSolidFillStyle (shape, r, g, b, 255); + SWFShape_setRightFillStyle (shape, fill); + SWFShape_drawLineTo (shape, 100, 0); + SWFShape_drawLineTo (shape, 100, 100); +...
2007 Oct 25
0
6 commits - libswfdec/swfdec_as_interpret.c libswfdec/swfdec_movie.c test/trace
...{ + SWFMovie movie; + SWFMovieClip clip; + SWFDisplayItem item; + char *real_name; + + movie = newSWFMovieWithVersion (version); + movie = newSWFMovie(); + SWFMovie_setRate (movie, 1); + SWFMovie_setDimension (movie, 200, 150); + + clip = newSWFMovieClip (); + item = SWFMovie_add (movie, (SWFBlock) clip); + SWFMovieClip_addInitAction (clip, newSWFAction ("_root.x = 42;")); + SWFDisplayItem_addAction (item, newSWFAction ("trace (_root.x);"), SWFACTION_INIT); + SWFDisplayItem_addAction (item, newSWFAction ("trace (_root.x);"), SWFACTION_CONSTRUCT); + SWFDispla...
2007 Mar 20
0
4 commits - libswfdec/swfdec_flv_decoder.c libswfdec/swfdec_flv_decoder.h libswfdec/swfdec_movie.c test/trace
...main (int argc, char **argv) +{ + SWFMovie movie; + SWFMovieClip parent, child; + SWFDisplayItem item; + + if (Ming_init ()) + return 1; + Ming_useSWFVersion (7); + + movie = newSWFMovie(); + SWFMovie_setRate (movie, 1); + SWFMovie_setDimension (movie, 200, 150); + SWFMovie_add (movie, (SWFBlock) compileSWFActionCode ("" + " trace (\"Check that the parent onLoad event happens before the child's onLoad\");" + "")); + parent = newSWFMovieClip (); + child = newSWFMovieClip (); + item = SWFMovieClip_add (parent, (SWFBlock) child); + SW...
2007 Oct 29
0
2 commits - libswfdec/swfdec_audio_event.c test/sound
...file = fopen ("/dev/null", "r"); + sound = newSWFSound (file, SWF_SOUND_NOT_COMPRESSED | SWF_SOUND_44KHZ | SWF_SOUND_16BITS | SWF_SOUND_STEREO); + instance = SWFMovieClip_startSound(movie_clip, sound); + SWFMovieClip_nextFrame (movie_clip); + + SWFMovie_add (movie, (SWFBlock) movie_clip); + SWFMovie_nextFrame (movie); + + SWFMovie_add (movie, (SWFBlock) newSWFAction ("" + "trace ('To crash or not to crash?');" + "function quit () {" + " loadMovie ('FSCommand:quit', '');" + "}" + "setTimeo...
2007 Oct 28
1
test/trace
...char name[100]; + SWFMovie movie; + SWFTextField text; + SWFDisplayItem display; + + movie = newSWFMovieWithVersion (version); + movie = newSWFMovie(); + SWFMovie_setRate (movie, 1); + SWFMovie_setDimension (movie, 200, 150); + + text = newSWFTextField (); + display = SWFMovie_add (movie, (SWFBlock) text); + + SWFMovie_add (movie, (SWFBlock) newSWFAction ("" + "trace ('Test whether native properties of TextField are initialized if the movie contains an EditText tag');" + "_global.TextField.prototype.hasOwnProperty = ASnative (101, 5);" + "trace (_gl...
2007 Jun 20
0
Branch 'as' - 5 commits - libswfdec/swfdec_graphic_movie.c libswfdec/swfdec_movie.c libswfdec/swfdec_sprite_movie.c test/image
...e (shape, r, g, b, 255); + SWFShape_setRightFillStyle (shape, fill); + SWFShape_drawLineTo (shape, 50, 0); + SWFShape_drawLineTo (shape, 50, 50); + SWFShape_drawLineTo (shape, 0, 50); + SWFShape_drawLineTo (shape, 0, 0); + + switch (type) { + case SHAPE: + item = SWFMovie_add (movie, (SWFBlock) shape); + break; + case MOVIE: + { + SWFMovieClip clip; + clip = newSWFMovieClip (); + SWFMovieClip_add (clip, (SWFBlock) shape); + SWFMovieClip_nextFrame (clip); + item = SWFMovie_add (movie, (SWFBlock) clip); + } + break; + case BUTTON: + { + SWFButton button; + bu...
2007 Oct 28
1
2 commits - libswfdec/swfdec_as_interpret.c test/trace
libswfdec/swfdec_as_interpret.c | 1 + test/trace/Makefile.am | 3 +++ test/trace/crash-0.5.3-divide-by-zero.as | 5 +++++ test/trace/crash-0.5.3-divide-by-zero.swf |binary test/trace/crash-0.5.3-divide-by-zero.swf.trace | 1 + 5 files changed, 10 insertions(+) New commits: commit
2007 Nov 14
0
5 commits - libswfdec/.gitignore libswfdec/swfdec_initialize.as test/image test/sound test/trace
...--git a/test/sound/crash-0.5.3-no-samples.c b/test/sound/crash-0.5.3-no-samples.c index 4339f03..30c0e34 100644 --- a/test/sound/crash-0.5.3-no-samples.c +++ b/test/sound/crash-0.5.3-no-samples.c @@ -28,15 +28,6 @@ do_movie () SWFMovie_add (movie, (SWFBlock) movie_clip); SWFMovie_nextFrame (movie); - SWFMovie_add (movie, (SWFBlock) newSWFAction ("" - "trace ('To crash or not to crash?');" - "function quit () {" - " loadMovie ('FSCommand:quit', '');" - "}" - "setTimeo...
2007 Jun 18
0
Branch 'as' - 8 commits - libswfdec/swfdec_movie.c libswfdec/swfdec_sprite.c libswfdec/swfdec_sprite.h libswfdec/swfdec_sprite_movie.c libswfdec/swfdec_sprite_movie.h libswfdec/swfdec_swf_decoder.c libswfdec/swfdec_swf_decoder.h
...hape (); + fill = SWFShape_addSolidFillStyle (shape, r, g, b, 255); + SWFShape_setRightFillStyle (shape, fill); + SWFShape_drawLineTo (shape, 50, 0); + SWFShape_drawLineTo (shape, 50, 50); + SWFShape_drawLineTo (shape, 0, 50); + SWFShape_drawLineTo (shape, 0, 0); + + SWFMovieClip_add (clip, (SWFBlock) shape); +} + +static void +modify_placement (SWFMovie movie, guint mod) +{ + SWFDisplayItem item; + SWFBlock clip, clip2; + + clip = (SWFBlock) newSWFMovieClip (); + add_rectangle ((SWFMovieClip) clip, 255, 0, 0); + SWFMovieClip_nextFrame ((SWFMovieClip) clip); + clip2 = (SWFBlock) newSWFMov...
2007 Mar 22
0
11 commits - libswfdec/swfdec_color.c libswfdec/swfdec_flv_decoder.c libswfdec/swfdec_js_net_stream.c libswfdec/swfdec_movie.c libswfdec/swfdec_net_stream.c libswfdec/swfdec_net_stream.h libswfdec/swfdec_pattern.c libswfdec/swfdec_script.c NEWS test/trace
...{ + SWFMovie movie; + SWFMovieClip clip; + SWFDisplayItem item; + + if (Ming_init ()) + return 1; + Ming_useSWFVersion (7); + + movie = newSWFMovie(); + SWFMovie_setRate (movie, 1); + SWFMovie_setDimension (movie, 200, 150); + + clip = newSWFMovieClip (); + item = SWFMovie_add (movie, (SWFBlock) clip); + SWFDisplayItem_setName (item, "m"); + SWFDisplayItem_addAction (item, compileSWFActionCode ("" + " trace (\"clipEvent (load)\");" + " trace (this);" + ""), SWFACTION_ONLOAD); + SWFMovie_add (movie, (SWFBlock)...
2007 Mar 16
0
4 commits - libswfdec/swfdec_script.c test/image test/trace
...seSWFVersion (7); + + movie = newSWFMovie(); + SWFMovie_setRate (movie, 1); + SWFMovie_setDimension (movie, 10, 10); + + image = newSWFJpegBitmap (fopen ("bw.jpg", "r+")); + shape = newSWFShapeFromBitmap ((SWFBitmap) image, SWFFILL_BITMAP); + + item = SWFMovie_add (movie, (SWFBlock) shape); + SWFDisplayItem_setCXform (item, newSWFCXform (100, 0, 0, 0, -90./256, 1.0, 1.0, 1.0)); + SWFMovie_nextFrame (movie); + + SWFMovie_save (movie, "negative-color-transform.swf"); + return 0; +} diff --git a/test/image/negative-color-transform.swf b/test/...
2007 Mar 14
0
10 commits - libswfdec/swfdec_flv_decoder.c libswfdec/swfdec_flv_decoder.h libswfdec/swfdec_js_global.c libswfdec/swfdec_js_movie.c libswfdec/swfdec_js_net_stream.c libswfdec/swfdec_loader.c libswfdec/swfdec_loader.h libswfdec/swfdec_loadertarget.c
...FAction action; + + if (Ming_init ()) + return 1; + Ming_useSWFVersion (7); + + movie = newSWFMovie(); + SWFMovie_setRate (movie, 1); + SWFMovie_setDimension (movie, 200, 150); + video = newSWFVideoStream (); + SWFVideoStream_setDimension (video, 200, 150); + item = SWFMovie_add (movie, (SWFBlock) video); + SWFDisplayItem_setName (item, "video"); + action = compileSWFActionCode ("" + "trace (\"Test what onStatus messages exist in an average movie.\");" + "nc = new NetConnection ();" + "nc.connect (null);" + &q...
2007 Jun 19
0
Branch 'as' - 4 commits - libswfdec/swfdec_codec_video.c libswfdec/swfdec_movie.c test/trace
...quot; + this);"), SWFACTION_ONLOAD); + SWFDisplayItem_addAction (item, newSWFAction ("trace (_root._currentframe + \": unload \" + this);"), SWFACTION_UNLOAD); +} + +static char * +modify_placement (SWFMovie movie, guint mod) +{ + GString *name; + SWFDisplayItem item; + SWFBlock clip1, clip2; + + name = g_string_new ("place-object"); + if (mod & MODIFY_REMOVE) + g_string_append (name, "-remove"); + clip1 = (SWFBlock) newSWFMovieClip (); + if (mod & MODIFY_DIFFERENT_CHAR) { + if (mod & MODIFY_HAS_CHAR) { + clip2 = (SWFBlock) ne...
2007 Aug 02
0
10 commits - libswfdec/compiler.c libswfdec-gtk/swfdec_source.c libswfdec/Makefile.am libswfdec/swfdec_player.c NEWS test/trace
...ize_t len; + byte *data; if (argc < 2) { g_print ("usage: %s FILE ...\n\n", argv[0]); @@ -118,23 +79,14 @@ main (int argc, char **argv) error = NULL; return 1; } - movie = newSWFMovie (); action = newSWFAction (contents); - SWFMovie_add (movie, (SWFBlock) action); - g_free (contents); - - array = g_byte_array_new (); - SWFMovie_output (movie, output_array, array); + data = SWFAction_getByteCode (action, &len); contents = get_name (argv[i]); g_print ("/* compiled from %s */\n", argv[i]); g_print (&quo...
2007 Nov 20
0
19 commits - libswfdec/swfdec_audio_event.c libswfdec/swfdec_bits.c libswfdec/swfdec_color.c libswfdec/swfdec_color.h libswfdec/swfdec_flv_decoder.c libswfdec/swfdec_image.c libswfdec/swfdec_initialize.as libswfdec/swfdec_initialize.h
...g` mask-and-clip.c -o mask-and-clip && ./mask-and-clip + */ + +#include <ming.h> + +enum { + FIRST_MOVIE_CLIP_ALL, + SECOND_MOVIE_CLIP_ALL, + THIRD_MOVIE_SWAP_DEPTH, + THIRD_MOVIE_MASK, + N_FLAGS +}; +#define FLAG_SET(var, flag) ((var) & (1 << (flag))) + +static SWFBlock +get_rectangle (int r, int g, int b) +{ + SWFMovieClip clip; + SWFShape shape; + SWFFillStyle fill; + + clip = newSWFMovieClip (); + shape = newSWFShape (); + fill = SWFShape_addSolidFillStyle (shape, r, g, b, 255); + SWFShape_setRightFillStyle (shape, fill); + SWFShape_drawLineTo (shape, 1...
2007 Jul 26
0
17 commits - doc/swfdec-sections.txt libswfdec/compiler.c libswfdec/.gitignore libswfdec/Makefile.am libswfdec/swfdec_asbroadcaster.c libswfdec/swfdec_as_context.c libswfdec/swfdec_as_object.c libswfdec/swfdec_as_object.h libswfdec/swfdec_as_strings.c
...if (!g_file_get_contents (argv[1], &contents, NULL, &error)) { + g_printerr ("%s\n", error->message); + g_error_free (error); + error = NULL; + return 1; + } + movie = newSWFMovie (); + action = newSWFAction (contents); + SWFMovie_add (movie, (SWFBlock) action); + g_free (contents); + + array = g_byte_array_new (); + SWFMovie_output (movie, output_array, array); + contents = get_name (argv[i]); + g_print ("/* compiled from %s */\n", argv[i]); + g_print ("const unsigned char %s[] = {\n", contents); +...
2008 Jan 08
0
9 commits - configure.ac test/custom test/Makefile.am test/swfdec_test_initialize.as test/swfdec_test_initialize.h test/swfdec_test_test.c test/trace
...; + this);", button_events[i]); + SWFButton_addAction (button, newSWFAction (script), (1 << i)); + } +} + +static SWFCharacter +get_clip_events_movie (const char *name) +{ + SWFMovieClip clip; + SWFDisplayItem item; + + clip = newSWFMovieClip (); + item = SWFMovieClip_add (clip, (SWFBlock) newSWFMovieClip ()); + SWFDisplayItem_addAction (item, newSWFAction ("trace (\"load \" + this);"), SWFACTION_ONLOAD); + SWFDisplayItem_addAction (item, newSWFAction ("trace (\"unload \" + this);"), SWFACTION_UNLOAD); + SWFDisplayItem_setName (item, name);...
2007 Nov 28
0
59 commits - libswfdec-gtk/swfdec_gtk_widget.c libswfdec/swfdec_as_object.c libswfdec/swfdec_as_object.h libswfdec/swfdec_button.c libswfdec/swfdec_button.h libswfdec/swfdec_button_movie.c libswfdec/swfdec_button_movie.h libswfdec/swfdec_event.c
...; + this);", button_events[i]); + SWFButton_addAction (button, newSWFAction (script), (1 << i)); + } +} + +static SWFCharacter +get_clip_events_movie (const char *name) +{ + SWFMovieClip clip; + SWFDisplayItem item; + + clip = newSWFMovieClip (); + item = SWFMovieClip_add (clip, (SWFBlock) newSWFMovieClip ()); + SWFDisplayItem_addAction (item, newSWFAction ("trace (\"load \" + this);"), SWFACTION_ONLOAD); + SWFDisplayItem_addAction (item, newSWFAction ("trace (\"unload \" + this);"), SWFACTION_UNLOAD); + SWFDisplayItem_setName (item, name);...