117 printf(
"Undistortion not possible in PnPAHRS.c... why?\n");
132 printf(
"Determine world vector for corner %d\n", i);
133 printf(
"Distorted coordinates: (x,y) = (%d, %d)\n", x_corners[i], y_corners[i]);
134 printf(
"Normalized coordinates: (x_n, y_n) = (%f, %f)\n",
x_n,
y_n);
154#if CAMERA_ROTATED_90DEG_RIGHT
struct FloatVect3 get_world_position_from_image_points(int *x_corners, int *y_corners, struct FloatVect3 *world_corners, int n_corners, struct camera_intrinsics_t cam_intrinsics, struct FloatEulers cam_body)
Get the world position of the camera, given image coordinates and corresponding world coordinates.
Functions for solving a perspective-n-point problem, using the AHRS to get the relevant angles.
struct FloatVect3 world_corners[4]
struct FloatEulers cam_body
void float_rmat_of_eulers_321(struct FloatRMat *rm, struct FloatEulers *e)
Rotation matrix from 321 Euler angles (float).
#define FLOAT_VECT3_ZERO(_v)
#define FLOAT_MAT33_DIAG(_m, _d00, _d11, _d22)
#define FLOAT_MAT33_ZERO(_m)
#define VECT3_SUM(_c, _a, _b)
#define VECT3_VECT3_TRANS_MUL(_mat, _v_a, _v_b)
#define VECT3_SDIV(_vo, _vi, _s)
#define MAT33_VECT3_MUL(_vout, _mat, _vin)
#define MAT33_MAT33_SUM(_mat1, _mat2, _mat3)
#define MAT33_INV(_minv, _m)
#define MAT33_TRANS(_mat1, _mat2)
#define MAT33_COPY(_mat1, _mat2)
#define MAT33_MAT33_DIFF(_mat1, _mat2, _mat3)
static struct FloatEulers * stateGetNedToBodyEulers_f(void)
Get vehicle body attitude euler angles (float).
API to get/set the generic vehicle states.
bool distorted_pixels_to_normalized_coords(float x_pd, float y_pd, float *x_n, float *y_n, float k, const float *K)
Transform distorted pixel coordinates to normalized coordinates.