Herror ::hom_mat2d_scale (
    const HTuple &HomMat2D,
    const HTuple &Sx,
    const HTuple &Sy,
    const HTuple &Px,
    const HTuple &Py,
    HTuple *HomMat2DScale
)

Add a scaling to a homogeneous 2D transformation matrix.

::hom_mat2d_scale adds a scaling by the scale factors Sx and Sy to a homogeneous 2D transformation matrix HomMat2D. The point (Px,Py) is the fixed point of the transformation. The resulting matrix is returned in HomMat2DScale.


Parameters

HomMat2D (input_control)
affine2d-array -> HTuple.double
Input transformation matrix.
Number of elements: 6

Sx (input_control)
number -> HTuple.double / long
Scale factor along the x-axis.
Default value: 2
Suggested values: 0.125, 0.25, 0.5, 1, 2, 4, 8, 16
Typical range of values: 0 <= Sx <= 1024
Minimum increment: 0.001
Recommended increment: 0.125
Restriction: Sx != 0

Sy (input_control)
number -> HTuple.double / long
Scale factor along the y-axis.
Default value: 2
Suggested values: 0.125, 0.25, 0.5, 1, 2, 4, 8, 16
Typical range of values: 0 <= Sy <= 1024
Minimum increment: 0.001
Recommended increment: 0.125
Restriction: Sy != 0

Px (input_control)
point.x -> HTuple.double / long
Fixed point of the transformation (x coordinate).
Default value: 0
Suggested values: 0, 16, 32, 64, 128, 256, 512, 1024
Typical range of values: 0 <= Px <= 1024
Minimum increment: 1
Recommended increment: 10

Py (input_control)
point.y -> HTuple.double / long
Fixed point of the transformation (y coordinate).
Default value: 0
Suggested values: 0, 16, 32, 64, 128, 256, 512, 1024
Typical range of values: 0 <= Py <= 1024
Minimum increment: 1
Recommended increment: 10

HomMat2DScale (output_control)
affine2d-array -> HTuple.double *
Output transformation matrix.
Number of elements: 6


Result

::hom_mat2d_scale returns H_MSG_TRUE if both scale factors are not 0.


Possible Predecessors

::hom_mat2d_identity, ::hom_mat2d_translate, ::hom_mat2d_scale, ::hom_mat2d_rotate


Possible Successors

::hom_mat2d_translate, ::hom_mat2d_scale, ::hom_mat2d_rotate


Module

Basic operators



Copyright © 1996-2002 MVTec Software GmbH