mirror of
https://gitlab.freedesktop.org/cairo/cairo.git
synced 2025-12-28 00:30:12 +01:00
Added XrMatrixGetAffine
This commit is contained in:
parent
1fc2dabbd0
commit
a18f4ea75b
3 changed files with 22 additions and 0 deletions
|
|
@ -1,5 +1,8 @@
|
|||
2003-07-03 Carl Worth <cworth@isi.edu>
|
||||
|
||||
* src/xrmatrix.c (XrMatrixGetAffine): Added XrMatrixGetAffine
|
||||
(from Soorya Kuloor)
|
||||
|
||||
* src/xr.c (XrGetAlpha): Added XrGetAlpha
|
||||
(XrGetRGBColor): Added XrGetRGBColor
|
||||
|
||||
|
|
|
|||
6
src/Xr.h
6
src/Xr.h
|
|
@ -443,6 +443,12 @@ XrMatrixSetAffine (XrMatrix *xrs,
|
|||
double c, double d,
|
||||
double tx, double ty);
|
||||
|
||||
XrStatus
|
||||
XrMatrixGetAffine (XrMatrix *matrix,
|
||||
double *a, double *b,
|
||||
double *c, double *d,
|
||||
double *tx, double *ty);
|
||||
|
||||
XrStatus
|
||||
XrMatrixTranslate (XrMatrix *matrix, double tx, double ty);
|
||||
|
||||
|
|
|
|||
|
|
@ -104,6 +104,19 @@ XrMatrixSetAffine (XrMatrix *matrix,
|
|||
return XrStatusSuccess;
|
||||
}
|
||||
|
||||
XrStatus
|
||||
XrMatrixGetAffine (XrMatrix *matrix,
|
||||
double *a, double *b,
|
||||
double *c, double *d,
|
||||
double *tx, double *ty)
|
||||
{
|
||||
*a = matrix->m[0][0]; *b = matrix->m[0][1];
|
||||
*c = matrix->m[1][0]; *d = matrix->m[1][1];
|
||||
*tx = matrix->m[2][0]; *ty = matrix->m[2][1];
|
||||
|
||||
return XrStatusSuccess;
|
||||
}
|
||||
|
||||
XrStatus
|
||||
_XrMatrixSetTranslate(XrMatrix *matrix,
|
||||
double tx, double ty)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue