Displaying 20 results from an estimated 129 matches for "swfdec_warn".
Did you mean:
swfdec_warn'd
2007 Mar 22
0
7 commits - configure.ac doc/swfdec-docs.sgml libswfdec/js libswfdec/swfdec_buffer.c libswfdec/swfdec_buffer.h libswfdec/swfdec_js_movie.c test/trace
...100644
--- a/libswfdec/swfdec_js_movie.c
+++ b/libswfdec/swfdec_js_movie.c
@@ -116,7 +116,11 @@ mc_play (JSContext *cx, JSObject *obj, u
{
SwfdecMovie *movie;
- movie = JS_GetPrivate(cx, obj);
+ movie = swfdec_scriptable_from_object (cx, obj, SWFDEC_TYPE_MOVIE);
+ if (movie == NULL) {
+ SWFDEC_WARNING ("not a movie");
+ return JS_TRUE;
+ }
g_assert (movie);
movie->stopped = FALSE;
@@ -128,8 +132,11 @@ mc_stop (JSContext *cx, JSObject *obj, u
{
SwfdecMovie *movie;
- movie = JS_GetPrivate(cx, obj);
- g_assert (movie);
+ movie = swfdec_scriptable_from_object (cx...
2007 Aug 13
0
2 commits - libswfdec/swfdec_sprite_movie.c libswfdec/swfdec_tag.c libswfdec/swfdec_tag.h
...ransform);
+ swfdec_bits_get_color_transform (&bits, &content->color_transform);
content->has_color_transform = TRUE;
content->graphic = swfdec_swf_decoder_get_character (s, character);
+ if (blend_mode) {
+ guint mode = swfdec_bits_get_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);
@@ -4...
2008 Jan 09
0
libswfdec/swfdec_audio_event.c libswfdec/swfdec_bits.c libswfdec/swfdec_sound.c libswfdec/swfdec_sprite.c libswfdec/swfdec_swf_decoder.c
...5dcd..fa43359 100644
--- a/libswfdec/swfdec_audio_event.c
+++ b/libswfdec/swfdec_audio_event.c
@@ -188,7 +188,7 @@ swfdec_audio_event_decode (SwfdecAudioEvent *event)
}
skip = bytes_per_sample * (event->start_sample / granule);
if (skip >= event->decoded->length) {
- SWFDEC_WARNING ("start sample %u > total number of samples %u",
+ SWFDEC_WARNING ("start sample %u > total number of samples %"G_GSIZE_FORMAT,
event->start_sample / granule, event->decoded->length / bytes_per_sample);
swfdec_buffer_unref (event->decoded);...
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
...ransform);
+ swfdec_bits_get_color_transform (&bits, &content->color_transform);
content->has_color_transform = TRUE;
content->graphic = swfdec_swf_decoder_get_character (s, character);
+ if (blend_mode) {
+ guint mode = swfdec_bits_get_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);
@@ -4...
2007 Oct 14
0
4 commits - libswfdec/swfdec_as_interpret.c libswfdec/swfdec_sound.c test/trace
...0 @@ swfdec_player_get_movie_from_value (SwfdecPlayer *player, SwfdecAsValue *val)
cx = SWFDEC_AS_CONTEXT (player);
s = swfdec_as_value_to_string (cx, val);
ret = swfdec_action_lookup_object (cx, NULL, s, s + strlen (s));
- if (!SWFDEC_IS_MOVIE (ret))
+ if (!SWFDEC_IS_MOVIE (ret)) {
+ SWFDEC_WARNING ("\"%s\" does not reference a movie", s);
return NULL;
+ }
return SWFDEC_MOVIE (ret);
}
@@ -607,7 +615,10 @@ swfdec_action_get_movie_by_path (SwfdecAsContext *cx, const char *path,
/* variable to use is the part after the last dot or colon */
*variable = end...
2007 Feb 22
0
3 commits - libswfdec/swfdec_js.c libswfdec/swfdec_js_movie.c libswfdec/swfdec_script.c
...SwfdecMovie *movie;
JSObject *jsobj;
guint32 id;
+ const char *bytes;
- val = cx->fp->sp[-2];
- if (!swfdec_eval_jsval (cx, NULL, &val))
- return JS_FALSE;
- movie = swfdec_scriptable_from_jsval (cx, val, SWFDEC_TYPE_MOVIE);
- val = JSVAL_VOID;
- if (movie == NULL) {
- SWFDEC_WARNING ("specified target does not reference a movie clip");
- goto out;
- }
if (!JS_ValueToECMAUint32 (cx, cx->fp->sp[-1], &id))
return JS_FALSE;
-
- if (id > (((SwfdecScript *) cx->fp->swf)->version > 4 ? 21 : 18))
+ val = cx->fp->sp[-2];
+ byt...
2007 Sep 05
0
5 commits - libswfdec/swfdec_codec_ffmpeg.c libswfdec/swfdec_codec_video.c libswfdec/swfdec_player.c libswfdec/swfdec_video.c
...DecoderFFMpeg *) dec;
- int got_image;
+ int got_image = 0;
SwfdecBuffer *ret;
AVPicture picture;
+ guchar *tmp, *aligned;
+ /* fullfill alignment and padding requirements */
+ tmp = g_try_malloc (buffer->length + ALIGNMENT + FF_INPUT_BUFFER_PADDING_SIZE);
+ if (tmp == NULL) {
+ SWFDEC_WARNING ("Could not allocate temporary memory");
+ return NULL;
+ }
+ aligned = (guchar *) (((uintptr_t) tmp + ALIGNMENT) & ~ALIGNMENT);
+ memcpy (aligned, buffer->data, buffer->length);
+ memset (aligned + buffer->length, 0, FF_INPUT_BUFFER_PADDING_SIZE);
if (avcodec_de...
2007 Apr 05
0
Branch 'as' - 9 commits - configure.ac libswfdec/swfdec_as_context.c libswfdec/swfdec_as_frame.c libswfdec/swfdec_as_frame.h libswfdec/swfdec_as_function.h libswfdec/swfdec_as_interpret.c libswfdec/swfdec_as_object.c libswfdec/swfdec_as_object.h
...dec_action_get_property (SwfdecAsContext *cx, guint action, const guint8 *data, guint len)
+{
+ SwfdecAsValue *val;
+ SwfdecAsObject *obj;
+ guint id;
+
+ id = swfdec_as_value_to_integer (cx, swfdec_as_stack_pop (cx->frame->stack));
+ if (id > (cx->version > 4 ? 21 : 18)) {
+ SWFDEC_WARNING ("trying to SetProperty %u, not allowed", id);
+ goto out;
+ }
+ val = swfdec_as_stack_peek (cx->frame->stack, 1);
+ swfdec_as_interpret_eval (cx, NULL, val);
+ if (SWFDEC_AS_VALUE_IS_UNDEFINED (val)) {
+ obj = cx->frame->scope;
+ } else if (SWFDEC_AS_VALUE_IS_OB...
2007 Apr 04
0
Branch 'as' - 4 commits - libswfdec/Makefile.am libswfdec/swfdec_as_context.c libswfdec/swfdec_as_frame.c libswfdec/swfdec_as_interpret.c libswfdec/swfdec_as_interpret.h libswfdec/swfdec_as_object.c libswfdec/swfdec_as_types.c libswfdec/swfdec_as_types.h
...+#include <string.h>
+#include "swfdec_decoder.h"
+#include "swfdec_movie.h"
+#include "swfdec_player_internal.h"
+#include "swfdec_root_movie.h"
+#include "swfdec_sprite.h"
+#include "swfdec_sprite_movie.h"
+
+/* Define this to get SWFDEC_WARN'd about missing properties of objects.
+ * This can be useful to find out about unimplemented native properties,
+ * but usually just causes a lot of spam. */
+//#define SWFDEC_WARN_MISSING_PROPERTIES
+
+/*** SUPPORT FUNCTIONS ***/
+
+#define swfdec_action_has_register(cx, i) \
+ ((i) < ((S...
2007 Nov 14
0
7 commits - libswfdec/swfdec_as_frame.c libswfdec/swfdec_as_function.c libswfdec/swfdec_as_internal.h libswfdec/swfdec_as_interpret.c libswfdec/swfdec_as_object.c libswfdec/swfdec_as_super.c libswfdec/swfdec_as_super.h
...e67b40 100644
--- a/libswfdec/swfdec_as_super.c
+++ b/libswfdec/swfdec_as_super.c
@@ -43,8 +43,6 @@ swfdec_as_super_call (SwfdecAsFunction *function)
SwfdecAsFunctionClass *klass;
SwfdecAsFrame *frame;
- //if (!super->callable)
- // return NULL;
if (super->object == NULL) {
SWFDEC_WARNING ("super () called without an object.");
return NULL;
@@ -146,13 +144,14 @@ swfdec_as_super_init (SwfdecAsSuper *super)
}
void
-swfdec_as_super_new (SwfdecAsFrame *frame, SwfdecAsObject *ref, gboolean callable)
+swfdec_as_super_new (SwfdecAsFrame *frame, SwfdecAsObject *thisp,...
2007 Feb 15
0
3 commits - libswfdec/swfdec_bits.c libswfdec/swfdec_shape.c libswfdec/swfdec_tag.c
...%s during DefineSprite",
tag, swfdec_swf_decoder_get_tag_name (tag));
} else {
- const unsigned char *endptr = parse.ptr + tag_len;
ret = func (s);
- swfdec_bits_syncbits (bits);
- if (tag_len > 0) {
- if (s->b.ptr < endptr) {
- SWFDEC_WARNING ("early parse finish (%d bytes)", endptr - s->b.ptr);
- }
- if (s->b.ptr > endptr) {
- SWFDEC_WARNING ("parse overrun (%d bytes)", s->b.ptr - endptr);
- }
+ if (swfdec_bits_left (&s->b)) {
+ SWFDEC_WARNING ("ea...
2007 Jun 27
0
Branch 'as' - 3 commits - libswfdec/Makefile.am libswfdec/swfdec_as_interpret.c libswfdec/swfdec_js_video.c libswfdec/swfdec_player.c libswfdec/swfdec_player_internal.h libswfdec/swfdec_video_movie_as.c libswfdec/swfdec_video_movie.c
...ger (cx, swfdec_as_stack_peek (cx->frame->stack, 1));
n_args = MIN (swfdec_as_stack_get_size (cx->frame->stack) - 1, n_args);
- if (!SWFDEC_AS_VALUE_IS_OBJECT (constructor) ||
- !SWFDEC_IS_AS_FUNCTION (fun = (SwfdecAsFunction *) SWFDEC_AS_VALUE_GET_OBJECT (constructor))) {
- SWFDEC_WARNING ("%s is not a constructor", name);
- goto fail;
- }
if (name != SWFDEC_AS_STR_EMPTY) {
- if (SWFDEC_AS_VALUE_IS_OBJECT (constructor)) {
- swfdec_as_object_get_variable (SWFDEC_AS_VALUE_GET_OBJECT (constructor),
- name, constructor);
+ if (!SWFDEC_AS_VALUE_IS_OBJECT...
2007 Jun 01
0
Branch 'as' - 2 commits - libswfdec/Makefile.am libswfdec/swfdec_as_strings.c libswfdec/swfdec_as_types.c libswfdec/swfdec_interval.c libswfdec/swfdec_interval.h libswfdec/swfdec_player_as.c libswfdec/swfdec_player.c
...= SWFDEC_PLAYER (obj->context);
SwfdecAsObject *object;
- SwfdecAsValue fun;
- guint i, n_args, first_arg, msecs;
- SwfdecAsInterval *interval;
+ guint id, msecs;
+#define MIN_INTERVAL_TIME 10
- if (!JSVAL_IS_OBJECT (argv[0])) {
+ if (!SWFDEC_AS_VALUE_IS_OBJECT (&argv[0])) {
SWFDEC_WARNING ("first argument to setInterval is not an object");
- return JS_TRUE;
+ return;
}
- object = JSVAL_TO_OBJECT (argv[0]);
- if (JS_GetClass (object) == &js_FunctionClass) {
- fun = argv[0];
- object = JS_GetParent (cx, object);
- if (object == NULL) {
- SWFDE...
2007 Sep 26
1
Youtube broken by 89d295a94
...+590,7 @@ swfdec_action_get_variable (SwfdecAsContext *cx, guint action, const guint8 *dat
swfdec_as_frame_get_variable (cx->frame, swfdec_as_context_get_string (cx, s), val);
}
} else {
- SWFDEC_AS_VALUE_SET_UNDEFINED (val);
+// SWFDEC_AS_VALUE_SET_UNDEFINED (val);
#ifdef SWFDEC_WARN_MISSING_PROPERTIES
SWFDEC_WARNING ("no variable named %s", s);
#endif
--
Regards,
Pavel Roskin
2007 Mar 20
0
4 commits - libswfdec/swfdec_flv_decoder.c libswfdec/swfdec_flv_decoder.h libswfdec/swfdec_movie.c test/trace
...*flv, SwfdecBits *bits, guint timestamp)
+{
+ SwfdecFlvDataTag tag;
+
+ if (flv->data == NULL) {
+ flv->data = g_array_new (FALSE, FALSE, sizeof (SwfdecFlvDataTag));
+ }
+
+ tag.timestamp = timestamp;
+ tag.buffer = swfdec_bits_get_buffer (bits, -1);
+ if (tag.buffer == NULL) {
+ SWFDEC_WARNING ("no buffer, ignoring");
+ return;
+ }
+ if (flv->data->len == 0) {
+ g_array_append_val (flv->data, tag);
+ } else if (g_array_index (flv->data, SwfdecFlvDataTag,
+ flv->data->len - 1).timestamp < tag.timestamp) {
+ g_array_append_val (flv->data, t...
2007 May 29
0
Branch 'as' - 6 commits - libswfdec/swfdec_as_interpret.c libswfdec/swfdec_js_xml.c libswfdec/swfdec_tag.c player/swfplay.c
...ger (cx, swfdec_as_stack_peek (cx->frame->stack, 1));
+ n_args = MIN (swfdec_as_stack_get_size (cx->frame->stack) - 1, n_args);
+ if (!SWFDEC_AS_VALUE_IS_OBJECT (constructor) ||
+ !SWFDEC_IS_AS_FUNCTION (fun = (SwfdecAsFunction *) SWFDEC_AS_VALUE_GET_OBJECT (constructor))) {
+ SWFDEC_WARNING ("%s is not a constructor", name);
goto fail;
- if (s[0] == '\0') {
- constructor = OBJECT_TO_JSVAL (object);
- } else {
- if (!JS_GetProperty (cx, object, s, &constructor))
- return JS_FALSE;
- if (!JSVAL_IS_OBJECT (constructor)) {
- SWFDEC_WARNIN...
2007 Feb 08
0
3 commits - libswfdec/swfdec_loader.c libswfdec/swfdec_script.c libswfdec/swfdec_video.c
...wfdecSwfDecoder
SWFDEC_LOG (" deblocking: %d", deblocking);
SWFDEC_LOG (" smoothing: %d", smoothing);
SWFDEC_LOG (" format: %d", (int) video->format);
- video->codec = swfdec_codec_get_video (video->format);
- if (video->codec == NULL) {
- SWFDEC_WARNING ("no codec for format %d", (int) video->format);
- return SWFDEC_STATUS_OK;
+ if (video->format != SWFDEC_VIDEO_FORMAT_UNDEFINED) {
+ video->codec = swfdec_codec_get_video (video->format);
+ if (video->codec == NULL) {
+ SWFDEC_WARNING ("no codec for...
2007 Mar 01
0
7 commits - libswfdec/swfdec_connection.c libswfdec/swfdec_js_connection.c libswfdec/swfdec_js_movie.c libswfdec/swfdec_js_net_stream.c libswfdec/swfdec_js_xml.c libswfdec/swfdec_net_stream.c libswfdec/swfdec_scriptable.c libswfdec/swfdec_scriptable.h
...(g = g_list_first (a->obj->properties); g; g = g_list_next (g)) {
- ScriptObjectProperty *prop = g->data;
- if (allowFalse) {
- prop->flags = flags;
- } else {
- prop->flags |= flags;
- }
- }
- } else {
- action_val_convert_to_string (b);
- SWFDEC_WARNING("ASSetPropFlags not implemented (properties %s, flags 0x%x)",
- b->string, (int)c->number);
- }
-
- action_val_free (a);
- action_val_free (b);
- action_val_free (c);
-
- a = action_val_new ();
- a->type = ACTIONVAL_TYPE_UNDEF;
- stack_push (context, a);
-}
-#endif...
2007 Oct 26
0
3 commits - libswfdec/swfdec_as_context.c libswfdec/swfdec_as_context.h libswfdec/swfdec_as_interpret.c
...ction, const guint8 *data, guint
return;
}
- try_data = g_malloc (sizeof (TryData));
+ try_data = g_malloc0 (sizeof (TryData));
swfdec_bits_init_data (&bits, data, len);
@@ -2716,8 +2751,9 @@ swfdec_action_try (SwfdecAsContext *cx, guint action, const guint8 *data, guint
SWFDEC_WARNING ("leftover bytes in Try action");
}
+ swfdec_action_try_data_ref (try_data);
swfdec_as_frame_push_block (cx->frame, data + len, data + len + try_size,
- swfdec_action_try_end_try, try_data, NULL);
+ swfdec_action_try_end_try, try_data, swfdec_action_try_data_unref...
2007 Sep 13
0
5 commits - libswfdec/Makefile.am libswfdec/swfdec_as_context.c libswfdec/swfdec_as_frame.c libswfdec/swfdec_as_frame_internal.h libswfdec/swfdec_as_interpret.c libswfdec/swfdec_as_scope.c libswfdec/swfdec_as_scope.h libswfdec/swfdec_as_script_function.c
...variable (obj, name, ret);
} else {
if (cx->frame) {
- obj = swfdec_as_frame_find_variable (cx->frame, name);
- if (obj) {
- swfdec_as_object_get_variable (obj, name, ret);
- return;
- }
+ swfdec_as_frame_get_variable (cx->frame, name, ret);
} else {
SWFDEC_WARNING ("eval called without a frame");
swfdec_as_object_get_variable (cx->global, name, ret);
}
- SWFDEC_AS_VALUE_SET_UNDEFINED (ret);
}
}
@@ -985,11 +980,10 @@ swfdec_as_context_eval_set_property (Swf
SWFDEC_ERROR ("no frame in eval_set?");
re...