Displaying 13 results from an estimated 13 matches for "init_action".
2007 Jun 06
0
Branch 'as' - libswfdec/Makefile.am libswfdec/swfdec_root_movie.c libswfdec/swfdec_root_sprite.c libswfdec/swfdec_root_sprite.h libswfdec/swfdec_swf_decoder.c libswfdec/swfdec_swf_decoder.h libswfdec/swfdec_tag.c
...EC_LOG ("exporting %s %u as %s", G_OBJECT_TYPE_NAME (object), id, name);
- g_object_ref (object);
- swfdec_root_sprite_add_root_action (SWFDEC_ROOT_SPRITE (s->main_sprite),
- SWFDEC_ROOT_ACTION_EXPORT, data);
- }
- }
-
- return SWFDEC_STATUS_OK;
-}
-
-int
-tag_func_do_init_action (SwfdecSwfDecoder * s)
-{
- SwfdecBits *bits = &s->b;
- guint id;
- SwfdecSprite *sprite;
- char *name;
-
- id = swfdec_bits_get_u16 (bits);
- SWFDEC_LOG (" id = %u", id);
- sprite = swfdec_swf_decoder_get_character (s, id);
- if (!SWFDEC_IS_SPRITE (sprite)) {
- SWFDEC_...
2007 Mar 09
0
libswfdec/swfdec_root_sprite.c libswfdec/swfdec_root_sprite.h
...EC_LOG ("exporting %s %u as %s", G_OBJECT_TYPE_NAME (object), id, name);
+ g_object_ref (object);
+ swfdec_root_sprite_add_root_action (SWFDEC_ROOT_SPRITE (s->main_sprite),
+ SWFDEC_ROOT_ACTION_EXPORT, data);
+ }
+ }
+
+ return SWFDEC_STATUS_OK;
+}
+
+int
+tag_func_do_init_action (SwfdecSwfDecoder * s)
+{
+ SwfdecBits *bits = &s->b;
+ guint id;
+ SwfdecSprite *sprite;
+
+ id = swfdec_bits_get_u16 (bits);
+ SWFDEC_LOG (" id = %u", id);
+ sprite = swfdec_swf_decoder_get_character (s, id);
+ if (!SWFDEC_IS_SPRITE (sprite)) {
+ SWFDEC_ERROR ("ch...
2007 Oct 25
0
6 commits - libswfdec/swfdec_as_interpret.c libswfdec/swfdec_event.c libswfdec/swfdec_event.h libswfdec/swfdec_movie.c libswfdec/swfdec_movie.h libswfdec/swfdec_player.c libswfdec/swfdec_player_internal.h libswfdec/swfdec_resource.c
...g_print ("exporting %s %u as %s\n", G_OBJECT_TYPE_NAME (object), id, name);
g_object_ref (object);
swfdec_resource_add_export (resource, object, name);
}
@@ -397,7 +396,6 @@ swfdec_sprite_movie_perform_one_action (SwfdecSpriteMovie *movie, guint tag, Swf
sprite->init_action = swfdec_script_new_from_bits (&bits, name, SWFDEC_AS_CONTEXT (player)->version);
g_free (name);
if (sprite->init_action) {
- g_print ("Executing init action for sprite %u\n", id);
swfdec_player_add_action_script (player, mov, sprite->init_action, 0);
}
}
c...
2007 Mar 05
0
11 commits - configure.ac libswfdec/swfdec_js_movie.c libswfdec/swfdec_root_movie.c libswfdec/swfdec_root_movie.h libswfdec/swfdec_script.c libswfdec/swfdec_sprite.c libswfdec/swfdec_sprite.h libswfdec/swfdec_sprite_movie.c libswfdec/swfdec_swf_decoder.c
...4
--- a/libswfdec/swfdec_sprite_movie.c
+++ b/libswfdec/swfdec_sprite_movie.c
@@ -32,6 +32,38 @@
#include "swfdec_script.h"
#include "swfdec_sprite.h"
+/*** SWFDEC_SPRITE_INFO ***/
+
+typedef struct _SwfdecSpriteInfo SwfdecSpriteInfo;
+struct _SwfdecSpriteInfo {
+ gboolean init_action_has_run; /* TRUE if init actions have been run */
+};
+
+static void
+swfdec_sprite_info_free (gpointer infop)
+{
+ SwfdecSpriteInfo *info = infop;
+
+ g_free (info);
+}
+
+static SwfdecSpriteInfo *
+swfdec_sprite_info_get (SwfdecMovie *movie, SwfdecSprite *sprite)
+{
+ SwfdecRootMovie *root =...
2007 Aug 09
0
Branch 'vivi' - 12 commits - libswfdec-gtk/swfdec_gtk_player.c libswfdec-gtk/swfdec_gtk_player.h libswfdec/Makefile.am libswfdec/swfdec_as_array.h libswfdec/swfdec_as_context.c libswfdec/swfdec_as_context.h libswfdec/swfdec_as_debugger.c
...;swfdec_pattern.h"
#include "swfdec_player_internal.h"
-#include "swfdec_script.h"
+#include "swfdec_script_internal.h"
#include "swfdec_shape.h"
#include "swfdec_sound.h"
#include "swfdec_sprite.h"
@@ -545,7 +545,7 @@ tag_func_do_init_action (SwfdecSwfDecode
return SWFDEC_STATUS_OK;
}
name = g_strdup_printf ("InitAction %u", id);
- sprite->init_action = swfdec_script_new (bits, name, s->version);
+ sprite->init_action = swfdec_script_new_from_bits (bits, name, s->version);
g_free (name);
if (spr...
2007 Mar 07
0
13 commits - libswfdec/Makefile.am libswfdec/swfdec_js_global.c libswfdec/swfdec_js_movie.c libswfdec/swfdec_root_movie.c libswfdec/swfdec_root_movie.h libswfdec/swfdec_script.c libswfdec/swfdec_sprite.h libswfdec/swfdec_sprite_movie.c
...4
--- a/libswfdec/swfdec_sprite_movie.c
+++ b/libswfdec/swfdec_sprite_movie.c
@@ -32,36 +32,6 @@
#include "swfdec_script.h"
#include "swfdec_sprite.h"
-/*** SWFDEC_SPRITE_INFO ***/
-
-typedef struct _SwfdecSpriteInfo SwfdecSpriteInfo;
-struct _SwfdecSpriteInfo {
- gboolean init_action_has_run; /* TRUE if init actions have been run */
-};
-
-static void
-swfdec_sprite_info_free (gpointer infop)
-{
- SwfdecSpriteInfo *info = infop;
-
- g_free (info);
-}
-
-static SwfdecSpriteInfo *
-swfdec_sprite_info_get (SwfdecMovie *movie, SwfdecSprite *sprite)
-{
- SwfdecRootMovie *root =...
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
...t; sprite->actions->len; i++) {
+ SwfdecSpriteAction *cur = &g_array_index (sprite->actions, SwfdecSpriteAction, i);
+ if (cur->buffer)
+ swfdec_buffer_unref (cur->buffer);
+ }
+ g_array_free (sprite->actions, TRUE);
+ sprite->actions = NULL;
if (sprite->init_action) {
swfdec_script_unref (sprite->init_action);
sprite->init_action = NULL;
@@ -118,62 +104,31 @@ swfdec_sprite_add_sound_chunk (SwfdecSpr
SWFDEC_AUDIO_OUT_GRANULARITY (sprite->frames[frame].sound_head->original_format);
}
-static void
-swfdec_sprite_remove_last_action (...
2007 Mar 12
0
11 commits - libswfdec/js libswfdec/swfdec_loader.c libswfdec/swfdec_root_sprite.c libswfdec/swfdec_script.c player/swfdebug.c player/swfdec_player_manager.c test/trace
...13 00:03:07 2007 +0100
put the sprite id of the init action into the script name
diff --git a/libswfdec/swfdec_root_sprite.c b/libswfdec/swfdec_root_sprite.c
index e8e868b..1b41237 100644
--- a/libswfdec/swfdec_root_sprite.c
+++ b/libswfdec/swfdec_root_sprite.c
@@ -147,6 +147,7 @@ tag_func_do_init_action (SwfdecSwfDecode
SwfdecBits *bits = &s->b;
guint id;
SwfdecSprite *sprite;
+ char *name;
id = swfdec_bits_get_u16 (bits);
SWFDEC_LOG (" id = %u", id);
@@ -159,8 +160,10 @@ tag_func_do_init_action (SwfdecSwfDecode
SWFDEC_ERROR ("sprite %u already has an...
2007 Aug 22
0
163 commits - autogen.sh configure.ac doc/swfdec-sections.txt libswfdec-gtk/swfdec_gtk_player.c libswfdec-gtk/swfdec_gtk_player.h libswfdec-gtk/swfdec_gtk_widget.c libswfdec-gtk/swfdec_source.c libswfdec/Makefile.am libswfdec/swfdec_as_array.c
...;swfdec_pattern.h"
#include "swfdec_player_internal.h"
-#include "swfdec_script.h"
+#include "swfdec_script_internal.h"
#include "swfdec_shape.h"
#include "swfdec_sound.h"
#include "swfdec_sprite.h"
@@ -545,7 +545,7 @@ tag_func_do_init_action (SwfdecSwfDecode
return SWFDEC_STATUS_OK;
}
name = g_strdup_printf ("InitAction %u", id);
- sprite->init_action = swfdec_script_new (bits, name, s->version);
+ sprite->init_action = swfdec_script_new_from_bits (bits, name, s->version);
g_free (name);
if (spr...
2007 Mar 29
0
libswfdec-gtk/swfdec_playback_alsa.c libswfdec/swfdec_audio_event.h libswfdec/swfdec_audio_flv.h libswfdec/swfdec_audio_stream.h libswfdec/swfdec_bits.c libswfdec/swfdec_bits.h libswfdec/swfdec_buffer.c libswfdec/swfdec_buffer.h libswfdec/swfdec_cache.c
.../
/* visuals */
@@ -71,11 +71,11 @@ struct _SwfdecSprite
SwfdecGraphic graphic;
SwfdecSpriteFrame * frames; /* the n_frames different frames */
- unsigned int n_frames; /* number of frames in this sprite */
+ guint n_frames; /* number of frames in this sprite */
SwfdecScript * init_action; /* action to run when initializing this sprite */
/* parse state */
- unsigned int parse_frame; /* frame we're currently parsing. == n_frames if done parsing */
+ guint parse_frame; /* frame we're currently parsing. == n_frames if done parsing */
GHashTable * live_content; /*...
2007 Jun 13
0
Branch 'as' - 6 commits - libswfdec/swfdec_as_array.c libswfdec/swfdec_button_movie.c libswfdec/swfdec_morph_movie.c libswfdec/swfdec_movie_asprops.c libswfdec/swfdec_movie.c libswfdec/swfdec_movie.h libswfdec/swfdec_player.c libswfdec/swfdec_sprite.c
.../libswfdec/swfdec_sprite.h
@@ -71,12 +71,11 @@ struct _SwfdecSprite
SwfdecGraphic graphic;
SwfdecSpriteFrame * frames; /* the n_frames different frames */
- guint n_frames; /* number of frames in this sprite */
+ guint n_frames; /* number of frames in this sprite */
SwfdecScript * init_action; /* action to run when initializing this sprite */
/* parse state */
- guint parse_frame; /* frame we're currently parsing. == n_frames if done parsing */
- GHashTable * live_content; /* depth->SwfdecSpriteContent for every content in parse_frame */
+ guint parse_frame; /* frame...
2007 Mar 29
0
Branch 'as' - 9 commits - libswfdec-gtk/swfdec_playback_alsa.c libswfdec/js libswfdec/Makefile.am libswfdec/swfdec_as_context.c libswfdec/swfdec_as_context.h libswfdec/swfdec_as_frame.c libswfdec/swfdec_as_frame.h libswfdec/swfdec_as_function.c
.../
/* visuals */
@@ -71,11 +71,11 @@ struct _SwfdecSprite
SwfdecGraphic graphic;
SwfdecSpriteFrame * frames; /* the n_frames different frames */
- unsigned int n_frames; /* number of frames in this sprite */
+ guint n_frames; /* number of frames in this sprite */
SwfdecScript * init_action; /* action to run when initializing this sprite */
/* parse state */
- unsigned int parse_frame; /* frame we're currently parsing. == n_frames if done parsing */
+ guint parse_frame; /* frame we're currently parsing. == n_frames if done parsing */
GHashTable * live_content; /*...
2008 Jan 21
0
70 commits - configure.ac libswfdec-gtk/Makefile.am libswfdec-gtk/swfdec-gtk.h libswfdec-gtk/swfdec_gtk_loader.c libswfdec-gtk/swfdec_gtk_player.c libswfdec-gtk/swfdec_gtk_socket.c libswfdec-gtk/swfdec_gtk_socket.h libswfdec-gtk/swfdec_playback_alsa.c
...index 791f985..2eaafe6 100644
--- a/libswfdec/swfdec_sprite_movie.c
+++ b/libswfdec/swfdec_sprite_movie.c
@@ -460,7 +460,8 @@ swfdec_sprite_movie_perform_one_action (SwfdecSpriteMovie *movie, guint tag, Swf
return TRUE;
}
name = g_strdup_printf ("InitAction %u", id);
- sprite->init_action = swfdec_script_new_from_bits (&bits, name, SWFDEC_AS_CONTEXT (player)->version);
+ sprite->init_action = swfdec_script_new_from_bits (&bits, name,
+ swfdec_movie_get_version (mov));
g_free (name);
if (sprite->init_action) {
swfdec_player_add_action_script (player, mov...