monoCamera
Configure monocular camera sensor
Description
ThemonoCamera
object holds information about the configuration of a monocular camera sensor. Configuration information includes the camera intrinsics, camera extrinsics such as its orientation (as described by pitch, yaw, and roll), and the camera location within the vehicle. To estimate the intrinsic and extrinsic camera parameters, seeCalibrate a Monocular Camera.
For images captured by the camera, you can use theimageToVehicle
andvehicleToImage
functions to transform point locations between image coordinates and vehicle coordinates. These functions apply projective transformations (homography), which enable you to estimate distances from a camera mounted on the vehicle to locations on a flat road surface.
Creation
Description
sensor = monoCamera(
creates aintrinsics
,height
)monoCamera
object that contains the configuration of a monocular camera sensor, given the intrinsic parameters of the camera and the height of the camera above the ground.intrinsics
andheight
set theIntrinsics
andHeight
properties of the camera.
setspropertiesusing one or more name-value pairs. For example,sensor
= monoCamera(intrinsics,height,Name,Value
)monoCamera(intrinsics,1.5,'Pitch',1)
creates a monocular camera sensor that is 1.5 meters above the ground and has a 1-degree pitch toward the ground. Enclose each property name in quotes.
Properties
Object Functions
imageToVehicle |
Convert image coordinates to vehicle coordinates |
vehicleToImage |
Convert vehicle coordinates to image coordinates |