[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Gnash-commit] gnash ChangeLog testsuite/misc-ming.all/shape_t...
From: |
Sandro Santilli |
Subject: |
[Gnash-commit] gnash ChangeLog testsuite/misc-ming.all/shape_t... |
Date: |
Wed, 07 Nov 2007 21:42:41 +0000 |
CVSROOT: /sources/gnash
Module name: gnash
Changes by: Sandro Santilli <strk> 07/11/07 21:42:41
Modified files:
. : ChangeLog
testsuite/misc-ming.all: shape_test.c
Log message:
* testsuite/misc-ming.all/shape_test.c: add Udog's drawing, both
non-explicitly closed; one using left fill (the one on the
left)
and one using right fill (the one on the right).
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/gnash/ChangeLog?cvsroot=gnash&r1=1.4796&r2=1.4797
http://cvs.savannah.gnu.org/viewcvs/gnash/testsuite/misc-ming.all/shape_test.c?cvsroot=gnash&r1=1.4&r2=1.5
Patches:
Index: ChangeLog
===================================================================
RCS file: /sources/gnash/gnash/ChangeLog,v
retrieving revision 1.4796
retrieving revision 1.4797
diff -u -b -r1.4796 -r1.4797
--- ChangeLog 7 Nov 2007 17:25:04 -0000 1.4796
+++ ChangeLog 7 Nov 2007 21:42:40 -0000 1.4797
@@ -1,5 +1,8 @@
2007-11-07 Sandro Santilli <address@hidden>
+ * testsuite/misc-ming.all/shape_test.c: add Udog's drawing, both
+ non-explicitly closed; one using left fill (the one on the left)
+ and one using right fill (the one on the right).
* testsuite/misc-ming.all/ming_utils.c (get_dejagnu_actions): don't
use printf to write the code into a buffer, just make the code a
const static const C-string.
Index: testsuite/misc-ming.all/shape_test.c
===================================================================
RCS file: /sources/gnash/gnash/testsuite/misc-ming.all/shape_test.c,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -b -r1.4 -r1.5
--- testsuite/misc-ming.all/shape_test.c 1 Jul 2007 10:55:06 -0000
1.4
+++ testsuite/misc-ming.all/shape_test.c 7 Nov 2007 21:42:41 -0000
1.5
@@ -17,10 +17,11 @@
*/
/*
- * Try to add variables to shapes, observed behavior is that variables are
added
- * to _root accidently.
+ * (1) Verify that shapes can not hold variables, but rather evaluates to
their
+ * containing sprite when referenced by name.
+ *
+ * (2) See effects of inconsistent drawing
*
- * TODO: verify this!
*/
#include <stdlib.h>
@@ -105,6 +106,8 @@
check_equals(mo, "sh2._x", "400");
check_equals(mo, "_root._x", "400");
+ add_actions(mo, "_root._x = 0;" ); /* cleanup */
+
// Do these checks mean that shapes are *not* movieclips?
check_equals(mo, "typeof(sh1.getDepth())", "'undefined'");
check_equals(mo, "typeof(sh2.getDepth())", "'undefined'");
@@ -113,6 +116,59 @@
check_equals(mo, "typeof(getInstanceAtDepth(-16381))", "'undefined'");
check_equals(mo, "typeof(getInstanceAtDepth(-16380))", "'undefined'");
+ SWFMovie_nextFrame(mo);
+
+ /*
+ * UdoG's drawing
+ *
+ * See DrawingApiTest.as (inv8)
+ *
+ */
+ { /* using left fill */
+ SWFDisplayItem it;
+ SWFShape sh = newSWFShape();
+ SWFMovieClip mc = newSWFMovieClip();
+ SWFShape_setLineStyle(sh, 1, 0, 0, 0, 255);
+ SWFShape_setLeftFillStyle(sh, SWFShape_addSolidFillStyle(sh, 0, 255, 0,
255));
+ SWFShape_movePenTo(sh, 20, 10); /* 0 */
+ SWFShape_drawLineTo(sh, 40, 10); /* 1 */
+ SWFShape_drawLineTo(sh, 40, 40); /* 2 */
+ SWFShape_drawLineTo(sh, 20, 40); /* 3 */
+ SWFShape_drawLineTo(sh, 20, 10); /* 4 */
+ SWFShape_drawLineTo(sh, 10, 10); /* 5 */
+ SWFShape_drawLineTo(sh, 10, 20); /* 6 */
+ SWFShape_drawLineTo(sh, 30, 20); /* 7 */
+ SWFShape_drawLineTo(sh, 30, 30); /* 8 */
+ SWFShape_drawLineTo(sh, 20, 30); /* 9 */
+ it = SWFMovieClip_add(mc, (SWFBlock)sh);
+ SWFDisplayItem_moveTo(it, 80, 150);
+ SWFDisplayItem_scale(it, 2, 2);
+ SWFMovieClip_nextFrame(mc);
+ it = SWFMovie_add(mo, (SWFBlock)mc);
+ }
+ { /* using right fill */
+ SWFDisplayItem it;
+ SWFShape sh = newSWFShape();
+ SWFMovieClip mc = newSWFMovieClip();
+ SWFShape_setLineStyle(sh, 1, 0, 0, 0, 255);
+ SWFShape_setLeftFillStyle(sh, SWFShape_addSolidFillStyle(sh, 0, 255, 0,
255));
+ SWFShape_movePenTo(sh, 20, 10); /* 0 */
+ SWFShape_drawLineTo(sh, 40, 10); /* 1 */
+ SWFShape_drawLineTo(sh, 40, 40); /* 2 */
+ SWFShape_drawLineTo(sh, 20, 40); /* 3 */
+ SWFShape_drawLineTo(sh, 20, 10); /* 4 */
+ SWFShape_drawLineTo(sh, 10, 10); /* 5 */
+ SWFShape_drawLineTo(sh, 10, 20); /* 6 */
+ SWFShape_drawLineTo(sh, 30, 20); /* 7 */
+ SWFShape_drawLineTo(sh, 30, 30); /* 8 */
+ SWFShape_drawLineTo(sh, 20, 30); /* 9 */
+ it = SWFMovieClip_add(mc, (SWFBlock)sh);
+ SWFDisplayItem_moveTo(it, 500, 150);
+ SWFDisplayItem_scale(it, 2, 2);
+ SWFMovieClip_nextFrame(mc);
+ it = SWFMovie_add(mo, (SWFBlock)mc);
+ }
+
add_actions(mo, "_root.totals(); stop();");
SWFMovie_nextFrame(mo);
- [Gnash-commit] gnash ChangeLog testsuite/misc-ming.all/shape_t...,
Sandro Santilli <=