next up previous contents
Next: Stereo matching Up: Camera Geometry Previous: Rectification Functions   Contents

Parallel Projection

Simple module to convert parallel camera disparity vectors to 3D world vectors and their complements. Disparity is defined as right camera image coordinates minus left camera image coordinates. Points in disparity space are of type Vec3 with x and y in the image z set to disparity. Values of focal length f and interocular separation I must be recovered from approriate parcam structure. Avoids the necessity of carrying round extraneous camera definitions at the expence of some generality.

extern void    par_proj_set(double fnew, double Inew);

extern void    par_proj_get(float *fp, float *Ip);

Module initialisation function that sets current f and I values. Suitable values must be provided prior to projection.

extern void    par_proj_ray(Vec2 u, Vec3 * p, Vec3 * v);

extern Vec3    vec3_par_proj_3d(Vec3 p);

extern Vec3    vec3_par_proj_disp(Vec3 p);

extern void    vec3_pp3d_inplace(Vec3 * p);

extern void    vec3_ppdisp_inplace(Vec3 * p);

Project a single point p between disparity and 3D coordinate frames.

vec3_par_proj_3d takes a point in disparity and returns a 3D point and

vec3_par_proj_disp the converse.

extern void    line3_par_proj_3d(Line3 * line);

extern void    line3_par_proj_disp(Line3 * line);

extern void    plane_par_proj_3d(Plane * plane);

Projection functions for Line3 and Plane.


next up previous contents
Next: Stereo matching Up: Camera Geometry Previous: Rectification Functions   Contents
root 2017-09-21