![]() |
NDEVR
API Documentation
|
A ViewportPointSmoother specialized for DepthAI cameras, converting between pixel coordinates and 3D points using the camera's intrinsic matrix. More...
Public Member Functions | |
| DepthAISmoother (const Vector< 2, uint04 > &size, const Matrix< fltp04 > &intrinsics) | |
| Constructs the smoother with the camera's native size and intrinsic matrix. | |
| DepthAISmoother * | clone () |
| Creates a copy of this smoother with the same parameters. | |
| Vertex< 3, fltp04 > | pixelToPoint (Vertex< 3, fltp04 > pixel) const final override |
| Converts a pixel coordinate with depth into a 3D point. | |
| Vertex< 2, fltp04 > | pointToPixel (Vertex< 3, fltp04 > location) const final override |
| Projects a 3D point onto the image plane as a pixel coordinate. | |
| void | setViewSize (const Vector< 2, uint04 > &view_size) final override |
| Updates the viewport size and recalculates pixel scaling factors. | |
Protected Attributes | |
| Matrix< fltp04 > | m_intrinics |
| Camera intrinsic matrix (fx, fy, cx, cy). | |
| Vector< 2, fltp04 > | m_inv_fov |
| Inverse focal lengths (1/fx, 1/fy). | |
| fltp04 | m_inv_pixel_multiplier = 1.0f |
| Inverse of the pixel multiplier. | |
| Vector< 2, uint04 > | m_original_size |
| Native camera image resolution. | |
| fltp04 | m_pixel_multiplier = 1.0f |
| Scale factor from native to current viewport size. | |
A ViewportPointSmoother specialized for DepthAI cameras, converting between pixel coordinates and 3D points using the camera's intrinsic matrix.
Definition at line 11 of file DepthAIPointSmoother.h.
|
inline |
Constructs the smoother with the camera's native size and intrinsic matrix.
| [in] | size | The native image resolution of the camera. |
| [in] | intrinsics | The 4x4 camera intrinsic matrix (fx, fy, cx, cy). |
Definition at line 17 of file DepthAIPointSmoother.h.
References Vector< t_dims, t_type >::as(), m_intrinics, m_inv_fov, and m_original_size.
Referenced by clone().
|
inline |
Creates a copy of this smoother with the same parameters.
Definition at line 61 of file DepthAIPointSmoother.h.
References DepthAISmoother(), m_intrinics, m_original_size, and setViewSize().
|
inlinefinaloverride |
Converts a pixel coordinate with depth into a 3D point.
| [in] | pixel | The pixel (x, y, depth) to convert. |
Definition at line 29 of file DepthAIPointSmoother.h.
References m_intrinics, m_inv_fov, and m_inv_pixel_multiplier.
|
inlinefinaloverride |
Projects a 3D point onto the image plane as a pixel coordinate.
| [in] | location | The 3D point in camera space. |
Definition at line 41 of file DepthAIPointSmoother.h.
References m_intrinics, and m_pixel_multiplier.
Updates the viewport size and recalculates pixel scaling factors.
| [in] | view_size | The new viewport size in pixels. |
Definition at line 53 of file DepthAIPointSmoother.h.
References cast(), m_inv_pixel_multiplier, m_original_size, and m_pixel_multiplier.
Referenced by clone().