Camera API | Component APIs

Camera API

The camera API allows you to give commands to your camera components for getting images or point clouds.

The API for camera components allows you to:

The camera component supports the following methods:

Method Name Description
GetImages GetImages is used for getting simultaneous images from different imagers from 3D cameras along with associated metadata, and single images from non-3D cameras, for example webcams, RTSP cameras, etc. in the image list in the response.
GetPointCloud Get a point cloud from the camera as bytes with a MIME type describing the structure of the data.
GetProperties Get the camera intrinsic parameters and camera distortion, as well as whether the camera supports returning point clouds.
DoCommand Execute model-specific commands that are not otherwise defined by the component API.
GetGeometries Get all the geometries associated with the camera in its current configuration, in the frame of the camera.
GetResourceName Get the ResourceName for this camera.
Close Safely shut down the resource and prevent further use.

API

GetImages

Usage

You can use the rgb-d-overlay module to view and compare the camera streams returned by this method.
See the module readme for further instructions.

GetImages is used for getting simultaneous images from different imagers from 3D cameras along with associated metadata, and single images from non-3D cameras, for example webcams, RTSP cameras, etc. in the image list in the response. Multiple images returned from GetImages() do not represent a time series of images.

Parameters:

Returns:

Example:


For more information, see the Python SDK Docs.

Parameters:

Returns:

Example:


For more information, see the Go SDK Docs.

Parameters:

Returns:

Example:


For more information, see the TypeScript SDK Docs.

Parameters:

Returns:

Example:


For more information, see the Flutter SDK Docs.

GetPointCloud

Get a point cloud from the camera as bytes with a MIME type describing the structure of the data. The consumer of this call should decode the bytes into the format suggested by the MIME type.

Parameters:

Returns:

Example:


For more information, see the Python SDK Docs.

Parameters:

Returns:

Example:


For more information, see the Go SDK Docs.

Parameters:

Returns:

Example:


For more information, see the TypeScript SDK Docs.

Parameters:

Returns:

Example:


For more information, see the Flutter SDK Docs.

GetProperties

Get the camera intrinsic parameters and camera distortion, as well as whether the camera supports returning point clouds.

Parameters:

Returns:

Example:


For more information, see the Python SDK Docs.

Parameters:

Returns:

For more information, see the Go SDK Docs.

Parameters:

Returns:

Example:


For more information, see the TypeScript SDK Docs.

Parameters:

Returns:

Example:


For more information, see the Flutter SDK Docs.

DoCommand

Execute model-specific commands that are not otherwise defined by the component API. Most models do not implement DoCommand. Any available model-specific commands should be covered in the model’s documentation. If you are implementing your own camera and want to add features that have no corresponding built-in API method, you can implement them with DoCommand.

Parameters:

Returns:

Raises:

Example:


For more information, see the Python SDK Docs.

Parameters:

Returns:

Example:


For more information, see the Go SDK Docs.

Parameters:

Returns:

Example:


For more information, see the TypeScript SDK Docs.

Parameters:

Returns:

Example:


For more information, see the Flutter SDK Docs.

GetGeometries

Get all the geometries associated with the camera in its current configuration, in the frame of the camera. The motion and navigation services use the relative position of inherent geometries to configured geometries representing obstacles for collision detection and obstacle avoidance while motion planning.

Parameters:

Returns:

Example:


For more information, see the Python SDK Docs.

Parameters:

Returns:

Example:


For more information, see the Go SDK Docs.

Parameters:

Returns:

For more information, see the TypeScript SDK Docs.

GetResourceName

Get the ResourceName for this camera.

Parameters:

Returns:

Example:


For more information, see the Python SDK Docs.

Parameters:

Returns:

Example:


For more information, see the Go SDK Docs.

Parameters:

Returns:

Example:


For more information, see the TypeScript SDK Docs.

Parameters:

Returns:

Example:


For more information, see the Flutter SDK Docs.

Close

Safely shut down the resource and prevent further use.

Parameters:

Returns:

Example:


For more information, see the Python SDK Docs.

Parameters:

Returns:

Example:


For more information, see the Go SDK Docs.