UWARG Computer Vision
Public Member Functions | Static Public Member Functions | List of all members
Camera Class Reference

Container class for storing information about the camera used to capture an image *. More...

#include <camera.h>

Collaboration diagram for Camera:
Collaboration graph

Public Member Functions

 Camera (cv::Size imageSize, cv::Size2d fov, cv::Mat cameraMatrix, cv::Mat distortionCoeffs, cv::Mat newCameraMatrix, bool applyUndistort=true)
 creates a Camera representing the specs for a given lens and sensor More...
 
cv::Size2d get_fov ()
 Returns the field of view of the camera in degrees for both horizontal and vertical dimensions.
 
cv::Mat * undistort (cv::Mat &img)
 Undistorts image. More...
 

Static Public Member Functions

static Camera TestCamera ()
 Example Camera for testing purposes.
 

Detailed Description

Container class for storing information about the camera used to capture an image *.

Constructor & Destructor Documentation

Camera::Camera ( cv::Size  imageSize,
cv::Size2d  fov,
cv::Mat  cameraMatrix,
cv::Mat  distortionCoeffs,
cv::Mat  newCameraMatrix,
bool  applyUndistort = true 
)

creates a Camera representing the specs for a given lens and sensor

Parameters
imageSizeSize of the camera image
fovThe field of view of the camera
cameraMatrixOpenCV camera calibration matrix giving focal length and principal point
distortionCoeffsOpenCV distortion coefficients used for undistorting images #param undistort Whether or not to apply undistortion to images. If false the camera acts as a placeholder that can be used for testing

Member Function Documentation

Mat * Camera::undistort ( cv::Mat &  img)

Undistorts image.

Parameters
imgmat to be undistorted
Returns
An orthorectified version of the given mat

The documentation for this class was generated from the following files: