mirror of
https://gitlab.freedesktop.org/cairo/cairo.git
synced 2025-12-24 21:50:19 +01:00
166 lines
2.2 KiB
Text
166 lines
2.2 KiB
Text
<!-- ##### SECTION Title ##### -->
|
|
cairo_matrix_t
|
|
|
|
<!-- ##### SECTION Short_Description ##### -->
|
|
Generic matrix operations
|
|
|
|
<!-- ##### SECTION Long_Description ##### -->
|
|
<para>
|
|
#cairo_matrix_t is used throughout cairo to convert between different
|
|
coordinate spaces. A #cairo_matrix_t holds an affine transformation,
|
|
such as a scale, rotation, shear, or a combination of these.
|
|
The transformation of a point (<literal>x</literal>,<literal>y</literal>)
|
|
is given by:
|
|
</para>
|
|
<programlisting>
|
|
x_new = xx * x + xy * y + x0;
|
|
y_new = yx * x + yy * y + y0;
|
|
</programlisting>
|
|
<para>
|
|
The current transformation matrix of a #cairo_t, represented as a
|
|
#cairo_matrix_t, defines the transformation from user-space
|
|
coordinates to device-space coordinates. See cairo_get_matrix() and
|
|
cairo_set_matrix().
|
|
</para>
|
|
|
|
<!-- ##### SECTION See_Also ##### -->
|
|
<para>
|
|
<itemizedlist>
|
|
<listitem>#cairo_t</listitem>
|
|
</itemizedlist>
|
|
</para>
|
|
|
|
<!-- ##### SECTION Stability_Level ##### -->
|
|
|
|
|
|
<!-- ##### STRUCT cairo_matrix_t ##### -->
|
|
<para>
|
|
|
|
</para>
|
|
|
|
@xx:
|
|
@yx:
|
|
@xy:
|
|
@yy:
|
|
@x0:
|
|
@y0:
|
|
|
|
<!-- ##### FUNCTION cairo_matrix_init ##### -->
|
|
<para>
|
|
|
|
</para>
|
|
|
|
@matrix:
|
|
@xx:
|
|
@yx:
|
|
@xy:
|
|
@yy:
|
|
@x0:
|
|
@y0:
|
|
|
|
|
|
<!-- ##### FUNCTION cairo_matrix_init_identity ##### -->
|
|
<para>
|
|
|
|
</para>
|
|
|
|
@matrix:
|
|
|
|
|
|
<!-- ##### FUNCTION cairo_matrix_init_translate ##### -->
|
|
<para>
|
|
|
|
</para>
|
|
|
|
@matrix:
|
|
@tx:
|
|
@ty:
|
|
|
|
|
|
<!-- ##### FUNCTION cairo_matrix_init_scale ##### -->
|
|
<para>
|
|
|
|
</para>
|
|
|
|
@matrix:
|
|
@sx:
|
|
@sy:
|
|
|
|
|
|
<!-- ##### FUNCTION cairo_matrix_init_rotate ##### -->
|
|
<para>
|
|
|
|
</para>
|
|
|
|
@matrix:
|
|
@radians:
|
|
|
|
|
|
<!-- ##### FUNCTION cairo_matrix_translate ##### -->
|
|
<para>
|
|
|
|
</para>
|
|
|
|
@matrix:
|
|
@tx:
|
|
@ty:
|
|
|
|
|
|
<!-- ##### FUNCTION cairo_matrix_scale ##### -->
|
|
<para>
|
|
|
|
</para>
|
|
|
|
@matrix:
|
|
@sx:
|
|
@sy:
|
|
|
|
|
|
<!-- ##### FUNCTION cairo_matrix_rotate ##### -->
|
|
<para>
|
|
|
|
</para>
|
|
|
|
@matrix:
|
|
@radians:
|
|
|
|
|
|
<!-- ##### FUNCTION cairo_matrix_invert ##### -->
|
|
<para>
|
|
|
|
</para>
|
|
|
|
@matrix:
|
|
@Returns:
|
|
|
|
|
|
<!-- ##### FUNCTION cairo_matrix_multiply ##### -->
|
|
<para>
|
|
|
|
</para>
|
|
|
|
@result:
|
|
@a:
|
|
@b:
|
|
|
|
|
|
<!-- ##### FUNCTION cairo_matrix_transform_distance ##### -->
|
|
<para>
|
|
|
|
</para>
|
|
|
|
@matrix:
|
|
@dx:
|
|
@dy:
|
|
|
|
|
|
<!-- ##### FUNCTION cairo_matrix_transform_point ##### -->
|
|
<para>
|
|
|
|
</para>
|
|
|
|
@matrix:
|
|
@x:
|
|
@y:
|
|
|
|
|