TensorMath.solvePnPExtended
FunctionEstimates the object pose given a set of object points (inObjectPoints), their corresponding image projections (inImagePoints), and the intrinsic camera matr…
- Available on all platforms
solvePnPExtended(
inObjectPoints,inImagePoints,imagePointsShape,cameraIntrinsicsMatrix,distortionCoeff,distortionCoeffShape,useExtrinsicGuess,flags,outRotTrans):boolean
Estimates the object pose given a set of object points (inObjectPoints), their corresponding image projections (inImagePoints), and the intrinsic camera matrix (cameraIntrinsicsMatrix). Similar to solvePnP but has additional camera distortion coefficient settings.
distortionCoeff - Input vector of distortion coefficients. If the vector is null - the zero distortion coefficients are assumed.
distortionCoeffShape - {numElements, 1, 1} where numElements can be 4, 5, 8 or 12.
useExtrinsicGuess - The function uses the provided outRotTrans values as initial approximations of the rotation and translation vectors and further optimizes them.
Parameters
| Parameter | Type |
|---|---|
inObjectPoints | Float32Array |
inImagePoints | Float32Array |
imagePointsShape | vec3 |
cameraIntrinsicsMatrix | mat3 |
distortionCoeff | Float32Array |
distortionCoeffShape | vec3 |
useExtrinsicGuess | boolean |
flags | number |
outRotTrans | Float32Array |
Returns
boolean