From: ellson Date: Tue, 18 Oct 2005 18:59:11 +0000 (+0000) Subject: add comment about why wrong initializations is OK X-Git-Tag: LAST_LIBGRAPH~32^2~7191 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=533fa1def82c8e4bb1f003225521f4b02575231b;p=graphviz add comment about why wrong initializations is OK --- diff --git a/lib/common/geom.c b/lib/common/geom.c index e39cf6f33..91d5d04fb 100644 --- a/lib/common/geom.c +++ b/lib/common/geom.c @@ -355,6 +355,8 @@ static pointf rotatepf(pointf p, int cwrot) static int last_cwrot; pointf P; + /* cosa is initially wrong for a cwrot of 0 + * this caching only works because we are never called for 0 rotations */ if (cwrot != last_cwrot) { sincos(cwrot / (2 * M_PI), &sina, &cosa); last_cwrot = cwrot;