pysdic.OrthographicExtrinsic.compute_rays#
- OrthographicExtrinsic.compute_rays(normalized_points)[source]#
Compute the rays of the camera passing through the given normalized points.
For an orthographic projection, all the rays are parallel to the \(z\) axis of the camera coordinate system. Each ray is represented by its origin and its direction in world coordinates:
The origin is the normalized point placed on the camera plane (\(Z_c = 0\)):
\[\begin{split}\vec{O}_w = R^T \cdot \left( \begin{bmatrix} x_n \\ y_n \\ 0 \end{bmatrix} - T \right)\end{split}\]The direction is the \(z\) axis of the camera expressed in world coordinates:
\[\begin{split}\vec{d}_w = R^T \cdot \begin{bmatrix} 0 \\ 0 \\ 1 \end{bmatrix}\end{split}\]- Parameters:
normalized_points (ArrayLike) – Normalized points in the camera coordinate system. Shape
(..., 2).- Returns:
Rays in world coordinates with shape
(..., 6)(same batch shape as the input points), where the last dimension encodes the ray origin(x, y, z)and the unit direction(dx, dy, dz).- Return type: