aboutsummaryrefslogtreecommitdiff
path: root/generic/Arc.c
diff options
context:
space:
mode:
authorlecoanet2002-11-05 09:54:21 +0000
committerlecoanet2002-11-05 09:54:21 +0000
commit6c6143e5585858de97480bcd0db69971540a83fc (patch)
tree55ae4a96b1537a4b43707d633da9bfb73d056f13 /generic/Arc.c
parente7608f72cc5d4ebb429f18d6d6b609f35986111a (diff)
downloadtkzinc-6c6143e5585858de97480bcd0db69971540a83fc.zip
tkzinc-6c6143e5585858de97480bcd0db69971540a83fc.tar.gz
tkzinc-6c6143e5585858de97480bcd0db69971540a83fc.tar.bz2
tkzinc-6c6143e5585858de97480bcd0db69971540a83fc.tar.xz
Corrections suite aux changements des structures ZnPoly et ZnTristrip.
Ajout du param�tre controls � la m�thode Coords.
Diffstat (limited to 'generic/Arc.c')
-rw-r--r--generic/Arc.c23
1 files changed, 15 insertions, 8 deletions
diff --git a/generic/Arc.c b/generic/Arc.c
index 53d6367..155bc06 100644
--- a/generic/Arc.c
+++ b/generic/Arc.c
@@ -1599,17 +1599,21 @@ GetClipVertices(Item item,
ZnTriStrip *tristrip)
{
ArcItem arc = (ArcItem) item;
-
- if (ISCLEAR(arc->flags, USING_POLY_BIT)) {
+ ZnPoint center;
+
+ if (ISCLEAR(arc->flags, USING_POLY_BIT) || !arc->render_shape) {
UpdateRenderShapeX(arc);
SET(arc->flags, USING_POLY_BIT);
}
- TRI_STRIP1(tristrip, ZnListArray(arc->render_shape),
- ZnListSize(arc->render_shape));
- tristrip->fan = True;
- tristrip->center.x = (item->item_bounding_box.corner.x + item->item_bounding_box.orig.x) / 2.0;
- tristrip->center.y = (item->item_bounding_box.corner.y + item->item_bounding_box.orig.y) / 2.0;
+
+ center.x = (item->item_bounding_box.corner.x + item->item_bounding_box.orig.x) / 2.0;
+ center.y = (item->item_bounding_box.corner.y + item->item_bounding_box.orig.y) / 2.0;
+ ZnListEmpty(item->wi->work_pts);
+ ZnListAdd(item->wi->work_pts, &center, ZnListTail);
+ ZnListAppend(item->wi->work_pts, arc->render_shape);
+ TRI_STRIP1(tristrip, ZnListArray(item->wi->work_pts),
+ ZnListSize(item->wi->work_pts), True);
return False;
}
@@ -1636,7 +1640,9 @@ GetContours(Item item,
POLY_CONTOUR1(poly, ZnListArray(arc->render_shape),
ZnListSize(arc->render_shape));
-
+ poly->contour1.cw = 1;
+ poly->contour1.controls = NULL;
+
return False;
}
@@ -1655,6 +1661,7 @@ Coords(Item item,
int index,
int cmd,
ZnPoint **pts,
+ char **controls,
int *num_pts)
{
ArcItem arc = (ArcItem) item;