CentralCamera

Perspective camera class

A concrete class for a central-projection perspective camera, a subclass of Camera. The camera coordinate system is:
0------------> u X
|
|
|   + (principal point)
|
|   Z-axis is into the page.
v Y
This camera model assumes central projection, that is, the focal point is at z=0 and the image plane is at z=f. The image is not inverted.

Methods

project project world points
K camera intrinsic matrix
C camera matrix
H camera motion to homography
invH decompose homography
F camera motion to fundamental matrix
E camera motion to essential matrix
invE decompose essential matrix
fov field of view
ray Ray3D corresponding to point
plot plot projection of world point on image plane
hold control hold for image plane
ishold test figure hold for image plane
clf clear image plane
figure figure holding the image plane
mesh draw shape represented as a mesh
point draw homogeneous points on image plane
line draw homogeneous lines on image plane
plot_camera draw camera in world view
plot_line_tr draw line in theta/rho format
plot_epiline draw epipolar line
flowfield compute optical flow
visjac_p image Jacobian for point features
visjac_p_polar image Jacobian for point features in polar coordinates
visjac_l image Jacobian for line features
visjac_e image Jacobian for ellipse features
rpy set camera attitude
move clone Camera after motion
centre get world coordinate of camera centre
estpose estimate pose
delete object destructor
char convert camera parameters to string
display display camera parameters

Properties (read/write)

npix image dimensions in pixels (2x1)
pp intrinsic: principal point (2x1)
rho intrinsic: pixel dimensions (2x1) in metres
f intrinsic: focal length
k intrinsic: radial distortion vector
p intrinsic: tangential distortion parameters
distortion intrinsic: camera distortion [k1 k2 k3 p1 p2]
T extrinsic: camera pose as homogeneous transformation

Properties (read only)

nu number of pixels in u-direction
nv number of pixels in v-direction
u0 principal point u-coordinate
v0 principal point v-coordinate

Notes

See also

Camera


CentralCamera.C

Camera matrix

C.

CentralCamera.CentralCamera

Create central projection camera object

C = CentralCamera(options) as above but with specified parameters.

Options

'name', N Name of camera
'focal', F Focal length [metres]
'distortion', D Distortion vector [k1 k2 k3 p1 p2]
'distortion-bouguet', D Distortion vector [k1 k2 p1 p2 k3]
'default' Default camera parameters: 1024x1024, f=8mm, 10um pixels, camera at origin, optical axis is z-axis, u- and v-axes parallel to x- and y-axes respectively.
'image', IM Display an image rather than points
'resolution', N Image plane resolution: NxN or N=[W H]
'sensor', S Image sensor size in metres (2x1)
'centre', P Principal point (2x1)
'pixel', S Pixel size: SxS or S=[W H]
'noise', SIGMA Standard deviation of additive Gaussian noise added to returned image projections
'pose', T Pose of the camera as a homogeneous transformation
'color', C Color of image plane background (default [1 1 0.8])

See also

Camera, fisheyecamera, CatadioptricCamera, SphericalCamera


CentralCamera.E

Essential matrix

E(T) is the essential matrix relating two camera views. The first view is from the current camera pose C.T and the second is a relative motion represented by the homogeneous transformation T. E = C.F(F (3x3) and the intrinsic parameters of camera C.

Reference

Y.Ma, J.Kosecka, S.Soatto, S.Sastry, "An invitation to 3D", Springer, 2003. p.177

See also

CentralCamera.F, CentralCamera.invE


CentralCamera.F

Fundamental matrix

F(T) is the fundamental matrix relating two camera views. The first view is from the current camera pose C.T and the second is a relative motion represented by the homogeneous transformation T. F(C2) is the fundamental matrix relating two camera views described by camera objects C (first view) and C2 (second view).

Reference

Y.Ma, J.Kosecka, S.Soatto, S.Sastry, "An invitation to 3D", Springer, 2003. p.177

See also

CentralCamera.E


CentralCamera.H

Homography matrix

H(T, n, d) is a 3x3 homography matrix for the camera observing the plane with normal n and at distance d, from two viewpoints. The first view is from the current camera pose C.T and the second is after a relative motion represented by the homogeneous transformation T.

See also

CentralCamera.H


CentralCamera.K

Intrinsic parameter matrix

K() is the 3x3 intrinsic parameter matrix.

CentralCamera.estpose

Estimate pose from object model and camera view

T = C.

CentralCamera.flowfield

Optical flow

C.quiver


CentralCamera.fov

Camera field-of-view angles.

a = C.

CentralCamera.invE

Decompose essential matrix

s = C.invE(E, p) as above but only solutions in which the world point p is visible are returned.

Reference

Hartley & Zisserman, "Multiview Geometry", Chap 9, p. 259 Y.Ma, J.Kosecka, s.Soatto, s.Sastry, "An invitation to 3D", Springer, 2003. p116, p120-122

Notes

  • The transformation is from view 1 to view 2.

See also

CentralCamera.E


CentralCamera.invH

Decompose homography matrix

s = C.See also

CentralCamera.H


CentralCamera.plot_epiline

Plot epipolar line

C.plot_epiline(f, p, ls) as above but draw lines using the line style arguments ls. H = C.

CentralCamera.plot_line_tr

Plot line in theta-rho format

plot_line_tr(L) plots lines on the camera's image plane that are described by columns of L with rows theta and rho respectively.

See also

Hough


CentralCamera.project

Project world points to image plane

uv = C. 'Tobj', T Transform all points by the homogeneous transformation T before projecting them to the camera image plane. 'Tcam', T Set the camera pose to the homogeneous transformation T before projecting points to the camera image plane. Temporarily overrides the current camera pose C.T. If Tcam (4x4xS) is a transform sequence then uv (2xNxS) represents the sequence of projected points as the camera moves in the world. If Tobj (4x4x) is a transform sequence then uv (2xNxS) represents the sequence of projected points as the object moves in the world.

See also

Camera.plot


CentralCamera.ray

3D ray for image point

R = C.See also

Ray3D


CentralCamera.visjac_e

Visual motion Jacobian for point feature

J = C.See also

CentralCamera.visjac_p, CentralCamera.visjac_p_polar, CentralCamera.visjac_l


CentralCamera.visjac_l

Visual motion Jacobian for line feature

J = C.See also

CentralCamera.visjac_p, CentralCamera.visjac_p_polar, CentralCamera.visjac_e


CentralCamera.visjac_p

Visual motion Jacobian for point feature

J = C.See also

CentralCamera.visjac_p_polar, CentralCamera.visjac_l, CentralCamera.visjac_e


CentralCamera.visjac_p_polar

Visual motion Jacobian for point feature

J = C.See also

CentralCamera.visjac_p, CentralCamera.visjac_l, CentralCamera.visjac_e


Machine Vision Toolbox for MATLAB © 1990-2011 Peter Corke.