git.asbjorn.biz
/
swftools.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
changed line width algorithm.
[swftools.git]
/
lib
/
modules
/
swfrender.c
diff --git
a/lib/modules/swfrender.c
b/lib/modules/swfrender.c
index
552fd1f
..
e5775bc
100644
(file)
--- a/
lib/modules/swfrender.c
+++ b/
lib/modules/swfrender.c
@@
-182,10
+182,17
@@
static void add_solidline(RENDERBUF*buf, double x1, double y1, double x2, double
double lastx,lasty;
double vx,vy;
double xx,yy;
double lastx,lasty;
double vx,vy;
double xx,yy;
-
- /* The Flash Player does this, too. This means every line is always at least
- one pixel wide */
+
+ /* Make sure the line is always at least one pixel wide */
+#ifdef LINEMODE1
+ /* That's what Macromedia's Player does at least at zoom level >= 1. */
width += 20;
width += 20;
+#else
+ /* That's what Macromedia's Player seems to do at zoom level 0. */
+ /* TODO: needs testing */
+ if(width<20)
+ width = 20;
+#endif
sd = (double)dx*(double)dx+(double)dy*(double)dy;
d = sqrt(sd);
sd = (double)dx*(double)dx+(double)dy*(double)dy;
d = sqrt(sd);
@@
-423,7
+430,7
@@
void swf_RenderShape(RENDERBUF*dest, SHAPE2*shape, MATRIX*m, CXFORM*c, U16 _dept
nm.r1 *= i->multiply;
nm.tx *= i->multiply;
nm.ty *= i->multiply;
nm.r1 *= i->multiply;
nm.tx *= i->multiply;
nm.ty *= i->multiply;
- s2->fillstyles[t].m = nm; //!!!!!!!!!!!!!!!!
+ s2->fillstyles[t].m = nm;
}
/* add this shape to the global shape list, for deallocing */
}
/* add this shape to the global shape list, for deallocing */
@@
-484,7
+491,7
@@
void swf_RenderShape(RENDERBUF*dest, SHAPE2*shape, MATRIX*m, CXFORM*c, U16 _dept
if(DEBUG&4) printf("\n");
} else if(line->type == splineTo) {
if(DEBUG&4) printf("\n");
} else if(line->type == splineTo) {
- int c,t,y,parts,qparts;
+ int c,t,parts,qparts;
double xx,yy;
transform_point(&mat, x, y, &x1, &y1);
double xx,yy;
transform_point(&mat, x, y, &x1, &y1);