|
From: <hba...@us...> - 2009-07-19 01:59:09
|
Revision: 10161
http://plplot.svn.sourceforge.net/plplot/?rev=10161&view=rev
Author: hbabcock
Date: 2009-07-19 01:59:08 +0000 (Sun, 19 Jul 2009)
Log Message:
-----------
Units are PI/2 not 2/PI. Also change to using the PLplot constant PI instead of 3.14159
Modified Paths:
--------------
trunk/drivers/cairo.c
Modified: trunk/drivers/cairo.c
===================================================================
--- trunk/drivers/cairo.c 2009-07-19 01:54:46 UTC (rev 10160)
+++ trunk/drivers/cairo.c 2009-07-19 01:59:08 UTC (rev 10161)
@@ -332,7 +332,7 @@
(double)pls->cmap0[0].r/255.0,
(double)pls->cmap0[0].g/255.0,
(double)pls->cmap0[0].b/255.0);
- cairo_fill(aStream->cairoContext);
+ cairo_fill(aStream->cairoContext);
}
/*---------------------------------------------------------------------
@@ -620,7 +620,7 @@
/* Set up the clipping region if we are doing text clipping */
if(aStream->text_clipping){
cairo_save(aStream->cairoContext);
- diorot_rad = pls->diorot * 2.0/3.14159;
+ diorot_rad = pls->diorot * PI/2.0;
rotate_cairo_surface(pls,
cos(diorot_rad),
sin(diorot_rad),
@@ -647,7 +647,7 @@
/* Extract rotation angle and shear from the PLplot tranformation matrix.
Compute sines and cosines of the angles as an optimization. */
plRotationShear(args->xform, &rotation, &shear, &stride);
- rotation -= pls->diorot * 3.14159 / 2.0;
+ rotation -= pls->diorot * PI / 2.0;
cos_rot = cos(rotation);
sin_rot = sin(rotation);
cos_shear = cos(shear);
@@ -754,7 +754,7 @@
/* Extract rotation angle and shear from the PLplot tranformation matrix.
Compute sines and cosines of the angles as an optimization. */
plRotationShear(args->xform, &rotation, &shear, &stride);
- rotation -= pls->diorot * 3.14159 / 2.0;
+ rotation -= pls->diorot * PI / 2.0;
cos_rot = cos(rotation);
sin_rot = sin(rotation);
cos_shear = cos(shear);
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|