1 #############################################################################
2 ## Name: XS/GraphicsMatrix.xs
3 ## Purpose: XS for Wx::GraphicsMatrix
4 ## Author: Klaas Hartmann
7 ## RCS-ID: $Id: GraphicsMatrix.xs 2110 2007-08-03 19:20:51Z mbarbon $
8 ## Copyright: (c) 2007 Klaas Hartmann
9 ## Licence: This program is free software; you can redistribute it and/or
10 ## modify it under the same terms as Perl itself
11 #############################################################################
13 #if wxUSE_GRAPHICS_CONTEXT
15 #include <wx/graphics.h>
17 MODULE=Wx PACKAGE=Wx::GraphicsMatrix
20 wxGraphicsMatrix::Concat ( t )
24 wxGraphicsMatrix::Get ( )
26 wxDouble a, b, c, d, tx, ty;
28 THIS->Get( &a, &b, &c, &d, &tx, &ty );
30 PUSHs( sv_2mortal( newSVnv( a ) ) );
31 PUSHs( sv_2mortal( newSVnv( b ) ) );
32 PUSHs( sv_2mortal( newSVnv( c ) ) );
33 PUSHs( sv_2mortal( newSVnv( d ) ) );
34 PUSHs( sv_2mortal( newSVnv( tx ) ) );
35 PUSHs( sv_2mortal( newSVnv( ty ) ) );
38 wxGraphicsMatrix::Invert ()
41 wxGraphicsMatrix::IsEqual ( t )
46 wxGraphicsMatrix::IsIdentity ()
49 wxGraphicsMatrix::Rotate (angle)
53 wxGraphicsMatrix::Scale (xScale, yScale)
58 wxGraphicsMatrix::Translate (dx, dy)
63 wxGraphicsMatrix::Set (a, b, c, d, tx, ty)
72 wxGraphicsMatrix::TransformPoint ( x, y )
76 wxDouble x_out, y_out;
80 THIS->TransformPoint( &x, &y );
82 PUSHs( sv_2mortal( newSVnv( x ) ) );
83 PUSHs( sv_2mortal( newSVnv( y ) ) );
86 wxGraphicsMatrix::TransformDistance ( dx, dy )
90 wxDouble dx_out, dy_out;
94 THIS->TransformDistance( &dx, &dy );
96 PUSHs( sv_2mortal( newSVnv( dx ) ) );
97 PUSHs( sv_2mortal( newSVnv( dy ) ) );