Displaying 4 results from an estimated 4 matches for "swfdec_movie_local_to_global_matrix".
2007 Nov 20
0
4 commits - libswfdec/swfdec_movie.c libswfdec/swfdec_movie.h libswfdec/swfdec_resource.c test/image test/trace
...e, cairo_matrix_t *matrix)
+{
+ g_return_if_fail (SWFDEC_IS_MOVIE (movie));
+ g_return_if_fail (matrix != NULL);
+
+ cairo_matrix_init_identity (matrix);
+ while (movie) {
+ cairo_matrix_multiply (matrix, &movie->inverse_matrix, matrix);
+ movie = movie->parent;
+ }
+}
+
+void
+swfdec_movie_local_to_global_matrix (SwfdecMovie *movie, cairo_matrix_t *matrix)
+{
+ g_return_if_fail (SWFDEC_IS_MOVIE (movie));
+ g_return_if_fail (matrix != NULL);
+
+ cairo_matrix_init_identity (matrix);
+ while (movie) {
+ cairo_matrix_multiply (matrix, matrix, &movie->matrix);
+ movie = movie->parent;
+ }
+...
2008 Jan 02
0
3 commits - libswfdec/swfdec_movie.c test/trace
...ovie_render (SwfdecMovie *movie, cairo_t *cr,
cairo_pattern_t *mask;
if (movie->parent == movie->masked_by->parent) {
cairo_transform (cr, &movie->inverse_matrix);
+ rect = *inval;
} else {
- cairo_matrix_t mat;
+ cairo_matrix_t mat, mat2;
swfdec_movie_local_to_global_matrix (movie, &mat);
+ swfdec_movie_global_to_local_matrix (movie->masked_by, &mat2);
+ cairo_matrix_multiply (&mat, &mat2, &mat);
cairo_transform (cr, &mat);
- swfdec_movie_global_to_local_matrix (movie->masked_by, &mat);
- cairo_transform (cr...
2007 Dec 10
0
6 commits - libswfdec/Makefile.am libswfdec/swfdec_as_interpret.c libswfdec/swfdec_color_as.c libswfdec/swfdec_graphic_movie.c libswfdec/swfdec_image_decoder.c libswfdec/swfdec_morph_movie.c libswfdec/swfdec_movie_as_drawing.c
...st be called
+ * before changing the movie or the output will have artifacts.
+ **/
+void
+swfdec_movie_invalidate_last (SwfdecMovie *movie)
+{
+ cairo_matrix_t matrix;
+
+ g_return_if_fail (SWFDEC_IS_MOVIE (movie));
+
+ if (movie->invalidate_last)
+ return;
+
+ if (movie->parent)
+ swfdec_movie_local_to_global_matrix (movie->parent, &matrix);
+ else
+ cairo_matrix_init_identity (&matrix);
+ swfdec_movie_invalidate (movie, &matrix, FALSE);
+ g_assert (movie->invalidate_last);
+}
+
+/**
+ * swfdec_movie_invalidate_last_next:
+ * @movie: a #SwfdecMovie
+ *
+ * Ensures the movie will be inva...
2007 Nov 20
0
7 commits - libswfdec/swfdec_movie.c libswfdec/swfdec_sprite_movie_as.c test/image
...rix)
cairo_matrix_init_identity (matrix);
while (movie) {
+ if (movie->cache_state >= SWFDEC_MOVIE_INVALID_MATRIX)
+ swfdec_movie_update (movie);
cairo_matrix_multiply (matrix, &movie->inverse_matrix, matrix);
movie = movie->parent;
}
@@ -584,6 +586,8 @@ swfdec_movie_local_to_global_matrix (SwfdecMovie *movie, cairo_matrix_t *matrix)
cairo_matrix_init_identity (matrix);
while (movie) {
+ if (movie->cache_state >= SWFDEC_MOVIE_INVALID_MATRIX)
+ swfdec_movie_update (movie);
cairo_matrix_multiply (matrix, matrix, &movie->matrix);
movie = movie->...