Displaying 15 results from an estimated 15 matches for "swfdec_content_free".
2007 Jun 09
0
Branch 'as' - libswfdec/swfdec_flv_decoder.c libswfdec/swfdec_movie.c libswfdec/swfdec_movie.h libswfdec/swfdec_sprite_movie_as.c
...653,8 +653,8 @@ swfdec_flv_decoder_add_movie (SwfdecFlvD
video->width = G_MAXUINT;
video->height = G_MAXUINT;
content->graphic = SWFDEC_GRAPHIC (video);
+ content->free = TRUE;
movie = swfdec_movie_new (parent, content);
- g_object_weak_ref (G_OBJECT (movie), (GWeakNotify) swfdec_content_free, content);
g_object_weak_ref (G_OBJECT (movie), (GWeakNotify) g_object_unref, video);
g_signal_connect (SWFDEC_ROOT_MOVIE (parent)->player, "notify::initialized",
G_CALLBACK (notify_initialized), movie);
diff --git a/libswfdec/swfdec_movie.c b/libswfdec/swfdec_movie.c
inde...
2007 Mar 15
0
2 commits - libswfdec/swfdec_sprite.c
...= swfdec_swf_decoder_get_character (s, id);
if (!SWFDEC_IS_GRAPHIC (content->graphic)) {
- g_hash_table_remove (sprite->live_content, GUINT_TO_POINTER (content->depth));
+ g_hash_table_remove (s->parse_sprite->live_content, GUINT_TO_POINTER (content->depth));
swfdec_content_free (content);
swfdec_sprite_remove_last_action (s->parse_sprite,
s->parse_sprite->parse_frame);
@@ -366,7 +366,7 @@ swfdec_spriteseg_place_object_2 (SwfdecS
SWFDEC_LOG (" id = %d", id);
} else if (content->graphic == NULL) {
SWFDEC_ERROR ("no c...
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
...- &g_array_index (sprite->frames[i].actions, SwfdecSpriteAction, j);
- switch (action->type) {
- case SWFDEC_SPRITE_ACTION_SCRIPT:
- swfdec_script_unref (action->data);
- break;
- case SWFDEC_SPRITE_ACTION_ADD:
- case SWFDEC_SPRITE_ACTION_UPDATE:
- swfdec_content_free (action->data);
- break;
- case SWFDEC_SPRITE_ACTION_REMOVE:
- break;
- default:
- g_assert_not_reached ();
- }
- }
- g_array_free (sprite->frames[i].actions, TRUE);
- }
g_slist_foreach (sprite->frames[i].sound, (GFunc) swfdec_sound_chunk_free, NULL)...
2007 Aug 13
0
2 commits - libswfdec/swfdec_sprite_movie.c libswfdec/swfdec_tag.c libswfdec/swfdec_tag.h
...t_u8 (&bits);
+ SWFDEC_WARNING (" blend mode = %u", mode);
+ }
+ if (has_filters)
+ swfdec_filters_parse (&bits);
if (!SWFDEC_IS_GRAPHIC (content->graphic)) {
SWFDEC_ERROR ("id %u does not reference a graphic, ignoring", character);
swfdec_content_free (content);
@@ -448,24 +467,34 @@ tag_func_define_button_2 (SwfdecSwfDecod
swfdec_button_append_content (button, states, content);
}
}
- swfdec_bits_get_u8 (bits);
+ swfdec_bits_get_u8 (&bits);
+ if (swfdec_bits_left (&bits)) {
+ SWFDEC_WARNING ("%u bytes left when...
2007 Apr 13
0
5 commits - libswfdec/Makefile.am libswfdec/swfdec_color.c libswfdec/swfdec_color.h libswfdec/swfdec_font.c libswfdec/swfdec_loadertarget.c libswfdec/swfdec_movie.h libswfdec/swfdec_pattern.c libswfdec/swfdec_pattern.h libswfdec/swfdec_player.c
...(=> %d)", content->clip_depth + 16384, content->clip_depth);
}
+ if (has_filter) {
+ SWFDEC_ERROR ("filters aren't implemented, skipping PlaceObject tag!");
+ g_hash_table_remove (s->parse_sprite->live_content, GUINT_TO_POINTER (content->depth));
+ swfdec_content_free (content);
+ swfdec_sprite_remove_last_action (s->parse_sprite,
+ s->parse_sprite->parse_frame);
+ return SWFDEC_STATUS_OK;
+ }
+ if (has_blend_mode) {
+ guint operator = swfdec_bits_get_u8 (bits);
+ content->operator = swfdec_sprite_convert_operator (operator);
+...
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
...} else {
- g_return_if_fail (movie->content->name == NULL);
- }
- } else {
- movie->depth = content->depth;
- }
- SWFDEC_LOG ("setting content of movie %s from %p to %p",
- movie->name, movie->content, content);
- if (movie->content->free)
- swfdec_content_free ((SwfdecContent *) movie->content);
- movie->content = content;
- if (!movie->modified) {
- movie->matrix = content->transform;
- movie->xscale = swfdec_matrix_get_xscale (&movie->matrix);
- movie->yscale = swfdec_matrix_get_yscale (&movie->matrix);
-...
2007 Jun 15
0
Branch 'as' - 5 commits - libswfdec/swfdec_as_native_function.c libswfdec/swfdec_edittext.c libswfdec/swfdec_edittext.h libswfdec/swfdec_font.c libswfdec/swfdec_font.h libswfdec/swfdec_image.c libswfdec/swfdec_image.h libswfdec/swfdec_morphshape.h
...d_chunk (SwfdecSprite * sprite, guint frame,
SwfdecBuffer * chunk, int skip, guint n_samples);
void swfdec_sprite_set_n_frames (SwfdecSprite *sprite, guint n_frames, guint rate);
@@ -98,12 +98,11 @@ int swfdec_sprite_get_frame (SwfdecSpr
SwfdecContent *swfdec_content_new (int depth);
void swfdec_content_free (SwfdecContent *content);
-int tag_show_frame (SwfdecSwfDecoder * s);
-int tag_func_set_background_color (SwfdecSwfDecoder * s);
-int swfdec_spriteseg_place_object_2 (SwfdecSwfDecoder * s);
-int swfdec_spriteseg_place_object_3 (SwfdecSwfDecoder * s);
-int swfdec_spriteseg_remove_object (SwfdecSwf...
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
...t;depth = depth;
+ content->clip_depth = 0; /* FIXME: check this */
+ content->name = g_strdup (name);
+ content->sequence = content;
+ content->start = 0;
+ content->end = G_MAXUINT;
+ ret = swfdec_movie_new (movie, content);
+ g_object_weak_ref (G_OBJECT (ret), (GWeakNotify) swfdec_content_free, content);
+ /* must be set by now, the movie has a name */
+ if (SWFDEC_SCRIPTABLE (ret)->jsobj == NULL)
+ return JS_FALSE;
+ SWFDEC_LOG ("attached %s (%u) as %s to depth %u", export, SWFDEC_CHARACTER (sprite)->id,
+ ret->name, ret->depth);
+ *rval = OBJECT_TO_JSV...
2007 Jan 16
0
9 commits - libswfdec/js libswfdec/Makefile.am libswfdec/swfdec_audio_stream.c libswfdec/swfdec_audio_stream.h libswfdec/swfdec_cache.c libswfdec/swfdec_cached.c libswfdec/swfdec_cached.h libswfdec/swfdec_edittext_movie.c libswfdec/swfdec_image.c
...l (cx, argv[0], SWFDEC_TYPE_MOVIE);
if (other == NULL)
return JS_TRUE;
if (other->parent != movie->parent)
@@ -433,11 +415,11 @@ swfdec_js_movie_duplicateMovieClip (JSCo
ret = swfdec_movie_new (movie->parent, content);
g_object_weak_ref (G_OBJECT (ret), (GWeakNotify) swfdec_content_free, content);
/* must be set by now, the movie has a name */
- if (ret->jsobj == NULL)
+ if (SWFDEC_SCRIPTABLE (ret)->jsobj == NULL)
return JS_FALSE;
swfdec_js_copy_props (ret, movie);
SWFDEC_LOG ("duplicated %s as %s to depth %u", movie->name, ret->name, ret->...
2007 Mar 02
0
12 commits - libswfdec/Makefile.am libswfdec/swfdec_audio_flv.c libswfdec/swfdec_flv_decoder.c libswfdec/swfdec_js.c libswfdec/swfdec_js.h libswfdec/swfdec_js_video.c libswfdec/swfdec_loader.c libswfdec/swfdec_loader_internal.h
...FDEC_DECODER (flv)->width;
- video->height = SWFDEC_DECODER (flv)->height;
+ video->width = G_MAXUINT;
+ video->height = G_MAXUINT;
content->graphic = SWFDEC_GRAPHIC (video);
movie = swfdec_movie_new (parent, content);
g_object_weak_ref (G_OBJECT (movie), (GWeakNotify) swfdec_content_free, content);
g_object_weak_ref (G_OBJECT (movie), (GWeakNotify) g_object_unref, video);
+ g_signal_connect (SWFDEC_ROOT_MOVIE (parent)->player, "notify::initialized",
+ G_CALLBACK (notify_initialized), movie);
/* set up the playback stream */
conn = swfdec_connection_new (...
2007 Aug 13
0
Branch 'vivi' - 24 commits - configure.ac libswfdec/swfdec_sprite_movie.c libswfdec/swfdec_tag.c libswfdec/swfdec_tag.h vivified/core vivified/dock vivified/ui
...t_u8 (&bits);
+ SWFDEC_WARNING (" blend mode = %u", mode);
+ }
+ if (has_filters)
+ swfdec_filters_parse (&bits);
if (!SWFDEC_IS_GRAPHIC (content->graphic)) {
SWFDEC_ERROR ("id %u does not reference a graphic, ignoring", character);
swfdec_content_free (content);
@@ -448,24 +467,34 @@ tag_func_define_button_2 (SwfdecSwfDecod
swfdec_button_append_content (button, states, content);
}
}
- swfdec_bits_get_u8 (bits);
+ swfdec_bits_get_u8 (&bits);
+ if (swfdec_bits_left (&bits)) {
+ SWFDEC_WARNING ("%u bytes left when...
2007 Jun 05
0
Branch 'as' - 8 commits - libswfdec/Makefile.am libswfdec/swfdec_as_context.c libswfdec/swfdec_as_frame.c libswfdec/swfdec_as_frame.h libswfdec/swfdec_as_interpret.c libswfdec/swfdec_as_number.c libswfdec/swfdec_as_scope.h
...eClass *klass;
g_return_if_fail (SWFDEC_IS_MOVIE (movie));
@@ -936,7 +937,6 @@ swfdec_movie_new_for_player (SwfdecPlaye
content->name = g_strdup_printf ("_level%u", depth);
ret = g_object_new (SWFDEC_TYPE_ROOT_MOVIE, NULL);
g_object_weak_ref (G_OBJECT (ret), (GWeakNotify) swfdec_content_free, content);
- SWFDEC_ROOT_MOVIE (ret)->player = player;
ret->root = ret;
if (swfdec_as_context_use_mem (SWFDEC_AS_CONTEXT (player), sizeof (SwfdecRootMovie))) {
g_object_ref (ret);
diff --git a/libswfdec/swfdec_player.c b/libswfdec/swfdec_player.c
index 54a2707..288e9ef 100644
---...
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
...const char * name,
int depth);
diff --git a/libswfdec/swfdec_sprite.c b/libswfdec/swfdec_sprite.c
index e81c688..d17cbd5 100644
--- a/libswfdec/swfdec_sprite.c
+++ b/libswfdec/swfdec_sprite.c
@@ -36,15 +36,6 @@
G_DEFINE_TYPE (SwfdecSprite, swfdec_sprite, SWFDEC_TYPE_GRAPHIC)
-void
-swfdec_content_free (SwfdecContent *content)
-{
- g_free (content->name);
- if (content->events)
- swfdec_event_list_free (content->events);
- g_free (content);
-}
-
static void
swfdec_sprite_dispose (GObject *object)
{
@@ -155,17 +146,6 @@ tag_func_set_background_color (SwfdecSwfDecoder * s, guint t...
2007 Mar 01
0
11 commits - libswfdec/Makefile.am libswfdec/swfdec_connection.c libswfdec/swfdec_connection.h libswfdec/swfdec_flv_decoder.c libswfdec/swfdec_js.c libswfdec/swfdec_js_connection.c libswfdec/swfdec_js.h libswfdec/swfdec_js_net_stream.c
...SwfdecContent *content = swfdec_content_new (0);
SwfdecMovie *movie;
SwfdecVideo *video;
+ SwfdecConnection *conn;
SwfdecNetStream *stream;
/* set up the video movie */
@@ -469,7 +470,8 @@ swfdec_flv_decoder_add_movie (SwfdecFlvD
g_object_weak_ref (G_OBJECT (movie), (GWeakNotify) swfdec_content_free, content);
g_object_weak_ref (G_OBJECT (movie), (GWeakNotify) g_object_unref, video);
/* set up the playback stream */
- stream = swfdec_net_stream_new (SWFDEC_ROOT_MOVIE (parent)->player);
+ conn = swfdec_connection_new (SWFDEC_ROOT_MOVIE (parent)->player->jscx);
+ stream = swfde...
2007 Apr 04
0
Branch 'as' - 17 commits - configure.ac doc/Makefile.am doc/swfdec-docs.sgml doc/swfdec-sections.txt doc/swfdec.types libswfdec-gtk/Makefile.am libswfdec-gtk/swfdec-gtk.h libswfdec-gtk/swfdec_gtk_loader.c libswfdec-gtk/swfdec_gtk_loader.h
...RIPTABLE (parent)->jscx;
g_object_ref (parent);
ret->root = parent->root;
swfdec_movie_initialize (ret, content);
@@ -811,7 +901,13 @@ swfdec_movie_new_for_player (SwfdecPlaye
ret = g_object_new (SWFDEC_TYPE_ROOT_MOVIE, NULL);
g_object_weak_ref (G_OBJECT (ret), (GWeakNotify) swfdec_content_free, content);
SWFDEC_ROOT_MOVIE (ret)->player = player;
- SWFDEC_SCRIPTABLE (ret)->jscx = player->jscx;
+ if (swfdec_as_context_use_mem (SWFDEC_AS_CONTEXT (player), sizeof (SwfdecRootMovie))) {
+ swfdec_as_object_add (SWFDEC_AS_OBJECT (ret),
+ SWFDEC_AS_CONTEXT (player), sizeof (Swfde...