# Pinhole Camera Geometry

oh my god, all my lessons with Optics in high school is coming back…

- Learned from the Visual SLAM book, starting page 96
- I also have notes that I understand better in Camera Calibration, which I learned from Cyrill stachniss.

### Summary

Let’s summarize the imaging process of a monocular camera:

- First, there is a point $P$ in the world coordinate system, and its world coordinates are $P_{w}$.
- Since the camera is moving, its motion is described by $R,t$ or transform matrix $T∈SE(3)$. The camera coordinates for $P$ are $P~_{c}=RP_{w}+t$.
- The $P~_{c}$ components are $X,Y,Z$, and they are projected onto the normalized plane $Z=1$ to get the normalized coordinates: $P_{c}=[X/Z,Y/Z,1]_{T}$. Note that $Z$ may be less than 1, indicating that the point is behind the normalization plane and it should not be projected on the camera plane.
- If the image is distorted, the coordinates of $P_{c}$ after distortion are calculated according to the distortion parameters.
- Finally, the distorted coordinates of $P$ pass through the intrinsics and we find its pixel coordinates: $P_{uv}=KP_{c}$.