- Welcome
- Getting Started With the NVIDIA DriveWorks SDK
- Modules
- Samples
- Tools
- Tutorials
- SDK Porting Guide
- DriveWorks API
- More
Defines the PnP module.
Macros | |
#define | DW_PNP_MAX_POINT_COUNT 128 |
Defines the maximum number of points that can be processed by the PnP solver. More... | |
Typedefs | |
typedef struct dwPnPObject * | dwPnPHandle_t |
A pointer to the handle representing a PnP solver. More... | |
Functions | |
DW_API_PUBLIC dwStatus | dwPnP_initialize (dwPnPHandle_t *obj, size_t ransacIterations, size_t optimizerIterations, dwContextHandle_t ctx) |
Initializes a PnP solver. More... | |
DW_API_PUBLIC dwStatus | dwPnP_release (dwPnPHandle_t obj) |
Releases the PnP solver. More... | |
DW_API_PUBLIC dwStatus | dwPnP_reset (dwPnPHandle_t obj) |
Resets the PnP solver. More... | |
DW_API_PUBLIC dwStatus | dwPnP_solve (dwTransformation3f *worldToCamera, size_t matchCount, const dwVector3f *rays, const dwVector3f *worldPoints, dwPnPHandle_t obj) |
Estimates the worldToCamera pose based on optical ray to 3D world point correspondences. More... | |
#define DW_PNP_MAX_POINT_COUNT 128 |
typedef struct dwPnPObject* dwPnPHandle_t |
DW_API_PUBLIC dwStatus dwPnP_initialize | ( | dwPnPHandle_t * | obj, |
size_t | ransacIterations, | ||
size_t | optimizerIterations, | ||
dwContextHandle_t | ctx | ||
) |
Initializes a PnP solver.
[out] | obj | A pointer to the PnP handle for the created module. |
[in] | ransacIterations | The number of P3P ransac iterations to run when solving a PnP pose. |
[in] | optimizerIterations | The number of non-linear optimization iterations to run when solving a PnP pose. |
[in] | ctx | Specifies the handler to the context to create the rectifier. |
DW_API_PUBLIC dwStatus dwPnP_release | ( | dwPnPHandle_t | obj | ) |
Releases the PnP solver.
[in] | obj | The object handle to release. |
DW_API_PUBLIC dwStatus dwPnP_reset | ( | dwPnPHandle_t | obj | ) |
Resets the PnP solver.
[in] | obj | Specifies the solver to reset. |
DW_API_PUBLIC dwStatus dwPnP_solve | ( | dwTransformation3f * | worldToCamera, |
size_t | matchCount, | ||
const dwVector3f * | rays, | ||
const dwVector3f * | worldPoints, | ||
dwPnPHandle_t | obj | ||
) |
Estimates the worldToCamera pose based on optical ray to 3D world point correspondences.
The rays can be obtained by applying the camera model to 2D pixel positions. The 3D world points come from known world structure.
[out] | worldToCamera | The estimated pose |
[in] | matchCount | The number of ray to point correspondences. |
[in] | rays | The optical rays. Their norm is expected to be one. |
[in] | worldPoints | The 3D world points that correspond to the rays provided. |
[in] | obj | A pointer to the PnP handle for the created module. |