projective_trans_point_2dT_projective_trans_point_2dProjectiveTransPoint2dProjectiveTransPoint2dprojective_trans_point_2d (Operator)

Name

projective_trans_point_2dT_projective_trans_point_2dProjectiveTransPoint2dProjectiveTransPoint2dprojective_trans_point_2d — Project a homogeneous 2D point using a projective transformation matrix.

Signature

projective_trans_point_2d( : : HomMat2D, Px, Py, Pw : Qx, Qy, Qw)

Herror T_projective_trans_point_2d(const Htuple HomMat2D, const Htuple Px, const Htuple Py, const Htuple Pw, Htuple* Qx, Htuple* Qy, Htuple* Qw)

void ProjectiveTransPoint2d(const HTuple& HomMat2D, const HTuple& Px, const HTuple& Py, const HTuple& Pw, HTuple* Qx, HTuple* Qy, HTuple* Qw)

HTuple HHomMat2D::ProjectiveTransPoint2d(const HTuple& Px, const HTuple& Py, const HTuple& Pw, HTuple* Qy, HTuple* Qw) const

double HHomMat2D::ProjectiveTransPoint2d(double Px, double Py, double Pw, double* Qy, double* Qw) const

static void HOperatorSet.ProjectiveTransPoint2d(HTuple homMat2D, HTuple px, HTuple py, HTuple pw, out HTuple qx, out HTuple qy, out HTuple qw)

HTuple HHomMat2D.ProjectiveTransPoint2d(HTuple px, HTuple py, HTuple pw, out HTuple qy, out HTuple qw)

double HHomMat2D.ProjectiveTransPoint2d(double px, double py, double pw, out double qy, out double qw)

def projective_trans_point_2d(hom_mat_2d: Sequence[float], px: MaybeSequence[Union[float, int]], py: MaybeSequence[Union[float, int]], pw: MaybeSequence[Union[float, int]]) -> Tuple[Sequence[float], Sequence[float], Sequence[float]]

def projective_trans_point_2d_s(hom_mat_2d: Sequence[float], px: MaybeSequence[Union[float, int]], py: MaybeSequence[Union[float, int]], pw: MaybeSequence[Union[float, int]]) -> Tuple[float, float, float]

Description

projective_trans_point_2dprojective_trans_point_2dProjectiveTransPoint2dProjectiveTransPoint2dprojective_trans_point_2d applies the homogeneous projective transformation matrix HomMat2DHomMat2DHomMat2DhomMat2Dhom_mat_2d to all homogeneous input points (PxPxPxpxpx,PyPyPypypy,PwPwPwpwpw) and returns an array of homogeneous output points (QxQxQxqxqx,QyQyQyqyqy,QwQwQwqwqw). The transformation is described by the homogeneous transformation matrix given in HomMat2DHomMat2DHomMat2DhomMat2Dhom_mat_2d. This corresponds to the following equation (input and output points as homogeneous vectors):

To transform the homogeneous coordinates to Euclidean coordinates, they have to be divided by QwQwQwqwqw:

If the points to transform are specified in standard image coordinates, their row coordinates must be passed in PxPxPxpxpx and their column coordinates in PyPyPypypy. This is necessary to obtain a right-handed coordinate system for the image. In particular, this assures that rotations are performed in the correct direction. Note that the (x,y) order of the matrices quite naturally corresponds to the usual (row,column) order for coordinates in the image.

Execution Information

Parameters

HomMat2DHomMat2DHomMat2DhomMat2Dhom_mat_2d (input_control)  hom_mat2d HHomMat2D, HTupleSequence[float]HTupleHtuple (real) (double) (double) (double)

Homogeneous projective transformation matrix.

PxPxPxpxpx (input_control)  number(-array) HTupleMaybeSequence[Union[float, int]]HTupleHtuple (real / integer) (double / int / long) (double / Hlong) (double / Hlong)

Input point (x coordinate).

PyPyPypypy (input_control)  number(-array) HTupleMaybeSequence[Union[float, int]]HTupleHtuple (real / integer) (double / int / long) (double / Hlong) (double / Hlong)

Input point (y coordinate).

PwPwPwpwpw (input_control)  number(-array) HTupleMaybeSequence[Union[float, int]]HTupleHtuple (real / integer) (double / int / long) (double / Hlong) (double / Hlong)

Input point (w coordinate).

QxQxQxqxqx (output_control)  number(-array) HTupleSequence[float]HTupleHtuple (real) (double) (double) (double)

Output point (x coordinate).

QyQyQyqyqy (output_control)  number(-array) HTupleSequence[float]HTupleHtuple (real) (double) (double) (double)

Output point (y coordinate).

QwQwQwqwqw (output_control)  number(-array) HTupleSequence[float]HTupleHtuple (real) (double) (double) (double)

Output point (w coordinate).

Possible Predecessors

vector_to_proj_hom_mat2dvector_to_proj_hom_mat2dVectorToProjHomMat2dVectorToProjHomMat2dvector_to_proj_hom_mat2d, hom_vector_to_proj_hom_mat2dhom_vector_to_proj_hom_mat2dHomVectorToProjHomMat2dHomVectorToProjHomMat2dhom_vector_to_proj_hom_mat2d, proj_match_points_ransacproj_match_points_ransacProjMatchPointsRansacProjMatchPointsRansacproj_match_points_ransac, proj_match_points_ransac_guidedproj_match_points_ransac_guidedProjMatchPointsRansacGuidedProjMatchPointsRansacGuidedproj_match_points_ransac_guided, hom_mat3d_projecthom_mat3d_projectHomMat3dProjectHomMat3dProjecthom_mat3d_project

See also

projective_trans_imageprojective_trans_imageProjectiveTransImageProjectiveTransImageprojective_trans_image, projective_trans_image_sizeprojective_trans_image_sizeProjectiveTransImageSizeProjectiveTransImageSizeprojective_trans_image_size, projective_trans_regionprojective_trans_regionProjectiveTransRegionProjectiveTransRegionprojective_trans_region, projective_trans_contour_xldprojective_trans_contour_xldProjectiveTransContourXldProjectiveTransContourXldprojective_trans_contour_xld, projective_trans_pixelprojective_trans_pixelProjectiveTransPixelProjectiveTransPixelprojective_trans_pixel

Module

Foundation