Displaying 11 results from an estimated 11 matches for "swfdecpattern".
Did you mean:
swfdec_pattern
2007 Apr 16
0
7 commits - libswfdec/swfdec_codec_gst.c libswfdec/swfdec_font.c libswfdec/swfdec_js_movie.c libswfdec/swfdec_morph_movie.c libswfdec/swfdec_pattern.c libswfdec/swfdec_pattern.h libswfdec/swfdec_shape.c libswfdec/swfdec_shape.h libswfdec/swfdec_sprite.c
.../libswfdec/swfdec_pattern.c
@@ -269,24 +269,13 @@ swfdec_gradient_pattern_init (SwfdecGrad
/*** EXPORTED API ***/
-/**
- * swfdec_pattern_parse:
- * @dec: a #SwfdecDecoder to parse from
- * @rgba: TRUE if colors are RGBA, FALSE if they're just RGB
- *
- * Continues parsing @dec into a new #SwfdecPattern
- *
- * Returns: a new #SwfdecPattern or NULL on error
- **/
-SwfdecPattern *
-swfdec_pattern_parse (SwfdecSwfDecoder *dec, gboolean rgba)
+static SwfdecPattern *
+swfdec_pattern_do_parse (SwfdecSwfDecoder *dec, gboolean rgba)
{
guint paint_style_type;
SwfdecBits *bits;
SwfdecPattern *pat...
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
...;yx * inv_ratio + end->yx * ratio) / 65535;
- dest->x0 = (start->x0 * inv_ratio + end->x0 * ratio) / 65535;
- dest->y0 = (start->y0 * inv_ratio + end->y0 * ratio) / 65535;
-}
+#include "swfdec_stroke.h"
/*** PATTERN ***/
@@ -71,131 +47,6 @@ swfdec_pattern_init (SwfdecPattern *patt
cairo_matrix_init_identity (&pattern->end_transform);
}
-/*** STROKE PATTERN ***/
-
-#define MAX_ALIGN 10
-
-typedef struct _SwfdecStrokePattern SwfdecStrokePattern;
-typedef struct _SwfdecStrokePatternClass SwfdecStrokePatternClass;
-
-#define SWFDEC_TYPE_STROKE_PATTERN...
2007 Dec 03
0
12 commits - libswfdec/Makefile.am libswfdec/swfdec_as_strings.c libswfdec/swfdec_as_types.c libswfdec/swfdec_as_types.h libswfdec/swfdec_gradient_pattern.c libswfdec/swfdec_gradient_pattern.h libswfdec/swfdec_movie_as_drawing.c libswfdec/swfdec_pattern.c
...SWFDEC_AS_NATIVE (901, 2, swfdec_sprite_movie_beginGradientFill)
void
swfdec_sprite_movie_beginGradientFill (SwfdecAsContext *cx, SwfdecAsObject *object,
guint argc, SwfdecAsValue *argv, SwfdecAsValue *rval)
{
- SWFDEC_FIXME ("implement");
+ SwfdecGradientPattern *gradient;
+ SwfdecPattern *pattern;
+ SwfdecMovie *movie;
+ SwfdecDraw *draw;
+ SwfdecAsObject *colors, *alphas, *ratios, *matrix;
+ const char *s;
+ gboolean radial;
+ int i, len;
+
+ SWFDEC_AS_CHECK (SWFDEC_TYPE_MOVIE, &movie, "|sOOOO", &s, &colors, &alphas, &ratios, &matrix);
+ m...
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
...int ratio)
+ const cairo_matrix_t *end, guint ratio)
{
- unsigned int inv_ratio = 65535 - ratio;
+ guint inv_ratio = 65535 - ratio;
g_assert (ratio < 65536);
if (ratio == 0) {
@@ -143,7 +143,7 @@ swfdec_pattern_append_path_snapped (cair
static void
swfdec_stroke_pattern_paint (SwfdecPattern *pattern, cairo_t *cr, const cairo_path_t *path,
- const SwfdecColorTransform *trans, unsigned int ratio)
+ const SwfdecColorTransform *trans, guint ratio)
{
SwfdecColor color;
double width;
@@ -206,7 +206,7 @@ G_DEFINE_TYPE (SwfdecColorPattern, swfde
static void
swfdec_color_patte...
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
...int ratio)
+ const cairo_matrix_t *end, guint ratio)
{
- unsigned int inv_ratio = 65535 - ratio;
+ guint inv_ratio = 65535 - ratio;
g_assert (ratio < 65536);
if (ratio == 0) {
@@ -143,7 +143,7 @@ swfdec_pattern_append_path_snapped (cair
static void
swfdec_stroke_pattern_paint (SwfdecPattern *pattern, cairo_t *cr, const cairo_path_t *path,
- const SwfdecColorTransform *trans, unsigned int ratio)
+ const SwfdecColorTransform *trans, guint ratio)
{
SwfdecColor color;
double width;
@@ -206,7 +206,7 @@ G_DEFINE_TYPE (SwfdecColorPattern, swfde
static void
swfdec_color_patte...
2007 Jul 01
1
implementing MovieClip drawing API
Hi,
I would like to implement MovieClip.{moveTo,lineTo,lineStyle}. I
initially thought I could place an SwfdecShape inside an
SwfdecSpriteMovie created by createEmptyMovieClip then call
swfdec_shape_ counterparts when MovieClip.{moveTo,lineTo,lineStyle}
were called. It wasn't as easy as I had thought. All the functions are
highly tied to swf bitstream, even adding an SwfdecShapeMovie to
2007 Apr 17
0
15 commits - libswfdec/jpeg libswfdec/swfdec_bits.c libswfdec/swfdec_edittext.c libswfdec/swfdec_font.c libswfdec/swfdec_image.c libswfdec/swfdec_root_sprite.c libswfdec/swfdec_script.c libswfdec/swfdec_shape.c libswfdec/swfdec_sprite.c
...,7 +329,7 @@ swfdec_shape_add_styles (SwfdecSwfDecode
n_fill_styles = swfdec_bits_get_u16 (bits);
}
SWFDEC_LOG (" n_fill_styles %d", n_fill_styles);
- for (i = 0; i < n_fill_styles; i++) {
+ for (i = 0; i < n_fill_styles && swfdec_bits_left (bits); i++) {
SwfdecPattern *pattern;
SWFDEC_LOG (" fill style %d:", i);
@@ -344,7 +344,7 @@ swfdec_shape_add_styles (SwfdecSwfDecode
n_line_styles = swfdec_bits_get_u16 (bits);
}
SWFDEC_LOG (" n_line_styles %d", n_line_styles);
- for (i = 0; i < n_line_styles; i++) {
+ for (i =...
2007 Apr 17
0
Branch 'as' - 17 commits - libswfdec/jpeg libswfdec/swfdec_bits.c libswfdec/swfdec_font.c libswfdec/swfdec_image.c libswfdec/swfdec_root_sprite.c libswfdec/swfdec_script.c libswfdec/swfdec_shape.c libswfdec/swfdec_sound.c libswfdec/swfdec_sprite.c
...,7 +329,7 @@ swfdec_shape_add_styles (SwfdecSwfDecode
n_fill_styles = swfdec_bits_get_u16 (bits);
}
SWFDEC_LOG (" n_fill_styles %d", n_fill_styles);
- for (i = 0; i < n_fill_styles; i++) {
+ for (i = 0; i < n_fill_styles && swfdec_bits_left (bits); i++) {
SwfdecPattern *pattern;
SWFDEC_LOG (" fill style %d:", i);
@@ -344,7 +344,7 @@ swfdec_shape_add_styles (SwfdecSwfDecode
n_line_styles = swfdec_bits_get_u16 (bits);
}
SWFDEC_LOG (" n_line_styles %d", n_line_styles);
- for (i = 0; i < n_line_styles; i++) {
+ for (i =...
2007 Feb 06
0
21 commits - configure.ac libswfdec/swfdec_audio_event.c libswfdec/swfdec_bits.c libswfdec/swfdec_button_movie.c libswfdec/swfdec_color.c libswfdec/swfdec_color.h libswfdec/swfdec_compiler.c libswfdec/swfdec_edittext.c libswfdec/swfdec_image.c
...(surface);
+ cairo_surface_destroy (surface);
swfdec_matrix_morph (&mat, &pat->start_transform, &pat->end_transform, ratio);
cairo_pattern_set_matrix (pattern, &mat);
cairo_pattern_set_extend (pattern, image->extend);
@@ -626,7 +627,7 @@ swfdec_pattern_to_string (SwfdecPattern
if (SWFDEC_IS_IMAGE_PATTERN (pattern)) {
SwfdecImagePattern *image = SWFDEC_IMAGE_PATTERN (pattern);
if (image->image->width == 0)
- swfdec_image_get_surface (image->image);
+ cairo_surface_destroy (swfdec_image_create_surface (image->image));
return g_strdu...
2007 Feb 06
0
Branch 'interpreter' - 8 commits - libswfdec/swfdec_bits.c libswfdec/swfdec_color.c libswfdec/swfdec_color.h libswfdec/swfdec_edittext.c libswfdec/swfdec_image.c libswfdec/swfdec_image.h libswfdec/swfdec_pattern.c libswfdec/swfdec_sprite.c test/dump.c
...(surface);
+ cairo_surface_destroy (surface);
swfdec_matrix_morph (&mat, &pat->start_transform, &pat->end_transform, ratio);
cairo_pattern_set_matrix (pattern, &mat);
cairo_pattern_set_extend (pattern, image->extend);
@@ -626,7 +627,7 @@ swfdec_pattern_to_string (SwfdecPattern
if (SWFDEC_IS_IMAGE_PATTERN (pattern)) {
SwfdecImagePattern *image = SWFDEC_IMAGE_PATTERN (pattern);
if (image->image->width == 0)
- swfdec_image_get_surface (image->image);
+ cairo_surface_destroy (swfdec_image_create_surface (image->image));
return g_strdu...
2008 Jan 07
0
12 commits - configure.ac doc/swfdec.types Makefile.am test/crashfinder.c test/dump.c test/Makefile.am test/swfdec-extract.c test/swfdec_out.c test/swfdec_out.h test/swfedit.c test/swfedit_file.c test/swfedit_file.h test/swfedit_list.c test/swfedit_list.h
...- g_print (" close\n");
- break;
- default:
- g_assert_not_reached ();
- break;
- }
- }
-}
-
-static void
-dump_shape (SwfdecShape *shape)
-{
- GSList *walk;
-
- for (walk = shape->draws; walk; walk = walk->next) {
- if (SWFDEC_IS_PATTERN (walk->data)) {
- SwfdecPattern *pattern = walk->data;
- char *str = swfdec_pattern_to_string (pattern);
- g_print ("%s\n", str);
- g_free (str);
- if (verbose) {
- g_print (" %g %g %g %g %g %g\n",
- pattern->start_transform.xx, pattern->start_transform.xy,
- patt...