L_MATRIX

Summary

Represents a 3x3 affine transformation matrix used for transformations in 2-D space.

Syntax

struct L_MATRIX 
{ 
   L_DOUBLE m11; 
   L_DOUBLE m12; 
   L_DOUBLE m21; 
   L_DOUBLE m22; 
   L_DOUBLE offsetX; 
   L_DOUBLE offsetY; 
   L_INT type; 
   L_INT padding; 
}; 
typedef struct L_MATRIX L_MATRIX; 

Members

m11

The value of the first row and first column.

m12

The value of the first row and second column.

m21

The value of the second row and first column.

m22

The value of the second row and second column.

offsetX

The x translation value (the dx value, or the element in the third row and first column).

offsetY

The y translation value (the dy value, or the element in the third row and second column).

type

Internal use only.

padding

Internal use only.

Comments

3x3 matrix is used for transformations in a 2-D x-y plane. Affine transformation matrices can be multiplied to form any number of linear transformations, such as rotation and skew (shear), followed by translation. An affine transformation matrix has its final column equal to (0, 0, 1), so only the members in the first two columns need to be specified. Note that vectors are expressed as row-vectors, not column vectors.

The L_MATRIX is stored using row-major order and has the following structure:

image\matrix.jpg

members in the last row, offsetX and offsetY, represent translation values.

In functions and structure members, the transformation matrix is usually specified as a vector with only six members, as follows:

(m11, m12, m21, m22, offsetX, offsetY)

Usage

Data Types

Functions

Help Version 23.0.2024.2.29
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2024 LEAD Technologies, Inc. All Rights Reserved.

LEADTOOLS Raster Imaging C API Help
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2023 LEAD Technologies, Inc. All Rights Reserved.