mirror of
https://github.com/michaelrsweet/pdfio.git
synced 2024-12-27 05:48:20 +01:00
Fix pdfioContentMatrixRotate function.
This commit is contained in:
parent
acea6fdbed
commit
1a17933635
@ -8,6 +8,7 @@ v1.1.0 (Month DD, YYYY)
|
|||||||
- Added `pdfioFileCreateTemporary` function (Issue #29)
|
- Added `pdfioFileCreateTemporary` function (Issue #29)
|
||||||
- Added `pdfioDictIterateKeys` function (Issue #31)
|
- Added `pdfioDictIterateKeys` function (Issue #31)
|
||||||
- Fixed "install-shared" target (Issue #32)
|
- Fixed "install-shared" target (Issue #32)
|
||||||
|
- Fixed `pdfioContentMatrixRotate` function.
|
||||||
|
|
||||||
|
|
||||||
v1.0.1 (March 2, 2022)
|
v1.0.1 (March 2, 2022)
|
||||||
|
@ -489,8 +489,11 @@ pdfioContentMatrixRotate(
|
|||||||
pdfio_stream_t *st, // I - Stream
|
pdfio_stream_t *st, // I - Stream
|
||||||
double degrees) // I - Rotation angle in degrees counter-clockwise
|
double degrees) // I - Rotation angle in degrees counter-clockwise
|
||||||
{
|
{
|
||||||
double dcos = cos(degrees / M_PI); // Cosine
|
double dcos = cos(M_PI * degrees / 180.0);
|
||||||
double dsin = sin(degrees / M_PI); // Sine
|
// Cosine
|
||||||
|
double dsin = sin(M_PI * degrees / 180.0);
|
||||||
|
// Sine
|
||||||
|
|
||||||
|
|
||||||
return (pdfioStreamPrintf(st, "%g %g %g %g 0 0 cm\n", dcos, -dsin, dsin, dcos));
|
return (pdfioStreamPrintf(st, "%g %g %g %g 0 0 cm\n", dcos, -dsin, dsin, dcos));
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user