Contains matrix native API.
Protected Static Methods | |
static intptr | create (float m11, float m12, float m21, float m22, float dx, float dy) |
Create a matrix with the specified elements. | |
static void | destroy (intptr handle) |
Destroys the matrix. | |
static std::vector< float > | elenents (intptr handle) |
Gets an array of floating-point values that represents the elements of the matrix. | |
static bool | is_identity (intptr handle) |
Gets a value indicating whether the matrix is the identity matrix. | |
static bool | is_invertible (intptr handle) |
Gets a value indicating whether the matrix is invertible. | |
static void | invert (intptr handle) |
Inverts the matrix, if it is invertible. | |
static float | offset_x (intptr handle) |
Gets the x translation value (the dx value, or the element in the third row and first column) of the matrix. | |
static float | offset_y (intptr handle) |
Gets the y translation value (the dx value, or the element in the third row and first column) of the matrix. | |
static void | multiply (intptr handle, intptr matrix, int32 order) |
Multiplies this xtd::drawing::drawing_2d::matrix by the matrix specified in the matrix parameter, and in the order specified in the order parameter. | |
static void | reset (intptr handle) |
Resets the matrix to have the elements of the identity matrix. | |
static void | rotate (intptr handle, float angle, int32 order) |
repend to the matrix a clockwise rotation, around the origin and by the specified angle. | |
static void | rotate_at (intptr handle, float angle, float x, float y, int32 order) |
Applies a clockwise rotation to the matrix around the point specified in the point parameter, and by prepending the rotation. | |
static void | scale (intptr handle, float scale_x, float scale_y, int32 order) |
Applies the specified scale vector (scale_x and scale_y) to this xtd::drawing::drawing_2d::matrix using the specified order. | |
static void | shear (intptr handle, float scale_x, float scale_y, int32 order) |
Applies the specified shear vector to the matrix in the specified order. | |
static void | transform_point (intptr handle, int32 &x, int32 &y) |
Applies the geometric transform represented by the matrix to a specified array of points. | |
static void | transform_point (intptr handle, float &x, float &y) |
Applies the geometric transform represented by the matrix to a specified array of points. | |
static void | transform_vectors (intptr handle, std::vector< xtd::collections::generic::key_value_pair< int32, int32 > > &points) |
Applies only the scale and rotate components of the matrix to the specified array of points. | |
static void | transform_vectors (intptr handle, std::vector< xtd::collections::generic::key_value_pair< float, float > > &points) |
Applies only the scale and rotate components of the matrix to the specified array of points. | |
static void | translate (intptr handle, float offset_x, float offset_y, int32 order) |
Applies the specified translation vector (offset_x and offset_y) to the matrix in the specified order. | |
static void | vector_transform_points (intptr handle, std::vector< xtd::collections::generic::key_value_pair< int32, int32 > > &points) |
Multiplies each vector in an array by the matrix. The translation elements of this matrix (third row) are ignored. | |
|
staticprotected |
Create a matrix with the specified elements.
m11 | The value in the first row and first column of the matrix. |
m12 | The value in the first row and second column of the matrix. |
m21 | The value in the second row and first column of the matrix. |
m22 | The value in the second row and second column of the matrix. |
dx | The value in the third row and first column of the matrix. |
dy | The value in the third row and second column of the matrix. |
|
staticprotected |
Destroys the matrix.
handle | The matrix handle to destroy. |
|
staticprotected |
Gets an array of floating-point values that represents the elements of the matrix.
handle | The matrix handle. |
|
staticprotected |
Gets a value indicating whether the matrix is the identity matrix.
handle | The matrix handle. |
|
staticprotected |
Gets a value indicating whether the matrix is invertible.
handle | The matrix handle. |
|
staticprotected |
Inverts the matrix, if it is invertible.
handle | The matrix handle. |
|
staticprotected |
Gets the x translation value (the dx value, or the element in the third row and first column) of the matrix.
handle | The matrix handle. |
|
staticprotected |
Gets the y translation value (the dx value, or the element in the third row and first column) of the matrix.
handle | The matrix handle. |
|
staticprotected |
Multiplies this xtd::drawing::drawing_2d::matrix by the matrix specified in the matrix parameter, and in the order specified in the order parameter.
handle | The matrix handle. |
matrix | The matrix handle by which the matrix is to be multiplied. |
order | The value that represents the order (see matrix_orders.h for more information). |
|
staticprotected |
Resets the matrix to have the elements of the identity matrix.
handle | The matrix handle. |
|
staticprotected |
repend to the matrix a clockwise rotation, around the origin and by the specified angle.
handle | The matrix handle. |
angle | The angle of the rotation, in degrees. |
order | The value that represents the order (see matrix_orders.h for more information). |
|
staticprotected |
Applies a clockwise rotation to the matrix around the point specified in the point parameter, and by prepending the rotation.
handle | The matrix handle. |
angle | The angle (extent) of the rotation, in degrees. |
x | The x-coordinate of the point that represents the center of the rotation. |
y | The y-coordinate of the point that represents the center of the rotation. |
order | The value that represents the order (see matrix_orders.h for more information). |
|
staticprotected |
Applies the specified scale vector (scale_x and scale_y) to this xtd::drawing::drawing_2d::matrix using the specified order.
handle | The matrix handle. |
scale_x | The value by which to scale this xtd::drawing::drawing_2d::matrix in the x-axis direction. |
scale_y | The value by which to scale this xtd::drawing::drawing_2d::matrix in the y-axis direction. |
order | A value that specifies the order (append or prepend) in which the scale vector is applied to the matrix (see matrix_orders.h for more information). |
|
staticprotected |
Applies the specified shear vector to the matrix in the specified order.
handle | The matrix handle. |
scale_x | The horizontal shear factor. |
scale_y | The vertical shear factor. |
order | A xvalue that specifies the order (append or prepend) in which the shear is applied (see matrix_orders.h for more information). |
|
staticprotected |
Applies the geometric transform represented by the matrix to a specified array of points.
handle | The matrix handle. |
x | The x-coordinate of the point that represents the point to transform. |
y | The y-coordinate of the point that represents the point to transform. |
|
staticprotected |
Applies the geometric transform represented by the matrix to a specified array of points.
handle | The matrix handle. |
x | The x-coordinate of the point that represents the point to transform. |
y | The y-coordinate of the point that represents the point to transform. |
|
staticprotected |
Applies only the scale and rotate components of the matrix to the specified array of points.
handle | The matrix handle. |
x | An array of xtd::collections::generic::key_value_pair<int32, int32>t structures that represents the points to transform. |
|
staticprotected |
Applies only the scale and rotate components of the matrix to the specified array of points.
handle | The matrix handle. |
x | An array of xtd::collections::generic::key_value_pair<int32, int32>t structures that represents the points to transform. |
|
staticprotected |
Applies the specified translation vector (offset_x and offset_y) to the matrix in the specified order.
handle | The matrix handle. |
offset_x | The x value by which to translate the matrix. |
offset_y | The y value by which to translate the matrix. |
order | A value that specifies the order (append or prepend) in which the translation is applied to the matrix. |
|
staticprotected |
Multiplies each vector in an array by the matrix. The translation elements of this matrix (third row) are ignored.
handle | The matrix handle. |
points | An array of xtd::collections::generic::key_value_pair<int32, int32> structures that represents the points to transform. |