# ZED SDK 5.3.1 — csharp API reference
> Per-symbol API reference for the ZED SDK csharp API, generated from the
> source headers/stubs. For concepts, tutorials and usage examples see the
> main documentation: https://docs.stereolabs.com/llms-full.txt
> (index: https://docs.stereolabs.com/llms.txt).
## Contents
- sl::Camera
- sl::InitParameters
- sl::RuntimeParameters
- sl::Mat
- sl
- sl::CameraParameters
- sl::CalibrationParameters
- sl::Pose
- sl::SensorsData
- sl::PositionalTrackingParameters
- sl::RecordingParameters
- sl::StreamingParameters
- sl::ObjectDetectionParameters
- sl::BodyTrackingParameters
- GNSS_STATUS
- sl::FusedPointCloud
- sl::Fusion
- sl::GNSSCalibrationParameters
- sl::Mesh
- sl::ObjectsBatch
- sl::PlaneDetectionParameters
- sl::PositionalTrackingFusionParameters
- sl::SpatialMappingParameters
- sl::ZEDCommon
- sl::AI_Model_status
- sl::BarometerData
- sl::BatchParameters
- sl::Bodies
- sl::BodyData
- sl::BodyTrackingFusionParameters
- sl::BodyTrackingFusionRuntimeParameters
- sl::BodyTrackingRuntimeParameters
- sl::CameraConfiguration
- sl::CameraIdentifier
- sl::CameraInformation
- sl::CameraMetrics
- sl::Camera::NativeRecordingParameters
- sl::Camera::sl_PlaneDetectionParameters
- sl::Camera::sl_PositionalTrackingParameters
- sl::Camera::sl_RuntimeParameters
- sl::Camera::sl_SpatialMappingParameters
- sl::Camera::sl_initParameters
- sl::Chunk
- sl::CommunicationParameters
- sl::CovarMatrix
- sl::CustomBoxObjectData
- sl::CustomMaskObjectData
- sl::CustomObjectDetectionProperties
- sl::CustomObjectDetectionRuntimeParameters
- sl::DeviceProperties
- sl::ECEF
- sl::ENU
- sl::FusedPositionalTrackingStatus
- sl::FusionConfiguration
- sl::FusionMetrics
- sl::Fusion::sl_GNSSCalibrationParameters
- sl::Fusion::sl_PositionalTrackingFusionParameters
- sl::GNSSData
- sl::GeoPose
- sl::HealthStatus
- sl::ImuData
- sl::InitFusionParameters
- sl::InputType
- sl::Landmark
- sl::Landmark2D
- sl::LatLng
- sl::MagnetometerData
- sl::Matrix3x3
- sl::ObjectData
- sl::ObjectDetectionRuntimeParameters
- sl::ObjectTrackingParameters
- sl::Objects
- sl::PlaneData
- sl::PositionalTrackingStatus
- sl::RecordingStatus
- sl::Rect
- sl::RegionOfInterestParameters
- sl::Resolution
- sl::SVOData
- sl::SensorParameters
- sl::SensorsConfiguration
- sl::StreamingProperties
- sl::SynchronizationParameter
- sl::TemperatureSensorData
- sl::UTM
- sl::VoxelMeasureParameters
- sl::char2
- sl::char3
- sl::char4
- sl::float2
- sl::float3
- sl::float4
- src/ZEDCamera.cs
- src/ZEDCommon.cs
- src/ZEDFusion.cs
- src/ZEDMat.cs
- add-on-csharp.txt
- csharp-api
- src
- release-notes.md
- System
- System::Collections::Generic
- System::Numerics
- System::Runtime::InteropServices
- std
---
# sl::Camera
**Module:** **Video Module**
This class serves as the primary interface between the camera and the various features provided by the SDK. More...
## Public Properties
| | Name |
| -------------- | -------------- |
| int | **ImageWidth**
Width of the images returned by the camera in pixels. |
| int | **ImageHeight**
Height of the images returned by the camera in pixels. |
| float | **Baseline**
Baseline of the camera (distance between the cameras). |
| float | **HorizontalFieldOfView**
Current horizontal field of view in degrees of the camera. |
| float | **VerticalFieldOfView**
Current vertical field of view in degrees of the camera. |
| SensorsConfiguration | **SensorsConfiguration** |
| CalibrationParameters | **CalibrationParametersRaw**
Stereo parameters for current ZED camera prior to rectification (distorted). |
| CalibrationParameters | **CalibrationParametersRectified**
Stereo parameters for current ZED camera after rectification (undistorted). |
| sl.MODEL | **CameraModel**
Model of the camera. |
| bool | **IsCameraReady**
Whether the camera has been successfully initialized. |
## Detailed Description
```csharp
class sl::Camera;
```
This class serves as the primary interface between the camera and the various features provided by the SDK.
It enables seamless integration and access to a wide array of capabilities, including video streaming, depth sensing, object tracking, mapping, and much more.
## Public Functions Documentation
### function RetrieveImage
```csharp
sl.ERROR_CODE RetrieveImage(
sl.Mat mat,
sl.VIEW view,
sl.MEM mem =sl.MEM.CPU,
sl.Resolution resolution =new sl.Resolution()
)
```
Retrieves an image texture from the ZED SDK and loads it into a sl.Mat.
**Parameters**:
* **mat** sl.Mat to fill with the new texture.
* **view** Image type (left RGB, right depth map, etc.)
* **mem** Whether the image should be on CPU or GPU memory.
* **resolution** Resolution of the texture. If set to (0,0), the camera resolution or InitParameters.maximumWorkingResolution will be taken, whichever is the smallest.
**Return**: sl.ERROR_CODE indicating if the retrieval was successful, and why it wasn't otherwise.
**Note**:
* If you want to access the texture via script, you'll usually want to specify CPU memory. Then you can use Marshal.Copy to move them into a new byte array, which you can load into a Texture2D. Note that you may need to change the color space and/or flip the image.
* For more info, read about the SDK method it calls: [retrieveImage](https://www.stereolabs.com/docs/api/classsl_1_1Camera.html#a01dce4f0af6f8959a9c974ffaca656b5).
Use this to get an individual texture from the last grabbed frame in a human-viewable format. Image textures work for when you want the result to be visible, such as the direct RGB image from the camera, or a greyscale image of the depth. However it will lose accuracy if used to show measurements like depth or confidence, unlike measure textures.
### function GetInitParameters
```csharp
InitParameters GetInitParameters()
```
Returns the InitParameters associated with the Camera object.
**Return**: InitParameters containing the parameters used to initialize the Camera object.
It corresponds to the structure given as argument to Open() method.
### function GetRuntimeParameters
```csharp
RuntimeParameters GetRuntimeParameters()
```
Returns the RuntimeParameters used.
**Return**: RuntimeParameters containing the parameters that define the behavior of the Grab method.
It corresponds to the structure given as argument to the Grab() method.
### function GetPositionalTrackingParameters
```csharp
PositionalTrackingParameters GetPositionalTrackingParameters()
```
Returns the PositionalTrackingParameters used.
**Return**: PositionalTrackingParameters containing the parameters used for positional tracking initialization.
It corresponds to the structure given as argument to the EnablePositionalTracking() method.
### function IsCameraSettingSupported
```csharp
bool IsCameraSettingSupported(
VIDEO_SETTINGS setting
)
```
Test if the video setting is supported by the camera.
**Parameters**:
* **setting** The video setting to test.
**Return**: true if the VIDEO_SETTINGS is supported by the camera, false otherwise.
### function SetCameraSettings
```csharp
void SetCameraSettings(
VIDEO_SETTINGS settings,
int minvalue,
int maxvalue
)
```
Sets the min and max range values of the requested camera setting (used for settings with a range).
**Parameters**:
* **settings** The setting to be set.
* **minvalue** The min value of the range to set.
* **maxvalue** The min value of the range to set.
### function GetCameraSettings
```csharp
sl.ERROR_CODE GetCameraSettings(
VIDEO_SETTINGS settings,
ref int minvalue,
ref int maxvalue
)
```
Returns the current range of the requested camera setting.
**Parameters**:
* **settings** Setting to be retrieved (setting with range value).
* **minvalue** Will be set to the value of the lower bound of the range of the setting.
* **maxvalue** Will be set to the value of the higher bound of the range of the setting.
**Return**: An sl.ERROR_CODE to indicate if the method was successful.
### function SetCameraSettings
```csharp
void SetCameraSettings(
VIDEO_SETTINGS settings,
int value
)
```
Sets the value of the requested camera setting (gain, brightness, hue, exposure, etc.).
**Parameters**:
* **settings** The setting to be set.
* **value** The value to set. Default: auto mode
### function GetCameraSettings
```csharp
int GetCameraSettings(
VIDEO_SETTINGS settings
)
```
Returns the current value of the requested camera setting (gain, brightness, hue, exposure, etc.).
**Parameters**:
* **settings** Setting to be retrieved (brightness, contrast, gain, exposure, etc.).
**Return**: The value of the requested camera setting.
### function SetCameraSettings
```csharp
ERROR_CODE SetCameraSettings(
VIDEO_SETTINGS settings,
SIDE side,
Rect roi,
bool reset =false
)
```
Overloaded method for VIDEO_SETTINGS.AEC_AGC_ROI which takes a Rect as parameter.
**Parameters**:
* **settings** Must be set at VIDEO_SETTINGS.AEC_AGC_ROI, otherwise the method will have no impact.
* **side** sl.SIDE on which to be applied for AEC/AGC computation.
* **roi** Rect that defines the target to be applied for AEC/AGC computation. Must be given according to camera resolution.
* **reset** Cancel the manual ROI and reset it to the full image.
**Return**: An sl.ERROR_CODE to indicate if the method was successful.
### function GetCameraSettings
```csharp
ERROR_CODE GetCameraSettings(
VIDEO_SETTINGS settings,
SIDE side,
ref Rect roi
)
```
Overloaded method for VIDEO_SETTINGS.AEC_AGC_ROI which takes a Rect as parameter.
**Parameters**:
* **settings** Must be set at VIDEO_SETTINGS.AEC_AGC_ROI, otherwise the method will have no impact.
* **side** sl.SIDE on which to get the ROI from.
* **roi** Roi that will be filled.
**Return**: An sl.ERROR_CODE to indicate if the method was successful.
### function ResetCameraSettings
```csharp
void ResetCameraSettings()
```
Reset camera settings to default.
### function GetCameraTimeStamp
```csharp
ulong GetCameraTimeStamp()
```
Gets the timestamp at the time the latest grabbed frame was extracted from the USB stream.
**Return**: Current timestamp in nanoseconds. -1 means it's is not available, such as with an .SVO file without compression.
**Note**: Must be called after calling Grab().
This is the closest timestamp you can get from when the image was taken.
### function GetCurrentTimeStamp
```csharp
ulong GetCurrentTimeStamp()
```
Gets the current timestamp at the time the method is called.
**Return**: The timestamp in nanoseconds.
Can be compared to the camera timestamp for synchronization, since they have the same reference (the computer's start time).
### function GetSVOPosition
```csharp
int GetSVOPosition()
```
Returns the current playback position in the SVO file.
**Return**: The current frame position in the SVO file. -1 if the SDK is not reading an SVO.
### function GetSVOPositionAtTimestamp
```csharp
int GetSVOPositionAtTimestamp(
ulong timestamp
)
```
Retrieves the frame index within the SVO file corresponding to the provided timestamp.
**Parameters**:
* **timestamp** The target timestamp for which the frame index is to be determined.
**Return**: The frame index within the SVO file that aligns with the given timestamp. Returns -1 if the timestamp falls outside the bounds of the SVO file.
### function GetSVONumberOfFrames
```csharp
int GetSVONumberOfFrames()
```
Returns the number of frames in the SVO file.
**Return**: The total number of frames in the SVO file. -1 if the SDK is not reading a SVO.
### function SetSVOPosition
```csharp
ERROR_CODE SetSVOPosition(
int position
)
```
Sets the position of the SVO file currently being read to a desired position.
**Parameters**:
* **position** Index of the desired position to be decoded.
**Return**: An sl.ERROR_CODE to indicate if the method was successful.
### function PauseSVOReading
```csharp
void PauseSVOReading(
bool status
)
```
Pauses or resumes SVO playback.
**Parameters**:
* **status** True to pause, false to resume.
### function GetCameraFPS
```csharp
float GetCameraFPS()
```
Returns the current camera FPS.
**Return**: The current fps
This is limited primarily by resolution but can also be lower due to setting a lower desired resolution in Open() or from USB connection/bandwidth issues.
### function IsOpened
```csharp
bool IsOpened()
```
Reports if the camera has been successfully opened.
**Return**: Returns true if the camera is already setup, otherwise false.
### function GetResolution
```csharp
static sl.Resolution GetResolution(
RESOLUTION resolution
)
```
Gets the corresponding sl.Resolution from an sl.RESOLUTION.
**Parameters**:
* **resolution** The wanted sl.RESOLUTION.
**Return**: The sl.Resolution corresponding to sl.RESOLUTION given as argument.
### function RetrieveMeasure
```csharp
sl.ERROR_CODE RetrieveMeasure(
sl.Mat mat,
sl.MEASURE measure,
sl.MEM mem =sl.MEM.CPU,
sl.Resolution resolution =new sl.Resolution()
)
```
Retrieves a measure texture from the ZED SDK and loads it into a sl.Mat.
**Parameters**:
* **mat** sl.Mat to fill with the new texture.
* **measure** Measure type (depth, confidence, xyz, etc.).
* **mem** Whether the image should be on CPU or GPU memory.
* **resolution** Resolution of the texture. If set to (0,0), the camera resolution or InitParameters.maximumWorkingResolution will be taken, whichever is the smallest.
**Return**: sl.ERROR_CODE indicating if the retrieval was successful, and why it wasn't otherwise.
**Note**:
* If you want to access the texture via script, you'll usually want to specify CPU memory. Then you can use Marshal.Copy to move them into a new byte array, which you can load into a Texture2D.
* For more info, read about the SDK method it calls: [retrieveMeasure](https://www.stereolabs.com/docs/api/classsl_1_1Camera.html#a9e0773c0c14ce5156c1fa2fde501c13e).
Use this to get an individual texture from the last grabbed frame with measurements in every pixel - such as a depth map, confidence map, etc. Measure textures are not human-viewable but don't lose accuracy, unlike image textures.
### function RetrieveVoxelMeasure
```csharp
sl.ERROR_CODE RetrieveVoxelMeasure(
sl.Mat mat,
sl.MEASURE measure =sl.MEASURE.XYZRGBA,
sl.MEM mem =sl.MEM.CPU,
sl.VoxelMeasureParameters parameters =new sl.VoxelMeasureParameters()
)
```
Retrieves a voxel-decimated point cloud from the last grabbed frame and loads it into a sl.Mat.
**Parameters**:
* **mat** sl.Mat to fill with the voxel-decimated point cloud.
* **measure** Point-cloud measure type (XYZ, XYZRGBA, XYZBGRA, XYZARGB, XYZABGR, and right variants).
* **mem** Whether the output should be on CPU or GPU memory.
* **parameters** Voxel decimation parameters. See sl.VoxelMeasureParameters.
**Return**: sl.ERROR_CODE indicating if the retrieval was successful, and why it wasn't otherwise.
**Note**: For more info, read about the SDK method it calls: [retrieveVoxelMeasure](https://www.stereolabs.com/docs/api/classsl_1_1Camera.html).
The returned mat is an unorganized 1D point cloud where each output element represents one occupied voxel. Only point-cloud measures are supported.
### function GetConfidenceThreshold
```csharp
int GetConfidenceThreshold()
```
Gets the current confidence threshold value for the disparity map (and by extension the depth map).
**Return**: Filtering value between 0 and 100.
Values below the given threshold are removed from the depth map.
### function GetDepthMinRangeValue
```csharp
float GetDepthMinRangeValue()
```
Gets the closest measurable distance by the camera, according to the camera type and depth map parameters.
**Return**: The nearest possible depth value.
### function GetCurrentMixMaxDepth
```csharp
sl.ERROR_CODE GetCurrentMixMaxDepth(
ref float min,
ref float max
)
```
Gets the current range of perceived depth.
**Parameters**:
* **min** Minimum depth detected (in selected sl.UNIT).
* **max** Maximum depth detected (in selected sl.UNIT).
**Return**: sl.ERROR_CODE.SUCCESS if values have been extracted. Other sl.ERROR_CODE otherwise.
### function GetDepthMaxRangeValue
```csharp
float GetDepthMaxRangeValue()
```
Returns the current maximum distance of depth/disparity estimation.
**Return**: The closest depth
### function EnablePositionalTracking
```csharp
sl.ERROR_CODE EnablePositionalTracking(
ref PositionalTrackingParameters positionalTrackingParameters
)
```
Initializes and starts the positional tracking processes.
**Parameters**:
* **positionalTrackingParameters** A structure containing all the specific parameters for the positional tracking. Default: a preset of PositionalTrackingParameters.
**Return**: sl.ERROR_CODE.FAILURE if the **area_file_path** file wasn't found, sl.ERROR_CODE.SUCCESS otherwise.
### function DisablePositionalTracking
```csharp
void DisablePositionalTracking(
string path =""
)
```
Disables the positional tracking.
**Parameters**:
* **path** If set, saves the spatial memory into an '.area' file. Default: (empty)
**path** is the name and path of the database, e.g. _path/to/file/myArea1.area"_.
### function IsPositionalTrackingEnabled
```csharp
bool IsPositionalTrackingEnabled()
```
Tells if the tracking module is enabled.
### function SaveAreaMap
```csharp
ERROR_CODE SaveAreaMap(
string areaFilePath
)
```
Saves the current area learning file.
**Parameters**:
* **areaFilePath** Path of an '.area' file to save the spatial memory database in.
The file will contain spatial memory data generated by the tracking.
### function GetAreaExportState
```csharp
AREA_EXPORT_STATE GetAreaExportState()
```
Returns the state of the spatial memory export process.
**Return**: The current state of the spatial memory export process.
### function ResetPositionalTracking
```csharp
sl.ERROR_CODE ResetPositionalTracking(
Quaternion rotation,
Vector3 translation
)
```
Resets the tracking, and re-initializes the position with the given translation vector and rotation quaternion.
**Parameters**:
* **rotation** Rotation to set the positional tracking to.
* **translation** Translation to set the positional tracking to.
**Return**: sl.ERROR_CODE.SUCCESS if the tracking has been reset, sl.ERROR_CODE.FAILURE otherwise.
### function GetSensorsConfiguration
```csharp
SensorsConfiguration GetSensorsConfiguration()
```
Returns the sensor configuration of the camera.
**Return**: SensorsConfiguration containing the sensor calibration information of the camera.
### function GetCameraInformation
```csharp
CameraInformation GetCameraInformation(
Resolution resolution =new Resolution()
)
```
Returns the CameraInformation associated the camera being used.
**Return**: CameraInformation containing the calibration parameters of the camera, as well as serial number and firmware version.
To ensure accurate calibration, it is possible to specify a custom resolution as a parameter when obtaining scaled information, as calibration parameters are resolution-dependent.
When reading an SVO file, the parameters will correspond to the camera used for recording.
### function GetPosition
```csharp
POSITIONAL_TRACKING_STATE GetPosition(
ref Quaternion rotation,
ref Vector3 position,
REFERENCE_FRAME referenceType =REFERENCE_FRAME.WORLD
)
```
Gets the position of the camera and the current state of the camera Tracking.
**Parameters**:
* **rotation** Quaternion filled with the current rotation of the camera depending on its reference frame.
* **position** Vector filled with the current position of the camera depending on its reference frame.
* **referenceType** Reference frame for setting the rotation/position. REFERENCE_FRAME.CAMERA gives movement relative to the last pose. REFERENCE_FRAME.WORLD gives cumulative movements since tracking started.
**Return**: The current state of the tracking process.
### function GetPositionalTrackingStatus
```csharp
PositionalTrackingStatus GetPositionalTrackingStatus()
```
Returns the current status of positional tracking module.
**Return**: The current status of positional tracking module.
### function GetPositionalTrackingLandmarks
```csharp
sl.ERROR_CODE GetPositionalTrackingLandmarks(
ref List< Landmark > landmarks
)
```
Get the current positional tracking landmarks.
**Parameters**:
* **landmarks** Array of presents landmarks.
**Return**: ERROR_CODE that indicate if the function succeed or not.
### function GetPositionalTrackingLandmarks2D
```csharp
sl.ERROR_CODE GetPositionalTrackingLandmarks2D(
ref List< Landmark2D > landmarks
)
```
Get the current positional tracking landmarks 2d.
**Parameters**:
* **landmarks** Array of presents landmarks.
**Return**: ERROR_CODE that indicate if the function succeed or not.
### function GetPosition
```csharp
POSITIONAL_TRACKING_STATE GetPosition(
ref Quaternion rotation,
ref Vector3 translation,
ref Quaternion targetQuaternion,
ref Vector3 targetTranslation,
REFERENCE_FRAME referenceFrame =REFERENCE_FRAME.WORLD
)
```
Gets the current position of the camera and state of the tracking, with an optional offset to the tracking frame.
**Parameters**:
* **rotation** Quaternion filled with the current rotation of the camera depending on its reference frame.
* **position** Vector filled with the current position of the camera depending on its reference frame.
* **targetQuaternion** Rotational offset applied to the tracking frame.
* **targetTranslation** Positional offset applied to the tracking frame.
* **referenceFrame** Reference frame for setting the rotation/position. REFERENCE_FRAME.CAMERA gives movement relative to the last pose. REFERENCE_FRAME.WORLD gives cumulative movements since tracking started.
**Return**: The current state of the tracking process.
### function GetPosition
```csharp
POSITIONAL_TRACKING_STATE GetPosition(
ref Pose pose,
REFERENCE_FRAME referenceType =REFERENCE_FRAME.WORLD
)
```
Gets the current position of the camera and state of the tracking, filling a Pose struct useful for AR pass-through.
**Parameters**:
* **pose** Current pose.
* **referenceType** Reference frame for setting the rotation/position. REFERENCE_FRAME.CAMERA gives movement relative to the last pose. REFERENCE_FRAME.WORLD gives cumulative movements since tracking started.
**Return**: The current state of the tracking process.
### function SetIMUOrientationPrior
```csharp
ERROR_CODE SetIMUOrientationPrior(
ref Quaternion rotation
)
```
Sets a prior to the IMU orientation (not for MODEL.ZED).
**Parameters**:
* **rotation** Prior rotation.
**Return**: An sl.ERROR_CODE status.
Prior must come from a external IMU, such as the HMD orientation and should be in a time frame that's as close as possible to the camera.
### function GetIMUOrientation
```csharp
ERROR_CODE GetIMUOrientation(
ref Quaternion rotation,
TIME_REFERENCE referenceTime =TIME_REFERENCE.IMAGE
)
```
Gets the rotation given by the IMU.
**Parameters**:
* **rotation** Rotation from the IMU.
**Return**: An sl.ERROR_CODE status.
**Note**: This method will return ERROR_CODE.INVALID_FUNCTION_CALL with a MODEL.ZED which does not contains internal sensors.
### function GetSensorsData
```csharp
ERROR_CODE GetSensorsData(
ref SensorsData data,
TIME_REFERENCE referenceTime =TIME_REFERENCE.IMAGE
)
```
Retrieves the SensorsData (IMU, magnetometer, barometer) at a specific time reference.
**Parameters**:
* **data** The SensorsData variable to store the data.
* **referenceTime** Defines the reference from which you want the data to be expressed. Default: REFERENCE_FRAME.WORLD.
**Return**: An sl.ERROR_CODE status.
**Note**: This method will return ERROR_CODE.INVALID_FUNCTION_CALL with a MODEL.ZED which does not contains internal sensors.
### function GetSensorsDataBatch
```csharp
ERROR_CODE GetSensorsDataBatch(
out List< SensorsData > data
)
```
Retrieves all SensorsData associated to most recent grabbed frame in the specified COORDINATE_SYSTEM of InitParameters.
**Parameters**:
* **data** SensorsData array that store the data batch.
**Return**:
### function SetRegionOfInterest
```csharp
ERROR_CODE SetRegionOfInterest(
sl.Mat roiMask,
bool[] module
)
```
Defines a region of interest to focus on for all the SDK, discarding other parts.
**Parameters**:
* **roiMask** The Mat defining the requested region of interest, pixels lower than 127 will be discarded from all modules: depth, positional tracking, etc. If empty, set all pixels as valid. The mask can be either at lower or higher resolution than the current images.
* **module** Apply the ROI to a list of SDK module, all by default. Must of size sl.MODULE.LAST. The Mat defining the requested region of interest, pixels lower than 127 will be discarded from all modules: depth, positional tracking, etc. If empty, set all pixels as valid. The mask can be either at lower or higher resolution than the current images.
**Return**: An sl.ERROR_CODE if something went wrong.
### function GetRegionOfInterest
```csharp
ERROR_CODE GetRegionOfInterest(
sl.Mat roiMask,
sl.Resolution resolution =new sl.Resolution(),
MODULE module =MODULE.ALL
)
```
Get the previously set or computed region of interest.
**Parameters**:
* **roiMask** The Mat returned
* **resolution** The optional size of the returned mask
* **module** Specifies the module from which the ROI is to be obtained.
**Return**: An sl.ERROR_CODE if something went wrong.
### function StartRegionOfInterestAutoDetection
```csharp
ERROR_CODE StartRegionOfInterestAutoDetection(
RegionOfInterestParameters roiParams
)
```
Start the auto detection of a region of interest to focus on for all the SDK, discarding other parts. This detection is based on the general motion of the camera combined with the motion in the scene. The camera must move for this process, an internal motion detector is used, based on the Positional Tracking module. It requires a few hundreds frames of motion to compute the mask.
**Parameters**:
* **roiParams**
**Return**: An sl.ERROR_CODE if something went wrong.
**Note**: This module is expecting a static portion, typically a fairly close vehicle hood at the bottom of the image. This module may not work correctly or detect incorrect background area, especially with slow motion, if there's no static element. This module work asynchronously, the status can be obtained using GetRegionOfInterestAutoDetectionStatus(), the result is either auto applied, or can be retrieve using GetRegionOfInterest function.
### function GetRegionOfInterestAutoDetectionStatus
```csharp
REGION_OF_INTEREST_AUTO_DETECTION_STATE GetRegionOfInterestAutoDetectionStatus()
```
Return the status of the automatic Region of Interest Detection. The automatic Region of Interest Detection is enabled by using StartRegionOfInterestAutoDetection
**Return**: An sl.ERROR_CODE if something went wrong.
### function EnableSpatialMapping
```csharp
sl.ERROR_CODE EnableSpatialMapping(
ref SpatialMappingParameters spatialMappingParameters
)
```
Initializes and begins the spatial mapping processes.
**Parameters**:
* **spatialMappingParameters** Spatial mapping parameters.
**Return**: sl.ERROR_CODE.SUCCESS if everything went fine, sl.ERROR_CODE.FAILURE otherwise.
### function EnableSpatialMapping
```csharp
sl.ERROR_CODE EnableSpatialMapping(
SPATIAL_MAP_TYPE type =SPATIAL_MAP_TYPE.MESH,
MAPPING_RESOLUTION mappingResolution =MAPPING_RESOLUTION.MEDIUM,
MAPPING_RANGE mappingRange =MAPPING_RANGE.MEDIUM,
bool saveTexture =false
)
```
Initializes and begins the spatial mapping processes.
**Parameters**:
* **resolutionMeter** Spatial mapping resolution in meters.
* **maxRangeMeter** Maximum scanning range in meters.
* **saveTexture** True to scan surface textures in addition to geometry.
**Return**: sl.ERROR_CODE.SUCCESS if everything went fine, sl.ERROR_CODE.FAILURE otherwise.
### function GetSpatialMappingParameters
```csharp
SpatialMappingParameters GetSpatialMappingParameters()
```
Returns the SpatialMappingParameters used.
**Return**: SpatialMappingParameters containing the parameters used for spatial mapping initialization.
It corresponds to the structure given as argument to the EnableSpatialMapping() method.
### function DisableSpatialMapping
```csharp
void DisableSpatialMapping()
```
Disables the spatial mapping process.
### function UpdateMesh
```csharp
sl.ERROR_CODE UpdateMesh(
int[] nbVerticesInSubmeshes,
int[] nbTrianglesInSubmeshes,
ref int nbUpdatedSubmesh,
int[] updatedIndices,
ref int nbVertices,
ref int nbTriangles,
int nbSubmeshMax
)
```
Updates the internal version of the mesh and returns the sizes of the meshes.
**Parameters**:
* **nbVerticesInSubmeshes** Array of the number of vertices in each sub-mesh.
* **nbTrianglesInSubmeshes** Array of the number of triangles in each sub-mesh.
* **nbUpdatedSubmesh** Number of updated sub-meshes.
* **updatedIndices** List of all sub-meshes updated since the last update.
* **nbVertices** Total number of updated vertices in all sub-meshes.
* **nbTriangles** Total number of updated triangles in all sub-meshes.
* **nbSubmeshMax** Maximum number of sub-meshes that can be handled.
**Return**: sl.ERROR_CODE indicating if the update was successful, and why it wasn't otherwise.
### function UpdateMesh
```csharp
sl.ERROR_CODE UpdateMesh(
ref Mesh mesh
)
```
Updates the internal version of the mesh and returns the sizes of the meshes.
**Parameters**:
* **mesh** The mesh to be filled with the generated spatial map.
**Return**: sl.ERROR_CODE indicating if the update was successful, and why it wasn't otherwise.
### function RetrieveMesh
```csharp
sl.ERROR_CODE RetrieveMesh(
Vector3[] vertices,
int[] triangles,
byte[] colors,
int nbSubmeshMax,
Vector2[] uvs,
IntPtr textures
)
```
Retrieves all chunks of the current generated mesh.
**Parameters**:
* **vertices** Vertices of the mesh.
* **triangles** Triangles, formatted as the index of each triangle's three vertices in the vertices array.
* **colors** (b, g, r) colors of the vertices.
* **nbSubmeshMax** Maximum number of sub-meshes that can be handled.
**Return**: sl.ERROR_CODE indicating if the retrieval was successful, and why it wasn't otherwise.
**Note**: Call UpdateMesh() before calling this.
Vertex and triangle arrays must be at least of the sizes returned by UpdateMesh (nbVertices and nbTriangles).
### function RetrieveMesh
```csharp
sl.ERROR_CODE RetrieveMesh(
ref Mesh mesh
)
```
Retrieves all chunks of the current generated mesh.
**Parameters**:
* **mesh** The mesh to be filled with the generated spatial map.
**Return**: sl.ERROR_CODE indicating if the retrieval was successful, and why it wasn't otherwise.
**Note**: Call UpdateMesh() before calling this.
Vertex and triangle arrays must be at least of the sizes returned by UpdateMesh (nbVertices and nbTriangles).
### function RetrieveChunks
```csharp
sl.ERROR_CODE RetrieveChunks(
ref Mesh mesh
)
```
Retrieve all chunks of the generated mesh.
**Parameters**:
* **mesh** The mesh to be filled with the generated spatial map.
**Return**: sl.ERROR_CODE indicating if the retrieval was successful, and why it wasn't otherwise.
### function RetrieveSpatialMap
```csharp
sl.ERROR_CODE RetrieveSpatialMap(
ref Mesh mesh
)
```
Retrieves the current generated mesh.
**Parameters**:
* **mesh** The mesh to be filled with the generated spatial map.
**Return**: sl.ERROR_CODE indicating if the retrieval was successful, and why it wasn't otherwise.
### function RetrieveSpatialMap
```csharp
sl.ERROR_CODE RetrieveSpatialMap(
ref FusedPointCloud fusedPointCloud
)
```
Retrieves the current fused point cloud.
**Parameters**:
* **fusedPointCloud** The Fused Point Cloud to be filled with the generated spatial map.
**Return**: sl.ERROR_CODE indicating if the retrieval was successful, and why it wasn't otherwise.
### function UpdateFusedPointCloud
```csharp
sl.ERROR_CODE UpdateFusedPointCloud(
ref int nbVertices
)
```
Updates the fused point cloud (if spatial map type was FUSED_POINT_CLOUD).
**Return**: sl.ERROR_CODE indicating if the update was successful, and why it wasn't otherwise.
### function RetrieveFusedPointCloud
```csharp
sl.ERROR_CODE RetrieveFusedPointCloud(
Vector4[] vertices
)
```
Retrieves all points of the fused point cloud.
**Parameters**:
* **vertices** Points of the fused point cloud.
**Return**: sl.ERROR_CODE indicating if the retrieval was successful, and why it wasn't otherwise.
**Note**: Call UpdateFusedPointCloud() before calling this.
Vertex arrays must be at least of the sizes returned by UpdateFusedPointCloud().
### function ExtractWholeSpatialMap
```csharp
ERROR_CODE ExtractWholeSpatialMap()
```
Extracts the current spatial map from the spatial mapping process.
**Return**: sl.ERROR_CODE.SUCCESS if the mesh is filled and available, otherwise sl.ERROR_CODE.FAILURE.
If the object to be filled already contains a previous version of the mesh, only changes will be updated, optimizing performance.
This is a blocking method. You should either call it in a thread or at the end of the mapping process.
### function RequestSpatialMap
```csharp
void RequestSpatialMap()
```
Starts the mesh generation process in a thread that does not block the spatial mapping process.
ZEDSpatialMappingHelper calls this each time it has finished applying the last mesh update.
### function PauseSpatialMapping
```csharp
void PauseSpatialMapping(
bool status
)
```
Pauses or resumes the spatial mapping processes.
**Parameters**:
* **status** If true, the integration is paused. If false, the spatial mapping is resumed.
### function GetMeshRequestStatus
```csharp
sl.ERROR_CODE GetMeshRequestStatus()
```
Returns the mesh generation status.
**Return**: sl.ERROR_CODE.SUCCESS if the mesh is ready and not yet retrieved, otherwise sl.ERROR_CODE.FAILURE.
Useful for knowing when to update and retrieve the mesh.
### function SaveMesh
```csharp
bool SaveMesh(
string filename,
MESH_FILE_FORMAT format
)
```
Saves the scanned mesh in a specific file format.
**Parameters**:
* **filename** Path and filename of the mesh.
* **format** File format (extension). Can be .obj, .ply or .bin.
**Return**: Has the mesh been saved successfully.
### function SavePointCloud
```csharp
bool SavePointCloud(
string filename,
MESH_FILE_FORMAT format
)
```
Saves the scanned point cloud in a specific file format.
**Parameters**:
* **filename** Path and filename of the point cloud.
* **format** File format (extension). Can be .obj, .ply or .bin.
**Return**: Has the point cloud been saved successfully.
### function LoadMesh
```csharp
bool LoadMesh(
string filename,
int[] nbVerticesInSubmeshes,
int[] nbTrianglesInSubmeshes,
ref int nbSubmeshes,
int[] updatedIndices,
ref int nbVertices,
ref int nbTriangles,
int nbSubmeshMax,
int[] textureSize =null
)
```
Loads a saved mesh file.
**Parameters**:
* **filename** Path and filename of the mesh. Should include the extension (.obj, .ply or .bin).
* **nbVerticesInSubmeshes** Array of the number of vertices in each sub-mesh.
* **nbTrianglesInSubmeshes** Array of the number of triangles in each sub-mesh.
* **nbSubmeshes** Number of sub-meshes.
* **updatedIndices** List of all sub-meshes updated since the last update.
* **nbVertices** Total number of updated vertices in all sub-meshes.
* **nbTriangles** Total number of updated triangles in all sub-meshes.
* **nbSubmeshMax** Maximum number of sub-meshes that can be handled.
* **textureSize** Array containing the sizes of all the textures (width, height) if applicable.
**Return**: Has the mesh been loaded successfully.
ZEDSpatialMapping then configures itself as if the loaded mesh was just scanned.
### function FilterMesh
```csharp
bool FilterMesh(
MESH_FILTER filterParameters,
int[] nbVerticesInSubmeshes,
int[] nbTrianglesInSubmeshes,
ref int nbSubmeshes,
int[] updatedIndices,
ref int nbVertices,
ref int nbTriangles,
int nbSubmeshMax
)
```
Filters a mesh to remove triangles while still preserving its overall shape (though less accurate).
**Parameters**:
* **filterParameters** Filter level. Higher settings remove more triangles.
* **nbVerticesInSubmeshes** Array of the number of vertices in each sub-mesh.
* **nbTrianglesInSubmeshes** Array of the number of triangles in each sub-mesh.
* **nbSubmeshes** Number of sub-meshes.
* **updatedIndices** List of all sub-meshes updated since the last update.
* **nbVertices** Total number of updated vertices in all sub-meshes.
* **nbTriangles** Total number of updated triangles in all sub-meshes.
* **nbSubmeshMax** Maximum number of sub-meshes that can be handled.
**Return**: Has the mesh been filtered successfully.
### function FilterMesh
```csharp
bool FilterMesh(
MESH_FILTER filterParameters,
ref Mesh mesh
)
```
Filters a mesh to remove triangles while still preserving its overall shape (though less accurate).
**Parameters**:
* **filterParameters** Filter level. Higher settings remove more triangles.
* **mesh** The mesh to be filled with the generated spatial map.
**Return**: Has the mesh been filtered successfully.
### function ApplyTexture
```csharp
bool ApplyTexture(
int[] nbVerticesInSubmeshes,
int[] nbTrianglesInSubmeshes,
ref int nbSubmeshes,
int[] updatedIndices,
ref int nbVertices,
ref int nbTriangles,
int[] textureSize,
int nbSubmeshMax
)
```
Applies the scanned texture onto the internal scanned mesh.
**Parameters**:
* **nbVerticesInSubmeshes** Array of the number of vertices in each sub-mesh.
* **nbTrianglesInSubmeshes** Array of the number of triangles in each sub-mesh.
* **nbSubmeshes** Number of sub-meshes.
* **updatedIndices** List of all sub-meshes updated since the last update.
* **nbVertices** Total number of updated vertices in all sub-meshes.
* **nbTriangles** Total number of updated triangles in all sub-meshes.
* **textureSize** Vector containing the size of all the texture (width, height).
* **nbSubmeshMax** Maximum number of sub-meshes that can be handled.
**Return**: Has the texture been applied successfully.
### function ApplyTexture
```csharp
bool ApplyTexture(
ref Mesh mesh
)
```
Applies the texture on a mesh.
**Parameters**:
* **mesh** Mesh with a texture to apply.
**Return**: Has the texture been applied successfully.
### function GetSpatialMappingState
```csharp
SPATIAL_MAPPING_STATE GetSpatialMappingState()
```
Returns the current spatial mapping state.
**Return**: The current state of the spatial mapping process.
As the spatial mapping runs asynchronously, this method allows you to get reported errors or status info.
### function GetGravityEstimate
```csharp
Vector3 GetGravityEstimate()
```
Gets a vector pointing toward the direction of gravity.
**Return**: Vector3 pointing downward.
This is estimated from a 3D scan of the environment, and as such, a scan must be started/finished for this value to be calculated. If using a camera other than MODEL.ZED, this is not required thanks to its IMU.
### function MergeChunks
```csharp
void MergeChunks(
int numberFaces,
int[] nbVerticesInSubmeshes,
int[] nbTrianglesInSubmeshes,
ref int nbSubmeshes,
int[] updatedIndices,
ref int nbVertices,
ref int nbTriangles,
int nbSubmesh
)
```
Consolidates the chunks from a scan.
**Parameters**:
* **numberFaces**
* **nbVerticesInSubmeshes** Array of the number of vertices in each sub-mesh.
* **nbTrianglesInSubmeshes** Array of the number of triangles in each sub-mesh.
* **nbSubmeshes** Number of sub-meshes.
* **updatedIndices** List of all sub-meshes updated since the last update.
* **nbVertices** Total number of updated vertices in all sub-meshes.
* **nbTriangles** Total number of updated triangles in all sub-meshes.
This is used to turn lots of small meshes (which are efficient for the scanning process) into several large meshes (which are more convenient to work with).
### function findFloorPlane
```csharp
sl.ERROR_CODE findFloorPlane(
ref PlaneData plane,
out float playerHeight,
Quaternion priorQuat,
Vector3 priorTrans
)
```
Detect the floor plane of the scene.
**Parameters**:
* **plane** Data on the detected plane.
* **playerHeight** Height of the camera from the newly-detected floor.
* **priorQuat** Prior rotation.
* **priorTrans** Prior position.
**Return**: sl.ERROR_CODE.SUCCESS if everything went fine, sl.ERROR_CODE.FAILURE otherwise.
Use ZEDPlaneDetectionManager.DetectFloorPlane for a higher-level version that turns planes into GameObjects.
### function FindFloorPlane
```csharp
sl.ERROR_CODE FindFloorPlane(
ref PlaneData plane,
out float playerHeight,
Quaternion priorQuat,
Vector3 priorTrans
)
```
Detect the floor plane of the scene.
**Parameters**:
* **plane** Data on the detected plane.
* **playerHeight** Height of the camera from the newly-detected floor.
* **priorQuat** Prior rotation.
* **priorTrans** Prior position.
**Return**: sl.ERROR_CODE.SUCCESS if everything went fine, sl.ERROR_CODE.FAILURE otherwise.
Use ZEDPlaneDetectionManager.DetectFloorPlane for a higher-level version that turns planes into GameObjects.
### function convertFloorPlaneToMesh
```csharp
int convertFloorPlaneToMesh(
Vector3[] vertices,
int[] triangles,
out int numVertices,
out int numTriangles
)
```
Using data from a detected floor plane, updates supplied vertex and triangle arrays with data needed to make a mesh that represents it.
**Parameters**:
* **vertices** Array to be filled with mesh vertices.
* **triangles** Array to be filled with mesh triangles, stored as indexes of each triangle's points.
* **numVertices** Total vertices in the mesh.
* **numTriangles** Total triangle indexes (3x number of triangles).
**Return**: 0 is the method was successful, 1 otherwise.
These arrays are updated directly from the wrapper.
### function ConvertFloorPlaneToMesh
```csharp
int ConvertFloorPlaneToMesh(
Vector3[] vertices,
int[] triangles,
out int numVertices,
out int numTriangles
)
```
Using data from a detected floor plane, updates supplied vertex and triangle arrays with data needed to make a mesh that represents it.
**Parameters**:
* **vertices** Array to be filled with mesh vertices.
* **triangles** Array to be filled with mesh triangles, stored as indexes of each triangle's points.
* **numVertices** Total vertices in the mesh.
* **numTriangles** Total triangle indexes (3x number of triangles).
**Return**: 0 is the method was successful, 1 otherwise.
These arrays are updated directly from the wrapper.
### function findPlaneAtHit
```csharp
sl.ERROR_CODE findPlaneAtHit(
ref PlaneData plane,
Vector2 coord,
ref PlaneDetectionParameters planeDetectionParameters
)
```
Checks the plane at the given left image coordinates.
**Parameters**:
* **plane** The detected plane if the method succeeded.
* **coord** The image coordinate. The coordinate must be taken from the full-size image.
* **parameters** A structure containing all the specific parameters for the plane detection. Default: a preset of PlaneDetectionParameters.
**Return**: sl.ERROR_CODE.SUCCESS if everything went fine, sl.ERROR_CODE.FAILURE otherwise.
### function FindPlaneAtHit
```csharp
sl.ERROR_CODE FindPlaneAtHit(
ref PlaneData plane,
Vector2 coord,
ref PlaneDetectionParameters planeDetectionParameters
)
```
Checks the plane at the given left image coordinates.
**Parameters**:
* **plane** The detected plane if the method succeeded.
* **coord** The image coordinate. The coordinate must be taken from the full-size image.
* **parameters** A structure containing all the specific parameters for the plane detection. Default: a preset of PlaneDetectionParameters.
**Return**: sl.ERROR_CODE.SUCCESS if everything went fine, sl.ERROR_CODE.FAILURE otherwise.
### function convertHitPlaneToMesh
```csharp
int convertHitPlaneToMesh(
Vector3[] vertices,
int[] triangles,
out int numVertices,
out int numTriangles
)
```
Using data from a detected hit plane, updates supplied vertex and triangle arrays with data needed to make a mesh that represents it.
**Parameters**:
* **vertices** Array to be filled with mesh vertices.
* **triangles** Array to be filled with mesh triangles, stored as indexes of each triangle's points.
* **numVertices** Total vertices in the mesh.
* **numTriangles** Total triangle indexes (3x number of triangles).
**Return**: 0 is the method was successful, 1 otherwise.
These arrays are updated directly from the wrapper.
### function ConvertHitPlaneToMesh
```csharp
int ConvertHitPlaneToMesh(
Vector3[] vertices,
int[] triangles,
out int numVertices,
out int numTriangles
)
```
Using data from a detected hit plane, updates supplied vertex and triangle arrays with data needed to make a mesh that represents it.
**Parameters**:
* **vertices** Array to be filled with mesh vertices.
* **triangles** Array to be filled with mesh triangles, stored as indexes of each triangle's points.
* **numVertices** Total vertices in the mesh.
* **numTriangles** Total triangle indexes (3x number of triangles).
**Return**: 0 is the method was successful, 1 otherwise.
These arrays are updated directly from the wrapper.
### function ConvertRangePreset
```csharp
static float ConvertRangePreset(
MAPPING_RANGE rangePreset
)
```
Updates the range to match the specified preset.
### function ConvertResolutionPreset
```csharp
static float ConvertResolutionPreset(
MAPPING_RESOLUTION resolutionPreset
)
```
Updates the resolution to match the specified preset.
### function EnableRecording
```csharp
ERROR_CODE EnableRecording(
string videoFileName,
SVO_COMPRESSION_MODE compressionMode =SVO_COMPRESSION_MODE.H264_BASED,
uint bitrate =0,
int targetFPS =0,
bool transcode =false,
string encryptionKey ="",
SVO_ENCODING_PRESET encodingPreset =SVO_ENCODING_PRESET.DEFAULT
)
```
Creates an SVO file to be filled by EnableRecording() and DisableRecording().
**Parameters**:
* **videoFileName** Filename of the recording. Whether it ends with .svo or .avi defines its file type.
* **compressionMode** The compression to use for recording.
* **bitrate** Override default bitrate with a custom bitrate (Kbits/s).
* **targetFPS** Use another fps than camera FPS. Must respect camera_fpstarget_fps == 0.
* **transcode** If input is in streaming mode, dump directly into SVO file (transcode=false) or decode/encode (transcode=true).
* **encryptionKey** Key to encrypt the SVO file. If empty, the file will not be encrypted.
* **encodingPreset** Preset for the encoding parameters. Default is the default preset of the encoder, which is a balanced preset between quality and speed.
**Return**: An sl.ERROR_CODE that defines if the file was successfully created and can be filled with images.
**Note**: An SVO is Stereolabs' own format designed for the ZED. It holds the video feed with timestamps as well as info about the camera used to record it.
### function EnableRecording
```csharp
ERROR_CODE EnableRecording(
RecordingParameters recordingParameters
)
```
Creates an SVO file to be filled by EnableRecording() and DisableRecording().
**Parameters**:
* **recordingParameters** A structure containing all the recording parameters.
**Return**: An sl.ERROR_CODE that defines if the file was successfully created and can be filled with images.
### function GetRecordingStatus
```csharp
sl.RecordingStatus GetRecordingStatus()
```
Get the recording information.
**Return**: The recording state structure. For more details, see RecordingStatus.
### function GetRecordingParameters
```csharp
sl.RecordingParameters GetRecordingParameters()
```
Returns the RecordingParameters used.
**Return**: sl.RecordingParameters containing the parameters used for recording initialization.
It corresponds to the structure given as argument to the EnableRecording() method.
### function PauseRecording
```csharp
void PauseRecording(
bool status
)
```
Pauses or resumes the recording.
**Parameters**:
* **status** If true, the recording is paused. If false, the recording is resumed.
### function DisableRecording
```csharp
void DisableRecording()
```
Disables the recording initiated by EnableRecording() and closes the generated file.
### function IngestDataIntoSVO
```csharp
ERROR_CODE IngestDataIntoSVO(
ref SVOData data
)
```
Ingest SVOData in a SVO file.
**Parameters**:
* **data** Data to ingest in the SVO file..
**Return**:
Note: The method works only if the camera is recording.
### function RetrieveSVOData
```csharp
ERROR_CODE RetrieveSVOData(
string key,
ref List< SVOData > data,
ulong tsBegin =0,
ulong tsEnd =0
)
```
Retrieves SVO data from the SVO file at the given channel key and in the given timestamp range.
**Parameters**:
* **key** The key of the SVOData that is going to be retrieved.
* **data** The map to be filled with SVOData objects, with timestamps as keys.
* **tsBegin** The beginning of the range.
* **tsEnd** The end of the range.
**Return**: sl.ERROR_CODE.SUCCESS in case of success, sl.ERROR_CODE.FAILURE otherwise.
### function GetSVODataKeys
```csharp
List< string > GetSVODataKeys()
```
Gets the external channels that can be retrieved from the SVO file.
**Return**: List of available keys.
### function EnableStreaming
```csharp
ERROR_CODE EnableStreaming(
STREAMING_CODEC codec =STREAMING_CODEC.H264_BASED,
uint bitrate =8000,
ushort port =30000,
int gopSize =-1,
bool adaptativeBitrate =false,
int chunkSize =32768,
int targetFPS =0
)
```
Creates an streaming pipeline.
**Parameters**:
* **codec** Defines the codec used for streaming.
* **bitrate** Defines the streaming bitrate in Kbits/s.
* **port** Defines the port used for streaming.
* **gopSize** Defines the gop size in number of frames.
* **adaptativeBitrate** Enable/Disable adaptive bitrate.
* **chunkSize** Defines a single chunk size.
* **targetFPS** Defines the target framerate for the streaming output.
**Return**: An sl.ERROR_CODE that defines if the streaming pipe was successfully created.
### function EnableStreaming
```csharp
ERROR_CODE EnableStreaming(
ref StreamingParameters streamingParameters
)
```
Creates an streaming pipeline.
**Parameters**:
* **streamingParameters** A structure containing all the specific parameters for the streaming. Default: a preset of StreamingParameters.
**Return**: An sl.ERROR_CODE that defines if the streaming pipe was successfully created.
### function IsStreamingEnabled
```csharp
bool IsStreamingEnabled()
```
Tells if the streaming is running.
**Return**: Has the streaming been enabled successfully.
### function DisableStreaming
```csharp
void DisableStreaming()
```
Disables the streaming initiated by EnableStreaming().
### function GetStreamingParameters
```csharp
sl.StreamingParameters GetStreamingParameters()
```
Returns the StreamingParameters used.
**Return**: sl.StreamingParameters containing the parameters used for streaming initialization.
It corresponds to the structure given as argument to the EnableStreaming() method.
### function EnableObjectDetection
```csharp
sl.ERROR_CODE EnableObjectDetection(
ref ObjectDetectionParameters od_params
)
```
Initializes and starts object detection module.
**Parameters**:
* **od_params** A structure containing all the specific parameters for the object detection. Default: a preset of ObjectDetectionParameters.
**Return**: An sl.ERROR_CODE that indicates the type of error.
### function EnableBodyTracking
```csharp
sl.ERROR_CODE EnableBodyTracking(
ref BodyTrackingParameters bt_params
)
```
Initializes and starts body tracking module.
**Parameters**:
* **bt_params** A structure containing all the specific parameters for the body tracking. Default: a preset of BodyTrackingParameters.
**Return**: An sl.ERROR_CODE that indicates the type of error.
### function DisableObjectDetection
```csharp
void DisableObjectDetection(
uint instanceID =0,
bool disableAllInstance =false
)
```
Disable object detection module and release the resources.
**Parameters**:
* **instanceID** Id of the object detection instance. Used when multiple instances of the object detection module are enabled at the same time.
* **disableAllInstance** Should disable all instances of the object detection module or just **instanceID**.
### function DisableBodyTracking
```csharp
void DisableBodyTracking(
uint instanceID =0,
bool disableAllInstance =false
)
```
Disable body tracking module and release the resources.
**Parameters**:
* **instanceID** Id of the body tracking module instance. Used when multiple instances of the body tracking module module are enabled at the same time.
* **disableAllInstance** Should disable all instances of the body tracking module or just **instanceID**.
### function GetObjectDetectionParameters
```csharp
sl.ObjectDetectionParameters GetObjectDetectionParameters()
```
Returns the ObjectDetectionParameters used.
**Return**: sl.ObjectDetectionParameters containing the parameters used for object detection initialization.
It corresponds to the structure given as argument to the EnableObjectDetection() method.
### function GetBodyTrackingParameters
```csharp
sl.BodyTrackingParameters GetBodyTrackingParameters()
```
Returns the BodyTrackingParameters used.
**Return**: sl.BodyTrackingParameters containing the parameters used for body tracking initialization.
It corresponds to the structure given as argument to the EnableBodyTracking() method.
### function IngestCustomBoxObjects
```csharp
sl.ERROR_CODE IngestCustomBoxObjects(
List< CustomBoxObjectData > objects_in
)
```
Feed the 3D Object tracking method with your own 2D bounding boxes from your own detection algorithm.
**Parameters**:
* **objects_in** List of CustomBoxObjectData to feed the object detection.
* **instanceID** Id of the object detection instance. Used when multiple instances of the object detection module are enabled at the same time.
**Return**: sl.ERROR_CODE.SUCCESS if everything went fine.
### function IngestCustomMaskObjects
```csharp
sl.ERROR_CODE IngestCustomMaskObjects(
List< CustomMaskObjectData > masks_in
)
```
Feed the 3D Object tracking function with your own 2D bounding boxes with masks from your own detection algorithm.
**Parameters**:
* **masks_in** Masks
**Return**: sl.ERROR_CODE.SUCCESS if everything went fine.
### function RetrieveObjects
```csharp
sl.ERROR_CODE RetrieveObjects(
ref Objects objs,
ref ObjectDetectionRuntimeParameters od_params,
uint instanceID =0
)
```
Retrieve objects detected by the object detection module.
**Parameters**:
* **objs** Retrieved objects.
* **od_params** Object detection runtime parameters
* **instanceID** Id of the object detection instance. Used when multiple instances of the object detection module are enabled at the same time.
**Return**: sl.ERROR_CODE.SUCCESS if everything went fine, sl.ERROR_CODE.FAILURE otherwise.
### function SetObjectDetectionRuntimeParameters
```csharp
sl.ERROR_CODE SetObjectDetectionRuntimeParameters(
ObjectDetectionRuntimeParameters objectDetectionRuntimeParameters,
uint instanceID =0
)
```
Set the object detection module instance runtime parameters By default the object detection module will use the parameters set in the ObjectDetectionRuntimeParameters constructor. This can be changed at any time, however since the processing is done in parallel, the parameters will be used for the next inference. This function can be called only on parameters change, the previous values will be applied during inference.
**Parameters**:
* **objectDetectionRuntimeParameters**
* **instanceID**
**Return**:
### function RetrieveCustomObjects
```csharp
sl.ERROR_CODE RetrieveCustomObjects(
ref Objects objs,
ref CustomObjectDetectionRuntimeParameters od_params,
uint instanceID =0
)
```
Retrieve objects detected by the custom object detection module.
**Parameters**:
* **objs** Custom object detection runtime settings, can be changed at each detection. In async mode, the parameters update is applied on the next iteration.
* **od_params** The detected objects will be saved into this object. If the object already contains data from a previous detection, it will be updated, keeping a unique ID for the same person.
* **instanceID** Id of the object detection instance. Used when multiple instances of the object detection module are enabled at the same time.
**Return**: sl.ERROR_CODE.SUCCESS if everything went fine, sl.ERROR_CODE.FAILURE otherwise.
### function SetCustomObjectDetectionRuntimeParameters
```csharp
sl.ERROR_CODE SetCustomObjectDetectionRuntimeParameters(
CustomObjectDetectionRuntimeParameters customObjectDetectionRuntimeParameters,
uint instanceID =0
)
```
Set the Object detection module instance runtime parameters when using the Custom model (OBJECT_DETECTION_MODEL::CUSTOM_BOX_OBJECTS and CUSTOM_BOX_OBJECTS::CUSTOM_YOLOLIKE_BOX_OBJECTS) By default the object detection module will use the parameters set in the CustomObjectDetectionRuntimeParameters constructor. This can be changed at any time, however since the processing is done in parallel, the parameters will be used for the next inference. This function can be called only on parameters change, the previous values will be applied during inference.
**Parameters**:
* **customObjectDetectionRuntimeParameters**
* **instanceID**
**Return**:
### function RetrieveBodies
```csharp
sl.ERROR_CODE RetrieveBodies(
ref Bodies bodies,
ref BodyTrackingRuntimeParameters bt_params,
uint instanceID =0
)
```
Retrieve bodies detected by the body tracking module.
**Parameters**:
* **objs** Retrieved bodies.
* **bt_params** Body tracking runtime parameters
* **instanceID** Id of the body tracking instance. Used when multiple instances of the body tracking module are enabled at the same time.
**Return**: sl.ERROR_CODE.SUCCESS if everything went fine, sl.ERROR_CODE.FAILURE otherwise.
### function SetBodyTrackingRuntimeParameters
```csharp
sl.ERROR_CODE SetBodyTrackingRuntimeParameters(
BodyTrackingRuntimeParameters bodyTrackingRuntimeParameters,
uint instanceID =0
)
```
Set the Body tracking module instance runtime parameters By default the Body tracking module will use the parameters set in the BodyTrackingRuntimeParameters constructor. This can be changed at any time, however since the processing is done in parallel, the parameters will be used for the next inference. This function can be called only on parameters change, the previous values will be applied during inference.
**Parameters**:
* **bodyTrackingRuntimeParameters**
* **instanceID**
**Return**:
### function UpdateObjectsBatch
```csharp
sl.ERROR_CODE UpdateObjectsBatch(
out int nbBatches
)
```
Update the batch trajectories and retrieve the number of batches.
**Parameters**:
* **nbBatches** Numbers of batches.
**Return**: An sl.ERROR_CODE that indicates the type of error.
### function GetObjectsBatch
```csharp
sl.ERROR_CODE GetObjectsBatch(
int batch_index,
ref ObjectsBatch objectsBatch
)
```
Retrieve a batch of objects.
**Parameters**:
* **batch_index** Index of the batch retrieved.
* **objectsBatch** Trajectory that will be filled by the batching queue process.
**Return**: An sl.ERROR_CODE that indicates the type of error.
**Note**:
* This method need to be called after RetrieveObjects(), otherwise trajectories will be empty.
* It also needs to be called after UpdateObjectsBatch() in order to retrieve the number of batch trajectories.
* To retrieve all the objects' batches, you need to iterate from 0 to nbBatches (retrieved from UpdateObjectsBatch()).
### function CheckAIModelStatus
```csharp
static AI_Model_status CheckAIModelStatus(
AI_MODELS model,
int gpu_id =0
)
```
Check if a corresponding optimized engine is found for the requested model based on your rig configuration.
**Parameters**:
* **model** AI model to check.
* **gpu_id** ID of the gpu.
**Return**: The status of the AI model.
### function OptimizeAIModel
```csharp
static sl.ERROR_CODE OptimizeAIModel(
AI_MODELS model,
int gpu_id =0
)
```
Optimize the requested model, possible download if the model is not present on the host.
**Parameters**:
* **model** AI model to optimize.
* **gpu_id** ID of the gpu to optimize on.
**Return**: An sl.ERROR_CODE that indicates the type of error.
### function dllz_free
```csharp
void dllz_free(
IntPtr ptr
)
```
### function Camera
```csharp
Camera(
int id
)
```
Default constructor.
**Parameters**:
* **id**
Creates an empty Camera object.
### function Open
```csharp
ERROR_CODE Open(
ref InitParameters initParameters
)
```
Opens the ZED camera from the provided InitParameters.
**Parameters**:
* **initParameters** A structure containing all the initial parameters. Default: a preset of InitParameters.
**Return**: An error code giving information about the internal process. If ERROR_CODE.SUCCESS is returned, the camera is ready to use. Every other code indicates an error and the program should be stopped.
The method will also check the hardware requirements and run a self-calibration.
### function OpenFromCameraId
```csharp
ERROR_CODE OpenFromCameraId(
ref InitParameters initParameters
)
```
Opens the camera identified by its camera index (slot), using the provided init parameters.
**Parameters**:
* **initParameters** Initialization parameters.
**Return**: sl.ERROR_CODE.SUCCESS if the camera was opened successfully.
### function OpenFromSerialNumber
```csharp
ERROR_CODE OpenFromSerialNumber(
ref InitParameters initParameters
)
```
Opens the camera identified by its serial number, using the provided init parameters.
**Parameters**:
* **initParameters** Initialization parameters.
**Return**: sl.ERROR_CODE.SUCCESS if the camera was opened successfully.
### function OpenFromSVOFile
```csharp
ERROR_CODE OpenFromSVOFile(
ref InitParameters initParameters
)
```
Opens the camera from an SVO file, using the provided init parameters.
**Parameters**:
* **initParameters** Initialization parameters. InitParameters.pathSVO must be set.
**Return**: sl.ERROR_CODE.SUCCESS if the camera was opened successfully.
### function OpenFromStream
```csharp
ERROR_CODE OpenFromStream(
ref InitParameters initParameters
)
```
Opens the camera from a network stream, using the provided init parameters.
**Parameters**:
* **initParameters** Initialization parameters. InitParameters.ipStream and InitParameters.portStream must be set.
**Return**: sl.ERROR_CODE.SUCCESS if the camera was opened successfully.
### function Close
```csharp
void Close()
```
Closes the camera.
Once destroyed, you need to recreate a camera instance to restart again.
### function Grab
```csharp
sl.ERROR_CODE Grab(
ref sl.RuntimeParameters runtimeParameters
)
```
This method will grab the latest images from the camera, rectify them, and compute the measurements based on the RuntimeParameters provided (depth, point cloud, tracking, etc.).
**Parameters**:
* **runtimeParameters** A structure containing all the runtime parameters. Default: a preset of RuntimeParameters.
**Return**: false if no problem was encountered, true otherwise.
**Note**: For more info, read about the SDK method it calls: [grab](https://www.stereolabs.com/docs/api/classsl_1_1Camera.html#afa3678a18dd574e162977e97d7cbf67b).
The grabbing method is typically called in the main loop in a separate thread.
### function Read
```csharp
sl.ERROR_CODE Read()
```
Reads the next available frame without running depth or tracking processing. Useful when decoding camera frames independently of the full grab pipeline.
**Return**: sl.ERROR_CODE.SUCCESS if a new frame was available.
### function StartPublishing
```csharp
ERROR_CODE StartPublishing(
ref CommunicationParameters commParams
)
```
Set this camera as a data provider for the Fusion module.
**Parameters**:
* **jsonConfigFileName**
**Return**: ERROR_CODE "ERROR_CODE.SUCCESS" if everything went fine, ERROR_CODE.FAILURE otherwise.
### function StopPublishing
```csharp
ERROR_CODE StopPublishing()
```
Set this camera as normal camera(without data providing).
### function GetInputType
```csharp
sl.INPUT_TYPE GetInputType()
```
Return the sl.INPUT_TYPE currently used.
**Return**: The current sl.INPUT_TYPE.
### function GetCalibrationParameters
```csharp
CalibrationParameters GetCalibrationParameters(
bool raw =false
)
```
Return the calibration parameters of the camera.
**Parameters**:
* **raw** Whether to return the raw or rectified calibration parameters.
**Return**: CalibrationParameters containing the calibration parameters requested.
### function GetCameraModel
```csharp
sl.MODEL GetCameraModel()
```
Gets the camera model (sl.MODEL).
**Return**: Model of the camera as sl.MODEL.
### function GetCameraFirmwareVersion
```csharp
int GetCameraFirmwareVersion()
```
Gets the camera firmware version.
**Return**: The firmware version of the camera.
### function GetSensorsFirmwareVersion
```csharp
int GetSensorsFirmwareVersion()
```
Gets the sensors firmware version.
**Return**: The firmware version of the camera.
### function GetZEDSerialNumber
```csharp
int GetZEDSerialNumber()
```
Gets the camera's serial number.
**Return**: The serial number of the camera.
### function GetFOV
```csharp
float GetFOV()
```
Returns the camera's vertical field of view in radians.
**Return**: The vertical field of view.
### function UpdateSelfCalibration
```csharp
void UpdateSelfCalibration()
```
Perform a new self calibration process.
**Note**: The self calibration will occur at the next Grab() call. New values will then be available in GetCameraInformation(), be sure to get them to still have consistent 2D - 3D conversion.
In some cases, due to temperature changes or strong vibrations, the stereo calibration becomes less accurate.
Use this method to update the self-calibration data and get more reliable depth values.
### function GetFrameDroppedCount
```csharp
uint GetFrameDroppedCount()
```
Gets the number of frames dropped since Grab() was called for the first time.
**Return**: Frames dropped since first Grab() call.
**Note**: It is similar to the Frame Drop display in the ZED Explorer app.
It is based on camera timestamps and an FPS comparison.
### function GetHealthStatus
```csharp
sl.HealthStatus GetHealthStatus()
```
Returns the self-diagnostic health status of the camera (image, depth, sensor quality).
**Return**: sl.HealthStatus filled with the current diagnostic results.
### function GetRetrieveImageResolution
```csharp
sl.Resolution GetRetrieveImageResolution()
```
Returns the effective resolution used when retrieving images (after any downscaling applied by the SDK).
**Return**: The actual image retrieval resolution.
### function GetRetrieveMeasureResolution
```csharp
sl.Resolution GetRetrieveMeasureResolution()
```
Returns the effective resolution used when retrieving depth measures (after any downscaling applied by the SDK).
**Return**: The actual measure retrieval resolution.
### function SaveCurrentImageInFile
```csharp
sl.ERROR_CODE SaveCurrentImageInFile(
sl.VIEW view,
String filename
)
```
Save current image (specified by view) in a file defined by filename.
**Parameters**:
* **side** sl.SIDE on which to save the image.
* **filename** Filename must end with .jpg or .png.
**Return**: An sl.ERROR_CODE that indicates the type of error.
Supported formats are JPEG and PNG.
Filename must end with either .jpg or .png.
### function SaveCurrentDepthInFile
```csharp
sl.ERROR_CODE SaveCurrentDepthInFile(
SIDE side,
String filename
)
```
Save the current depth in a file defined by filename.
**Parameters**:
* **side** sl.SIDE on which to save the depth.
* **filename** Filename must end with .png, .pfm or .pgm.
**Return**: An sl.ERROR_CODE that indicates the type of error.
Supported formats are PNG, PFM and PGM.
### function SaveCurrentPointCloudInFile
```csharp
sl.ERROR_CODE SaveCurrentPointCloudInFile(
SIDE side,
String filename
)
```
Save the current point cloud in a file defined by filename.
**Parameters**:
* **side** sl.SIDE on which to save the point cloud.
* **filename** Filename must end with .ply, .xyz , .vtk or .pcd.
**Return**: An sl.ERROR_CODE that indicates the type of error.
Supported formats are PLY, VTK, XYZ and PCD.
### function UnloadPlugin
```csharp
static void UnloadPlugin()
```
### function UnloadInstance
```csharp
static void UnloadInstance(
int id
)
```
### function GenerateUniqueID
```csharp
static string GenerateUniqueID()
```
Generate a UUID like unique id to help identify and track AI detections.
**Return**: A UUID like unique id.
### function GetSDKVersion
```csharp
static string GetSDKVersion()
```
Gets the version of the currently installed ZED SDK.
**Return**: ZED SDK version as a string in the format MAJOR.MINOR.PATCH.
### function ConvertCoordinateSystem
```csharp
static sl.ERROR_CODE ConvertCoordinateSystem(
ref Quaternion rotation,
ref Vector3 translation,
sl.COORDINATE_SYSTEM coordinateSystemSrc,
sl.COORDINATE_SYSTEM coordinateSystemDest
)
```
Change the coordinate system of a transform matrix.
**Parameters**:
* **rotation** [In, Out] : rotation to transform
* **translation** [In, Out] : translation to transform
* **coordinateSystemSrc** The current coordinate system of the translation/rotation
* **coordinateSystemDest** The destination coordinate system for the translation/rotation.
**Return**: SUCCESS if everything went well, FAILURE otherwise.
### function IsCameraOne
```csharp
static bool IsCameraOne(
sl.MODEL model
)
```
Returns whether the given camera model is a monocular (ZED One) camera.
### function IsResolutionAvailable
```csharp
static bool IsResolutionAvailable(
sl.RESOLUTION resolution,
sl.MODEL model
)
```
Returns whether the given resolution is supported by the given camera model.
### function IsFPSAvailable
```csharp
static bool IsFPSAvailable(
int fps,
sl.RESOLUTION resolution,
sl.MODEL model
)
```
Returns whether the given FPS is supported for the given resolution and camera model.
### function IsHDRAvailable
```csharp
static bool IsHDRAvailable(
sl.RESOLUTION resolution,
sl.MODEL model
)
```
Returns whether HDR is available for the given resolution and camera model.
### function GetSDKVersion
```csharp
static void GetSDKVersion(
ref int major,
ref int minor,
ref int patch
)
```
Gets the version of the currently installed ZED SDK.
**Return**: ZED SDK version as a string in the format MAJOR.MINOR.PATCH.
### function GetDeviceList
```csharp
static sl.DeviceProperties[] GetDeviceList(
out int nbDevices
)
```
List all the connected devices with their associated information.
**Return**: The device properties for each connected camera.
This method lists all the cameras available and provides their serial number, models and other information.
### function GetStreamingDeviceList
```csharp
static sl.StreamingProperties[] GetStreamingDeviceList(
out int nbDevices
)
```
List all the streaming devices with their associated information.
**Return**: The device properties for each connected camera.
This method lists all the cameras available and provides their serial number, models and other information.
### function Reboot
```csharp
static sl.ERROR_CODE Reboot(
int serialNumber,
bool fullReboot =true
)
```
Performs a hardware reset of the ZED 2 and the ZED 2i.
**Parameters**:
* **serialNumber** Serial number of the camera to reset, or 0 to reset the first camera detected.
* **fullReboot** Perform a full reboot (sensors and video modules) if true, otherwise only the video module will be rebooted.
**Return**: sl.ERROR_CODE.SUCCESS if everything went fine, sl.ERROR_CODE::CAMERA_NOT_DETECTED if no camera was detected, sl.ERROR_CODE.FAILURE otherwise.
### function SetTimestampClock
```csharp
static void SetTimestampClock(
sl.TIMESTAMP_CLOCK clock
)
```
Sets the clock source used for all SDK timestamps (images and sensors). This is a process-wide setting shared by all camera instances. Call this before opening any camera.
**Parameters**:
* **clock** The desired TIMESTAMP_CLOCK.
### function GetTimestampClock
```csharp
static sl.TIMESTAMP_CLOCK GetTimestampClock()
```
Returns the clock source currently used for SDK timestamps.
### function SetMaxSystemClockStepMs
```csharp
static void SetMaxSystemClockStepMs(
float limitMs
)
```
Sets the maximum system-clock step (ms) the SDK follows per sample when the host clock is adjusted backward. Only meaningful in TIMESTAMP_CLOCK.SYSTEM_CLOCK mode.
**Parameters**:
* **limitMs** Clamp threshold. 4 ms by default; negative = disable; 0 = freeze.
### function GetMaxSystemClockStepMs
```csharp
static float GetMaxSystemClockStepMs()
```
Returns the current system-clock step clamp in milliseconds.
## Public Property Documentation
### property ImageWidth
```csharp
int ImageWidth;
```
Width of the images returned by the camera in pixels.
It corresponds to the camera's current resolution setting.
### property ImageHeight
```csharp
int ImageHeight;
```
Height of the images returned by the camera in pixels.
It corresponds to the camera's current resolution setting.
### property Baseline
```csharp
float Baseline;
```
Baseline of the camera (distance between the cameras).
Extracted from calibration files.
### property HorizontalFieldOfView
```csharp
float HorizontalFieldOfView;
```
Current horizontal field of view in degrees of the camera.
### property VerticalFieldOfView
```csharp
float VerticalFieldOfView;
```
Current vertical field of view in degrees of the camera.
### property SensorsConfiguration
```csharp
SensorsConfiguration SensorsConfiguration;
```
### property CalibrationParametersRaw
```csharp
CalibrationParameters CalibrationParametersRaw;
```
Stereo parameters for current ZED camera prior to rectification (distorted).
### property CalibrationParametersRectified
```csharp
CalibrationParameters CalibrationParametersRectified;
```
Stereo parameters for current ZED camera after rectification (undistorted).
### property CameraModel
```csharp
sl.MODEL CameraModel;
```
Model of the camera.
### property IsCameraReady
```csharp
bool IsCameraReady;
```
Whether the camera has been successfully initialized.
## Public Attributes Documentation
### variable CameraID
```csharp
int CameraID = 0;
```
Camera ID (for multiple cameras)
---
# sl::InitParameters
**Module:** **Video Module**
Class containing the options used to initialize the sl.Camera object. More...
## Detailed Description
```csharp
class sl::InitParameters;
```
Class containing the options used to initialize the sl.Camera object.
**Note**: For more info, read about the ZED SDK C++ class it mirrors: [InitParameters](https://www.stereolabs.com/docs/api/structsl_1_1InitParameters.html)
This class allows you to select multiple parameters for the sl.Camera such as the selected camera, resolution, depth mode, coordinate system, and units of measurement.
Once filled with the desired options, it should be passed to the sl.Camera.Open() method.
## Public Functions Documentation
### function SetFromCameraID
```csharp
void SetFromCameraID(
int cameraID
)
```
Set the input as the camera with specified id.
**Parameters**:
* **cameraID**
### function SetFromSerialNumber
```csharp
void SetFromSerialNumber(
uint serialNumber
)
```
Set the input as the camera with specified serial number.
**Parameters**:
* **serialNumber**
### function SetFromSVOFile
```csharp
void SetFromSVOFile(
string svoFilePath
)
```
Set the input as the SVO specified with the filename.
**Parameters**:
* **svoFilePath**
### function SetFromGMSLPort
```csharp
void SetFromGMSLPort(
int port
)
```
### function SetFromStream
```csharp
void SetFromStream(
string ipAddress,
ushort port =30000
)
```
### function InitParameters
```csharp
InitParameters()
```
Default constructor.
All the parameters are set to their default and optimized values.
## Public Attributes Documentation
### variable inputType
```csharp
sl.INPUT_TYPE inputType;
```
Defines the input source to initialize and open an sl.Camera object from.
**Note**:
* Available cameras and their id/serial number can be listed using sl.Camera.GetDeviceList() and sl.Camera.GetStreamingDeviceList().
* Each sl.Camera will create its own memory (CPU and GPU), therefore the number of cameras used at the same time can be limited by the configuration of your computer (GPU/CPU memory and capabilities).
* See sl.InputType for complementary information.
The SDK can handle different input types:
* Select a camera by its ID (_/dev/videoX_ on Linux, and 0 to N cameras connected on Windows)
* Select a camera by its serial number
* Open a recorded sequence in the SVO file format
* Open a streaming camera from its IP address and port
Default : (empty)
### variable resolution
```csharp
sl.RESOLUTION resolution;
```
Desired camera resolution.
**Note**:
* Small resolutions offer higher framerate and lower computation time.
* In most situations, sl.RESOLUTION.HD720 at 60 FPS is the best balance between image quality and framerate.
* Available resolutions are listed here: sl.RESOLUTION.
Default: sl.RESOLUTION.AUTO
* Resolves to sl.RESOLUTION.HD1200 for ZED X/X Mini
* Resolves to sl.RESOLUTION.HD720 for other cameras
### variable cameraFPS
```csharp
int cameraFPS;
```
Requested camera frame rate.
**Note**: If the requested cameraFPS is unsupported, the closest available FPS will be used.
If set to 0, the highest FPS of the specified camera_resolution will be used.
Default: 0
See sl.RESOLUTION for a list of supported frame rates.
### variable cameraDeviceID
```csharp
int cameraDeviceID;
```
Id for identifying which camera to use from the connected cameras.
### variable serialNumber
```csharp
uint serialNumber;
```
SN for identifying which camera to use from the connected cameras.
### variable pathSVO
```csharp
string pathSVO = "";
```
Path to a recorded SVO file to play, including filename.
### variable gmslPort
```csharp
int gmslPort = 0;
```
gmsl port used to open a ZED camera connected through GMSL interface.
### variable svoRealTimeMode
```csharp
bool svoRealTimeMode;
```
Defines if sl.Camera object return the frame in real time mode.
**Note**: sl.Camera.Grab() will return an error when trying to play too fast, and frames will be dropped when playing too slowly.
When playing back an SVO file, each call to sl.Camera.Grab() will extract a new frame and use it.
However, it ignores the real capture rate of the images saved in the SVO file.
Enabling this parameter will bring the SDK closer to a real simulation when playing back a file by using the images' timestamps.
Default: false
### variable svoDecryptionKey
```csharp
string svoDecryptionKey = "";
```
Optional passphrase or key to decrypt an encrypted SVO file.
This must match the key used at recording time.
Default: "" (no decryption)
### variable coordinateUnits
```csharp
UNIT coordinateUnits;
```
Unit of spatial data (depth, point cloud, tracking, mesh, etc.) for retrieval.
Default: sl.UNIT.MILLIMETER
### variable coordinateSystem
```csharp
COORDINATE_SYSTEM coordinateSystem;
```
sl.COORDINATE_SYSTEM to be used as reference for positional tracking, mesh, point clouds, etc.
This parameter allows you to select the sl.COORDINATE_SYSTEM used by the sl.Camera object to return its measures.
This defines the order and the direction of the axis of the coordinate system.
Default: sl.COORDINATE_SYSTEM.IMAGE
### variable depthMode
```csharp
sl.DEPTH_MODE depthMode;
```
sl.DEPTH_MODE to be used.
**Note**: Available depth mode are listed here: sl.DEPTH_MODE.
The ZED SDK offers several sl.DEPTH_MODE, offering various levels of performance and accuracy.
This parameter allows you to set the sl.DEPTH_MODE that best matches your needs.
Default: sl.DEPTH_MODE.NEURAL
### variable depthMinimumDistance
```csharp
float depthMinimumDistance;
```
Minimum depth distance to be returned, measured in the sl.UNIT defined in coordinateUnits.
**Note**:
* depthMinimumDistance value cannot be greater than 3 meters.
* 0 will imply that depthMinimumDistance is set to the minimum depth possible for each camera (those values are available [here](https://www.stereolabs.com/docs/depth-sensing/depth-settings#depth-range)).
This parameter allows you to specify the minimum depth value (from the camera) that will be computed.
In stereovision (the depth technology used by the camera), looking for closer depth values can have a slight impact on performance and memory consumption.
On most of modern GPUs, performance impact will be low. However, the impact of memory footprint will be visible.
In cases of limited computation power, increasing this value can provide better performance.
Default: -1 (corresponding values are available [here](https://www.stereolabs.com/docs/depth-sensing/depth-settings#depth-range))
### variable depthMaximumDistance
```csharp
float depthMaximumDistance;
```
Maximum depth distance to be returned, measured in the sl.UNIT defined in coordinateUnits.
**Note**:
* Changing this value has no impact on performance and doesn't affect the positional tracking nor the spatial mapping.
* It only change values the depth, point cloud and normals.
When estimating the depth, the ZED SDK uses this upper limit to turn higher values into **inf** ones.
### variable cameraImageFlip
```csharp
FLIP_MODE cameraImageFlip;
```
Defines if a flip of the images is needed.
**Note**:
* From ZED SDK 3.2 a new sl.FLIP_MODE enum was introduced to add the automatic flip mode detection based on the IMU gravity detection.
* This does not work on sl.MODEL.ZED cameras since they do not have the necessary sensors.
If you are using the camera upside down, setting this parameter to sl.FLIP_MODE.ON will cancel its rotation.
The images will be horizontally flipped.
Default: sl.FLIP_MODE.OFF
### variable enableRightSideMeasure
```csharp
bool enableRightSideMeasure;
```
Enable the measurement computation on the right images.
By default, the ZED SDK only computes a single depth map, aligned with the left camera image.
This parameter allows you to enable sl.MEASURE.DEPTH_RIGHT and other sl.MEASURE.XXX_RIGHT at the cost of additional computation time.
For example, mixed reality pass-through applications require one depth map per eye, so this parameter can be activated.
Default: False
### variable cameraDisableSelfCalib
```csharp
bool cameraDisableSelfCalib;
```
Disables the self-calibration process at camera opening.
**Note**:
* In most situations, self calibration should remain enabled.
* You can also trigger the self-calibration at anytime after sl.Camera.Open() by calling sl.Camera.UpdateSelfCalibration(), even if this parameter is set to true.
At initialization, sl.Camera runs a self-calibration process that corrects small offsets from the device's factory calibration.
A drawback is that calibration parameters will slightly change from one (live) run to another, which can be an issue for repeatability.
If set to true, self-calibration will be disabled and calibration parameters won't be optimized, raw calibration parameters from the configuration file will be used.
Default: false
### variable sdkVerbose
```csharp
int sdkVerbose;
```
Enable the ZED SDK verbose mode.
**Note**:
* The verbose messages can also be exported into a log file.
* See sdkVerboseLogFile for more.
This parameter allows you to enable the verbosity of the ZED SDK to get a variety of runtime information in the console.
When developing an application, enabling verbose (`sdkVerbose >= 1`) mode can help you understand the current ZED SDK behavior.
However, this might not be desirable in a shipped version.
Default: 0 (no verbose message)
### variable sdkGPUId
```csharp
int sdkGPUId;
```
NVIDIA graphics card id to use.
**Note**: A non-positive value will search for all CUDA capable devices and select the most powerful.
By default the SDK will use the most powerful NVIDIA graphics card found.
However, when running several applications, or using several cameras at the same time, splitting the load over available GPUs can be useful.
This parameter allows you to select the GPU used by the sl.Camera using an ID from 0 to n-1 GPUs in your PC.
Default: -1
### variable sdkVerboseLogFile
```csharp
string sdkVerboseLogFile = "";
```
File path to store the ZED SDK logs (if sdkVerbose is enabled).
**Note**:
* Setting this parameter to any value will redirect all standard output print calls of the entire program.
* This means that your own standard output print calls will be redirected to the log file.
* This parameter can be particularly useful for creating a log system, and with Unreal or Unity applications that don't provide a standard console output.
**Warning**:
* The log file won't be cleared after successive executions of the application.
* This means that it can grow indefinitely if not cleared.
The file will be created if it does not exist.
Default: ""
### variable depthStabilization
```csharp
int depthStabilization;
```
Defines whether the depth needs to be stabilized and to what extent.
**Note**:
* The stabilization uses the positional tracking to increase its accuracy, so the positional tracking module will be enabled automatically when set to a value different from 0.
* Note that calling sl.Camera.EnablePositionalTracking() with your own parameters afterwards is still possible.
Regions of generated depth map can oscillate from one frame to another.
These oscillations result from a lack of texture (too homogeneous) on an object and by image noise.
This parameter controls a stabilization filter that reduces these oscillations.
In the range [0-100]:
* 0 disable the depth stabilization (raw depth will be return)
* stabilization smoothness is linear from 1 to 100
Default: 1
### variable optionalSettingsPath
```csharp
string optionalSettingsPath = "";
```
Optional path where the ZED SDK has to search for the settings file (SNXXXX.conf file).
**Note**:
* The settings file will be searched in the default directory:
* **Linux**: _/usr/local/zed/settings/_
* **Windows**: _C:/ProgramData/stereolabs/settings_
* If a path is specified and no file has been found, the ZED SDK will search the settings file in the default directory.
* An automatic download of the settings file (through **ZED Explorer** or the installer) will still download the files on the default path.
This file contains the calibration information of the camera.
Default: ""
### variable sensorsRequired
```csharp
bool sensorsRequired;
```
Requires the successful opening of the motion sensors before opening the camera.
**Note**:
* If set to false, the ZED SDK will try to **open and use** the IMU (second USB device on USB2.0) and will open the camera successfully even if the sensors failed to open.
* This parameter only impacts the LIVE mode.
* If set to true, sl.Camera.Open() will fail if the sensors cannot be opened.
* This parameter should be used when the IMU data must be available, such as object detection module or when the gravity is needed.
* This setting is not taken into account for sl.MODEL.ZED camera since it does not include sensors.
Default: false.
This can be used for example when using a USB3.0 only extension cable (some fiber extension for example).
### variable ipStream
```csharp
string ipStream = "";
```
IP address of the streaming sender to connect to.
### variable portStream
```csharp
ushort portStream = 30000;
```
Port of the streaming sender to connect to.
### variable enableImageEnhancement
```csharp
bool enableImageEnhancement = true;
```
Enable the Enhanced Contrast Technology, to improve image quality.
**Note**: This only works for firmware version starting from 1523 and up.
Default: True.
If set to true, image enhancement will be activated in camera ISP. Otherwise, the image will not be enhanced by the IPS.
### variable optionalOpencvCalibrationFile
```csharp
string optionalOpencvCalibrationFile;
```
Optional path where the ZED SDK can find a file containing the calibration information of the camera computed by OpenCV.
**Note**:
* Using this will disable the factory calibration of the camera.
* The file must be in a XML/YAML/JSON formatting provided by OpenCV.
* It also must contain the following keys: Size, K_LEFT (intrinsic left), K_RIGHT (intrinsic right), D_LEFT (distortion left), D_RIGHT (distortion right), R (extrinsic rotation), T (extrinsic translation).
**Warning**: Erroneous calibration values can lead to poor accuracy in all ZED SDK modules.
### variable openTimeoutSec
```csharp
float openTimeoutSec;
```
Define a timeout in seconds after which an error is reported if the sl.Camera.Open() method fails.
**Note**: This parameter only impacts the LIVE mode.
Set to '-1' to try to open the camera endlessly without returning error in case of failure.
Set to '0' to return error in case of failure at the first attempt.
Default: 5.0
### variable asyncGrabCameraRecovery
```csharp
bool asyncGrabCameraRecovery;
```
Define the behavior of the automatic camera recovery during sl.Camera.Grab() method call.
When async is enabled and there's an issue with the communication with the sl.Camera object, sl.Camera.Grab() will exit after a short period and return the sl.ERROR_CODE.CAMERA_REBOOTING warning.
The recovery will run in the background until the correct communication is restored.
When asyncGrabCameraRecovery is false, the sl.Camera.Grab() method is blocking and will return only once the camera communication is restored or the timeout is reached.
Default: false
### variable grabComputeCappingFPS
```csharp
float grabComputeCappingFPS = 0;
```
Define a computation upper limit to the grab frequency.
**Note**:
* It has no effect when reading an SVO file.
* Internally the sl.Camera.grab() method always tries to get the latest available image while respecting the desired FPS as much as possible.
This can be useful to get a known constant fixed rate or limit the computation load while keeping a short exposure time by setting a high camera capture framerate.
The value should be inferior to the sl.InitParameters.camera_fps and strictly positive.
This is an upper limit and won't make a difference if the computation is slower than the desired compute capping FPS.
### variable enableImageValidityCheck
```csharp
bool enableImageValidityCheck;
```
Enable or disable the image validity verification. This will perform additional verification on the image to identify corrupted data.This verification is done in the grab function and requires some computations. If an issue is found, the grab function will output a warning as sl.ERROR_CODE.CORRUPTED_FRAME. This version doesn't detect frame tearing currently. default: enabled
### variable maximumWorkingResolution
```csharp
Resolution maximumWorkingResolution;
```
Set a maximum size for all SDK output, like retrieveImage and retrieveMeasure functions. This will override the default (0,0) and instead of outputting native image size sl::Mat, the ZED SDK will take this size as default. A custom lower size can also be used at runtime, but not bigger.This is used for internal optimization of compute and memory allocations The default is similar to previous version with(0,0), meaning native image size
**Note**: : if maximum_working_resolution field are lower than 64, it will be interpreted as dividing scale factor;
* maximum_working_resolution = sl::Resolution(1280, 2) -> 1280 x(image_height/2) = 1280 x(half height)
* maximum_working_resolution = sl::Resolution(4, 4) -> (image_width/4) x(image_height/4) = quarter size
---
# sl::RuntimeParameters
**Module:** **Depth Sensing Module**
Class containing parameters that defines the behavior of sl.Camera.Grab(). More...
## Detailed Description
```csharp
class sl::RuntimeParameters;
```
Class containing parameters that defines the behavior of sl.Camera.Grab().
**Note**: Parameters can be user-adjusted at runtime.
The default constructor sets all parameters to their default settings.
## Public Functions Documentation
### function RuntimeParameters
```csharp
RuntimeParameters(
REFERENCE_FRAME reframe =REFERENCE_FRAME.CAMERA,
bool depth =true,
int cnf_threshold =95,
int txt_cnf_threshold =100,
bool removeSaturatedAreas_ =true,
bool pEnableFillMode =false
)
```
Default constructor.
All the parameters are set to their default values.
## Public Attributes Documentation
### variable measure3DReferenceFrame
```csharp
sl.REFERENCE_FRAME measure3DReferenceFrame;
```
Reference frame in which to provides the 3D measures (point cloud, normals, etc.).
Default: sl.REFERENCE_FRAME.CAMERA
### variable enableDepth
```csharp
bool enableDepth;
```
Defines if the depth map should be computed.
**Note**: If set to false, only the images are available.
Default: true
### variable enableFillMode
```csharp
bool enableFillMode;
```
Defines if the depth map should be completed or not.
**Note**: It is similar to the removed sl.SENSING_MODE.FILL.
**Warning**: Enabling this will override the confidence values confidenceThreshold and textureConfidenceThreshold as well as removeSaturatedAreas.
Default: false
### variable confidenceThreshold
```csharp
int confidenceThreshold;
```
Threshold to reject depth values based on their confidence.
**Note**:
* Pixels with a value close to 100 are not to be trusted. Accurate depth pixels tends to be closer to lower values.
* It can be seen as a probability of error, scaled to 100.
Each depth pixel has a corresponding confidence sl.MEASURE.CONFIDENCE in the range [1, 100].
Decreasing this value will remove depth data from both objects edges and low textured areas, to keep only confident depth estimation data.
Default: 95
### variable textureConfidenceThreshold
```csharp
int textureConfidenceThreshold;
```
Threshold to reject depth values based on their texture confidence.
**Note**: Pixels with a value close to 100 are not to be trusted. Accurate depth pixels tends to be closer to lower values.
The texture confidence range is [1, 100].
Decreasing this value will remove depth data from image areas which are uniform.
Default: 100 (no depth pixel will be rejected)
### variable removeSaturatedAreas
```csharp
bool removeSaturatedAreas;
```
Defines if the saturated area (luminance>=255) must be removed from depth map estimation.
**Note**: It is recommended to keep this parameter at true because saturated area can create false detection.
Default: true
---
# sl::Mat
**Module:** **Core Module**
Class representing 1 to 4-channel matrix of float or uchar, stored on CPU and/or GPU side. More...
## Public Properties
| | Name |
| -------------- | -------------- |
| IntPtr | **MatPtr**
Returns the internal ptr of a Mat. |
## Detailed Description
```csharp
class sl::Mat;
```
Class representing 1 to 4-channel matrix of float or uchar, stored on CPU and/or GPU side.
**Note**: For more info, read about the ZED SDK C++ class it mirrors: [Mat](https://www.stereolabs.com/docs/api/classsl_1_1Mat.html)
This class is defined in a row-major order, meaning that for an image buffer, the rows are stored consecutively from top to bottom.
## Public Functions Documentation
### function Mat
```csharp
Mat()
```
Default constructor.
Creates an empty sl.Mat.
### function Mat
```csharp
Mat(
System.IntPtr ptr
)
```
Constructor.
**Parameters**:
* **ptr** Internal pointer to create the sl.Mat with.
Creates a sl.Mat from an existing internal pointer.
### function Mat
```csharp
Mat(
sl.Resolution resolution,
MAT_TYPE type,
MEM mem =MEM.CPU
)
```
Constructor.
**Parameters**:
* **resolution** Size of the matrix in pixels.
* **type** Type of the matrix. Depends on texture type (see sl.VIEW and sl.MEASURE).
* **mem** Where the buffer will be stored (CPU or GPU memory).
Choose depending on where you'll need to access it from.
Creates a sl.Mat with a given sl.Resolution.
### function Create
```csharp
void Create(
sl.Resolution resolution,
MAT_TYPE type,
MEM mem =MEM.CPU
)
```
Creates a sl.Mat with a given sl.Resolution.
**Parameters**:
* **resolution** Size of the matrix in pixels.
* **type** Type of the matrix. Depends on texture type (see sl.VIEW and sl.MEASURE).
* **mem** Where the buffer will be stored (CPU or GPU memory).
Choose depending on where you'll need to access it from.
### function Create
```csharp
void Create(
uint width,
uint height,
MAT_TYPE type,
MEM mem =MEM.CPU
)
```
Creates a Mat with a given width and height.
**Parameters**:
* **width** Width of the matrix in pixels.
* **height** Height of the matrix in pixels..
* **type** Type of the matrix. Depends on texture type (see sl.VIEW and sl.MEASURE).
* **mem** Where the buffer will be stored (CPU or GPU memory).
Choose depending on where you'll need to access it from.
### function IsInit
```csharp
bool IsInit()
```
Whether the sl.Mat has been initialized.
### function Free
```csharp
void Free(
MEM mem =MEM.BOTH
)
```
Frees the memory of the sl.Mat.
**Parameters**:
* **mem** Whether the sl.Mat is on CPU or GPU memory.
### function UpdateCPUFromGPU
```csharp
sl.ERROR_CODE UpdateCPUFromGPU()
```
Copies data from the GPU to the CPU, if possible.
**Return**: sl.ERROR_CODE.SUCCESS if everything went well, sl.ERROR_CODE.FAILURE otherwise.
### function UpdateGPUFromCPU
```csharp
sl.ERROR_CODE UpdateGPUFromCPU()
```
Copies data from the CPU to the GPU, if possible.
**Return**: sl.ERROR_CODE.SUCCESS if everything went well, sl.ERROR_CODE.FAILURE otherwise.
### function GetInfos
```csharp
string GetInfos()
```
Returns the information about the sl::Mat into a string.
**Return**: String containing the sl::Mat information.
### function CopyTo
```csharp
sl.ERROR_CODE CopyTo(
sl.Mat dest,
sl.COPY_TYPE copyType =COPY_TYPE.CPU_CPU
)
```
Copies data from this sl.Mat to another sl.Mat (deep copy).
**Parameters**:
* **dest** sl.Mat that the data will be copied to.
* **copyType** The to and from memory types.
**Return**: sl.ERROR_CODE indicating if the copy was successful, or why it wasn't.
### function Read
```csharp
sl.ERROR_CODE Read(
string filePath
)
```
Reads an image from a file.
**Parameters**:
* **filePath** Path of the file to read (including the name and extension).
**Return**: sl.ERROR_CODE indicating if the copy was successful, or why it wasn't.
**Note**: Only works if sl.Mat has access to sl.MEM.CPU.
Supports .png and .jpeg.
### function Write
```csharp
sl.ERROR_CODE Write(
string filePath,
int compressionLevel =-1
)
```
Writes the sl.Mat into a file as an image.
**Parameters**:
* **filePath** Path of the file to write in (including the name and extension).
* **compression_level** Compression level used. Highest value means highest compression (smaller size). Range [0 - 100].
**Return**: sl.ERROR_CODE indicating if the copy was successful, or why it wasn't.
**Note**: Only works if sl.Mat has access to sl.MEM.CPU.
### function GetWidth
```csharp
int GetWidth()
```
Returns the width of the matrix.
### function GetHeight
```csharp
int GetHeight()
```
Returns the height of the matrix.
**Return**:
### function GetChannels
```csharp
int GetChannels()
```
Returns the number of values stored in one pixel.
### function GetPixelBytes
```csharp
int GetPixelBytes()
```
Returns the size of one pixel in bytes.
### function GetStep
```csharp
int GetStep(
sl.MEM mem =sl.MEM.CPU
)
```
Returns the memory step in number of elements (size in one pixel row).
### function GetStepBytes
```csharp
int GetStepBytes(
sl.MEM mem =sl.MEM.CPU
)
```
Returns the memory step in bytes (size of one pixel row).
**Return**:
### function GetWidthBytes
```csharp
int GetWidthBytes()
```
Returns the size of a row in bytes.
**Return**:
### function GetMemoryType
```csharp
MEM GetMemoryType()
```
Returns the type of memory (CPU and/or GPU).
**Return**:
### function IsMemoryOwner
```csharp
bool IsMemoryOwner()
```
Returns whether the sl.Mat is the owner of the memory it accesses.
**Return**:
### function GetResolution
```csharp
sl.Resolution GetResolution()
```
Returns the resolution (width and height) of the matrix.
**Return**:
### function Alloc
```csharp
void Alloc(
uint width,
uint height,
MAT_TYPE matType,
MEM mem =MEM.CPU
)
```
Allocates the sl.Mat memory.
**Parameters**:
* **width** Width of the image/matrix in pixels.
* **height** Height of the image/matrix in pixels.
* **matType** Type of matrix (data type and channels - see sl.MAT_TYPE)
* **mem** Where the buffer will be stored - CPU memory or GPU memory.
### function Alloc
```csharp
void Alloc(
sl.Resolution resolution,
MAT_TYPE matType,
MEM mem =MEM.CPU
)
```
Allocates the sl.Mat memory.
**Parameters**:
* **resolution** Size of the image/matrix in pixels.
* **matType** Type of matrix (data type and channels - see sl.MAT_TYPE)
* **mem** Where the buffer will be stored - CPU memory or GPU memory.
### function SetFrom
```csharp
int SetFrom(
Mat src,
COPY_TYPE copyType =COPY_TYPE.CPU_CPU
)
```
Copies data from another sl.Mat into this one (deep copy).
**Parameters**:
* **src** sl.Mat where the data will be copied from.
* **copyType** Specifies the memory that will be used for the copy.
**Return**: sl.ERROR_CODE (as an int) indicating if the copy was successful, or why it wasn't.
### function GetPtr
```csharp
System.IntPtr GetPtr(
MEM mem =MEM.CPU
)
```
Returns the CPU or GPU data pointer.
**Parameters**:
* **mem** Specifies whether you want sl.MEM.CPU or sl.MEM.GPU.
### function Clone
```csharp
void Clone(
Mat source
)
```
Duplicates a sl.Mat by copying all its data into a new one (deep copy).
**Parameters**:
* **source** sl.Mat to clone.
### function GetDataType
```csharp
sl.MAT_TYPE GetDataType()
```
Returns the data type of this Mat (e.g. MAT_32F_C1, MAT_8U_C4, etc.).
### function GetValue
```csharp
sl.ERROR_CODE GetValue(
int x,
int y,
out float value,
sl.MEM mem =sl.MEM.CPU
)
```
Returns the value of a specific point in the matrix of type sl.MAT_TYPE.MAT_32F_C1.
**Parameters**:
* **x** Column of the point to get the value from.
* **y** Row of the point to get the value from.
* **value** Gets filled with the current value.
* **mem** Which memory should be read.
**Return**: sl.ERROR_CODE indicating if the get was successful, or why it wasn't.
### function GetValue
```csharp
sl.ERROR_CODE GetValue(
int x,
int y,
out float2 value,
sl.MEM mem =sl.MEM.CPU
)
```
Returns the value of a specific point in the matrix of type sl.MAT_TYPE.MAT_32F_C2.
**Parameters**:
* **x** Column of the point to get the value from.
* **y** Row of the point to get the value from.
* **value** Gets filled with the current value.
* **mem** Which memory should be read.
**Return**: sl.ERROR_CODE indicating if the get was successful, or why it wasn't.
### function GetValue
```csharp
sl.ERROR_CODE GetValue(
int x,
int y,
out float3 value,
sl.MEM mem =sl.MEM.CPU
)
```
Returns the value of a specific point in the matrix of type sl.MAT_TYPE.MAT_32F_C3.
**Parameters**:
* **x** Column of the point to get the value from.
* **y** Row of the point to get the value from.
* **value** Gets filled with the current value.
* **mem** Which memory should be read.
**Return**: sl.ERROR_CODE indicating if the get was successful, or why it wasn't.
### function GetValue
```csharp
sl.ERROR_CODE GetValue(
int x,
int y,
out float4 value,
sl.MEM mem =sl.MEM.CPU
)
```
Returns the value of a specific point in the matrix of type sl.MAT_TYPE.MAT_32F_C4.
**Parameters**:
* **x** Column of the point to get the value from.
* **y** Row of the point to get the value from.
* **value** Gets filled with the current value.
* **mem** Which memory should be read.
**Return**: sl.ERROR_CODE indicating if the get was successful, or why it wasn't.
### function GetValue
```csharp
sl.ERROR_CODE GetValue(
int x,
int y,
out byte value,
sl.MEM mem =sl.MEM.CPU
)
```
Returns the value of a specific point in the matrix of type sl.MAT_TYPE.MAT_8U_C1.
**Parameters**:
* **x** Column of the point to get the value from.
* **y** Row of the point to get the value from.
* **value** Gets filled with the current value.
* **mem** Which memory should be read.
**Return**: sl.ERROR_CODE indicating if the get was successful, or why it wasn't.
### function GetValue
```csharp
sl.ERROR_CODE GetValue(
int x,
int y,
out char2 value,
sl.MEM mem =sl.MEM.CPU
)
```
Returns the value of a specific point in the matrix of type sl.MAT_TYPE.MAT_8U_C2.
**Parameters**:
* **x** Column of the point to get the value from.
* **y** Row of the point to get the value from.
* **value** Gets filled with the current value.
* **mem** Which memory should be read.
**Return**: sl.ERROR_CODE indicating if the get was successful, or why it wasn't.
### function GetValue
```csharp
sl.ERROR_CODE GetValue(
int x,
int y,
out char3 value,
sl.MEM mem =sl.MEM.CPU
)
```
Returns the value of a specific point in the matrix of type sl.MAT_TYPE.MAT_8U_C3.
**Parameters**:
* **x** Column of the point to get the value from.
* **y** Row of the point to get the value from.
* **value** Gets filled with the current value.
* **mem** Which memory should be read.
**Return**: sl.ERROR_CODE indicating if the get was successful, or why it wasn't.
### function GetValue
```csharp
sl.ERROR_CODE GetValue(
int x,
int y,
out char4 value,
sl.MEM mem =sl.MEM.CPU
)
```
Returns the value of a specific point in the matrix of type sl.MAT_TYPE.MAT_8U_C4.
**Parameters**:
* **x** Column of the point to get the value from.
* **y** Row of the point to get the value from.
* **value** Gets filled with the current value.
* **mem** Which memory should be read.
**Return**: sl.ERROR_CODE indicating if the get was successful, or why it wasn't.
### function SetValue
```csharp
sl.ERROR_CODE SetValue(
int x,
int y,
ref float value,
sl.MEM mem =sl.MEM.CPU
)
```
Sets a value to a specific point in the matrix of type sl.MAT_TYPE.MAT_32F_C1.
**Parameters**:
* **x** Column of the point to set the value.
* **y** Row of the point to set the value.
* **value** Value to which the point will be set.
* **mem** Which memory will be updated.
**Return**: sl.ERROR_CODE indicating if the get was successful, or why it wasn't.
### function SetValue
```csharp
sl.ERROR_CODE SetValue(
int x,
int y,
ref float2 value,
sl.MEM mem =sl.MEM.CPU
)
```
Sets a value to a specific point in the matrix of type sl.MAT_TYPE.MAT_32F_C2.
**Parameters**:
* **x** Column of the point to set the value.
* **y** Row of the point to set the value.
* **value** Value to which the point will be set.
* **mem** Which memory will be updated.
**Return**: sl.ERROR_CODE indicating if the get was successful, or why it wasn't.
### function SetValue
```csharp
sl.ERROR_CODE SetValue(
int x,
int y,
ref float3 value,
sl.MEM mem =sl.MEM.CPU
)
```
Sets a value to a specific point in the matrix of type sl.MAT_TYPE.MAT_32F_C3.
**Parameters**:
* **x** Column of the point to set the value.
* **y** Row of the point to set the value.
* **value** Value to which the point will be set.
* **mem** Which memory will be updated.
**Return**: sl.ERROR_CODE indicating if the get was successful, or why it wasn't.
### function SetValue
```csharp
sl.ERROR_CODE SetValue(
int x,
int y,
float4 value,
sl.MEM mem =sl.MEM.CPU
)
```
Sets a value to a specific point in the matrix of type sl.MAT_TYPE.MAT_32F_C4.
**Parameters**:
* **x** Column of the point to set the value.
* **y** Row of the point to set the value.
* **value** Value to which the point will be set.
* **mem** Which memory will be updated.
**Return**: sl.ERROR_CODE indicating if the get was successful, or why it wasn't.
### function SetValue
```csharp
sl.ERROR_CODE SetValue(
int x,
int y,
ref byte value,
sl.MEM mem =sl.MEM.CPU
)
```
Sets a value to a specific point in the matrix of type sl.MAT_TYPE.MAT_8U_C1.
**Parameters**:
* **x** Column of the point to set the value.
* **y** Row of the point to set the value.
* **value** Value to which the point will be set.
* **mem** Which memory will be updated.
**Return**: sl.ERROR_CODE indicating if the get was successful, or why it wasn't.
### function SetValue
```csharp
sl.ERROR_CODE SetValue(
int x,
int y,
ref char2 value,
sl.MEM mem =sl.MEM.CPU
)
```
Sets a value to a specific point in the matrix of type sl.MAT_TYPE.MAT_8U_C2.
**Parameters**:
* **x** Column of the point to set the value.
* **y** Row of the point to set the value.
* **value** Value to which the point will be set.
* **mem** Which memory will be updated.
**Return**: sl.ERROR_CODE indicating if the get was successful, or why it wasn't.
### function SetValue
```csharp
sl.ERROR_CODE SetValue(
int x,
int y,
ref char3 value,
sl.MEM mem =sl.MEM.CPU
)
```
Sets a value to a specific point in the matrix of type sl.MAT_TYPE.MAT_8U_C3.
**Parameters**:
* **x** Column of the point to set the value.
* **y** Row of the point to set the value.
* **value** Value to which the point will be set.
* **mem** Which memory will be updated.
**Return**: sl.ERROR_CODE indicating if the get was successful, or why it wasn't.
### function SetValue
```csharp
sl.ERROR_CODE SetValue(
int x,
int y,
ref char4 value,
sl.MEM mem =sl.MEM.CPU
)
```
Sets a value to a specific point in the matrix of type sl.MAT_TYPE.MAT_8U_C4.
**Parameters**:
* **x** Column of the point to set the value.
* **y** Row of the point to set the value.
* **value** Value to which the point will be set.
* **mem** Which memory will be updated.
**Return**: sl.ERROR_CODE indicating if the get was successful, or why it wasn't.
### function SetTo
```csharp
sl.ERROR_CODE SetTo(
ref float value,
sl.MEM mem
)
```
Fills the entire sl.Mat of type sl.MAT_TYPE.MAT_32F_C1 with the given value.
**Parameters**:
* **value** Value to be copied all over the matrix.
* **mem** Which buffer to fill, CPU and/or GPU.
**Return**: sl.ERROR_CODE indicating if the get was successful, or why it wasn't.
### function SetTo
```csharp
sl.ERROR_CODE SetTo(
ref float2 value,
sl.MEM mem
)
```
Fills the entire sl.Mat of type sl.MAT_TYPE.MAT_32F_C2 with the given value.
**Parameters**:
* **value** Value to be copied all over the matrix.
* **mem** Which buffer to fill, CPU and/or GPU.
**Return**: sl.ERROR_CODE indicating if the get was successful, or why it wasn't.
### function SetTo
```csharp
sl.ERROR_CODE SetTo(
ref float3 value,
sl.MEM mem
)
```
Fills the entire sl.Mat of type sl.MAT_TYPE.MAT_32F_C3 with the given value.
**Parameters**:
* **value** Value to be copied all over the matrix.
* **mem** Which buffer to fill, CPU and/or GPU.
**Return**: sl.ERROR_CODE indicating if the get was successful, or why it wasn't.
### function SetTo
```csharp
sl.ERROR_CODE SetTo(
ref float4 value,
sl.MEM mem
)
```
Fills the entire sl.Mat of type sl.MAT_TYPE.MAT_32F_C4 with the given value.
**Parameters**:
* **value** Value to be copied all over the matrix.
* **mem** Which buffer to fill, CPU and/or GPU.
**Return**: sl.ERROR_CODE indicating if the get was successful, or why it wasn't.
### function SetTo
```csharp
sl.ERROR_CODE SetTo(
ref byte value,
sl.MEM mem
)
```
Fills the entire sl.Mat of type sl.MAT_TYPE.MAT_8U_C1 with the given value.
**Parameters**:
* **value** Value to be copied all over the matrix.
* **mem** Which buffer to fill, CPU and/or GPU.
**Return**: sl.ERROR_CODE indicating if the get was successful, or why it wasn't.
### function SetTo
```csharp
sl.ERROR_CODE SetTo(
ref char2 value,
sl.MEM mem
)
```
Fills the entire sl.Mat of type sl.MAT_TYPE.MAT_8U_C2 with the given value.
**Parameters**:
* **value** Value to be copied all over the matrix.
* **mem** Which buffer to fill, CPU and/or GPU.
**Return**: sl.ERROR_CODE indicating if the get was successful, or why it wasn't.
### function SetTo
```csharp
sl.ERROR_CODE SetTo(
ref char3 value,
sl.MEM mem
)
```
Fills the entire sl.Mat of type sl.MAT_TYPE.MAT_8U_C3 with the given value.
**Parameters**:
* **value** Value to be copied all over the matrix.
* **mem** Which buffer to fill, CPU and/or GPU.
**Return**: sl.ERROR_CODE indicating if the get was successful, or why it wasn't.
### function SetTo
```csharp
sl.ERROR_CODE SetTo(
ref char4 value,
sl.MEM mem
)
```
Fills the entire sl.Mat of type sl.MAT_TYPE.MAT_8U_C4 with the given value.
**Parameters**:
* **value** Value to be copied all over the matrix.
* **mem** Which buffer to fill, CPU and/or GPU.
**Return**: sl.ERROR_CODE indicating if the get was successful, or why it wasn't.
### function ConvertColor
```csharp
sl.ERROR_CODE ConvertColor(
sl.MEM mem =sl.MEM.CPU,
bool swapRBChannels =false
)
```
Convert the color channels of the Mat (RGB to BGR or RGBA to BGRA). This methods works only on 8U_C4 or 8U_C3.
**Parameters**:
* **mem** Which buffer to fill, CPU and/or GPU.
* **swapRBChannels** Swap blue and red channels.
**Return**: sl.ERROR_CODE indicating if the get was successful, or why it wasn't.
### function Swap
```csharp
static void Swap(
Mat a,
Mat b
)
```
Swaps the content of two Mat objects (no data copy, only internal pointers are exchanged).
### function ConvertColor
```csharp
static sl.ERROR_CODE ConvertColor(
sl.Mat src,
sl.Mat dst,
bool swapRBChannels =false,
bool removeAlphaChannel =false,
sl.MEM mem =sl.MEM.CPU
)
```
Convert the color channels of the Mat into another Mat This methods works only on 8U_C4 if removeAlphaChannel is enabled, or 8U_C4 and 8U_C3 if swapRBChannels is enabled
**Parameters**:
* **src** Source image.
* **dst** Destination image.
* **swapRBChannels** Swap blue and red channels.
* **removeAlphaChannel** Remove alpha channel.
* **mem** Which buffer to fill, CPU and/or GPU.
**Return**: sl.ERROR_CODE indicating if the get was successful, or why it wasn't.
### function BlobFromImage
```csharp
static sl.ERROR_CODE BlobFromImage(
sl.Mat image_in,
sl.Mat tensor_out,
sl.Resolution resolution,
float scaleFactor,
float3 mean,
float3 stdDev,
bool keepAspectRatio,
bool swapRBChannels
)
```
Convert an image into a GPU Tensor in planar channel configuration (NCHW), ready to use for deep learning model
**Parameters**:
* **image_in** input image to convert
* **tensor_out** output GPU tensor
* **resolution** resolution of the output image, generally square, although not mandatory
* **scaleFactor** Scale factor applied to each pixel value, typically to convert the char value into [0-1] float
* **mean** mean, statistic to normalized the pixel values, applied AFTER the scale. For instance for imagenet statistics the mean would be sl::float3(0.485, 0.456, 0.406)
* **stdDev** standard deviation, statistic to normalized the pixel values, applied AFTER the scale. For instance for imagenet statistics the standard deviation would be sl::float3(0.229, 0.224, 0.225)
* **keepAspectRatio** indicates if the original width and height ratio should be kept using padding (sometimes refer to as letterboxing) or if the image should be stretched
* **swapRBChannels** indicates if the Red and Blue channels should be swapped (RGB-BGR or RGBA-BGRA)
**Return**: sl.ERROR_CODE indicating if the get was successful, or why it wasn't.
### function BlobFromImages
```csharp
static sl.ERROR_CODE BlobFromImages(
sl.Mat[] images_in,
sl.Mat tensor_out,
sl.Resolution resolution,
float scaleFactor,
float3 mean,
float3 stdDev,
bool keepAspectRatio,
bool swapRBChannels
)
```
Convert an image array into a GPU Tensor in planar channel configuration (NCHW), ready to use for deep learning model
**Parameters**:
* **image_in** input images to convert
* **tensor_out** output GPU tensor
* **resolution** resolution of the output image, generally square, although not mandatory
* **scaleFactor** Scale factor applied to each pixel value, typically to convert the char value into [0-1] float
* **mean** mean, statistic to normalized the pixel values, applied AFTER the scale. For instance for imagenet statistics the mean would be sl::float3(0.485, 0.456, 0.406)
* **stdDev** standard deviation, statistic to normalized the pixel values, applied AFTER the scale. For instance for imagenet statistics the standard deviation would be sl::float3(0.229, 0.224, 0.225)
* **keepAspectRatio** indicates if the original width and height ratio should be kept using padding (sometimes refer to as letterboxing) or if the image should be stretched
* **swapRBChannels** indicates if the Red and Blue channels should be swapped (RGB-BGR or RGBA-BGRA)
**Return**: sl.ERROR_CODE indicating if the get was successful, or why it wasn't.
## Public Property Documentation
### property MatPtr
```csharp
IntPtr MatPtr;
```
Returns the internal ptr of a Mat.
---
# sl
## Classes
| | Name |
| -------------- | -------------- |
| class | **sl::Camera**
This class serves as the primary interface between the camera and the various features provided by the SDK. |
| class | **sl::ZEDCommon** |
| struct | **sl::Matrix3x3**
Structure representing a generic 3*3 matrix. |
| struct | **sl::Resolution**
Structure containing the width and height of an image. |
| struct | **sl::Rect**
Structure defining a 2D rectangle with top-left corner coordinates and width/height in pixels. |
| struct | **sl::CameraConfiguration**
Structure containing information about the camera sensor. |
| struct | **sl::CameraInformation**
Structure containing information of a single camera (serial number, model, input type, etc.) |
| class | **sl::PositionalTrackingParameters**
Class containing a set of parameters for the positional tracking module initialization. |
| struct | **sl::Pose**
Structure containing positional tracking data giving the position and orientation of the camera in 3D space. |
| struct | **sl::RegionOfInterestParameters**
Structure containing a set of parameters for the region of interest. |
| struct | **sl::PositionalTrackingStatus**
Lists the different status of positional tracking. |
| struct | **sl::ImuData**
Structure containing data from the IMU sensor. |
| struct | **sl::BarometerData**
Structure containing data from the barometer sensor. |
| struct | **sl::MagnetometerData**
Structure containing data from the magnetometer sensor. |
| struct | **sl::TemperatureSensorData**
Structure containing data from the temperature sensors. |
| struct | **sl::SensorsData**
Structure containing all sensors data (except image sensors) to be used for positional tracking or environment study. |
| struct | **sl::SensorParameters**
Structure containing information about a single sensor available in the current device. |
| struct | **sl::SensorsConfiguration**
Structure containing information about all the sensors available in the current device. |
| class | **sl::RuntimeParameters**
Class containing parameters that defines the behavior of sl.Camera.Grab(). |
| struct | **sl::CameraParameters**
Structure containing the intrinsic parameters of a camera. |
| struct | **sl::CalibrationParameters**
Structure containing intrinsic and extrinsic parameters of the camera (translation and rotation). |
| struct | **sl::SVOData**
Structure containing data that can be stored in and retrieved from SVOs. That information will be ingested with sl.Camera.ingestDataIntoSVO and retrieved with sl.Camera.retrieveSVOData. |
| struct | **sl::VoxelMeasureParameters**
Parameters controlling voxel decimation in Camera.RetrieveVoxelMeasure. |
| class | **sl::InitParameters**
Class containing the options used to initialize the sl.Camera object. |
| struct | **sl::RecordingParameters**
Structure containing the options used to record. |
| struct | **sl::StreamingParameters**
Structure containing the options used to stream with the ZED SDK. |
| struct | **sl::DeviceProperties**
Structure containing information about the properties of a camera. |
| struct | **sl::StreamingProperties**
Structure containing information about the properties of a streaming device. |
| struct | **sl::HealthStatus**
Structure containing the self-diagnostic results of the camera (image, depth, sensor health). Retrieved via Camera.GetHealthStatus. |
| struct | **sl::RecordingStatus**
Structure containing information about the status of the recording. |
| struct | **sl::InputType**
Structure defining the input type used in the ZED SDK. |
| class | **sl::PlaneDetectionParameters**
Class containing a set of parameters for the plane detection functionality. |
| class | **sl::SpatialMappingParameters**
Class containing a set of parameters for the spatial mapping module. |
| class | **sl::Mesh**
Class representing a mesh and containing the geometric (and optionally texture) data of the scene captured by the spatial mapping module. |
| class | **sl::FusedPointCloud**
A fused point cloud contains both geometric and color data of the scene captured by spatial mapping. |
| struct | **sl::Chunk**
Class representing a sub-mesh containing local vertices and triangles. |
| struct | **sl::PlaneData**
Structure representing a plane defined by a point and a normal, or a plane equation. |
| struct | **sl::BatchParameters**
Structure containing a set of parameters for batch object detection. |
| struct | **sl::AI_Model_status**
Structure containing AI model status. |
| struct | **sl::ObjectDetectionParameters**
Structure containing a set of parameters for the object detection module. |
| struct | **sl::ObjectTrackingParameters**
Structure containing a set of parameters for the object tracking module. |
| struct | **sl::ObjectDetectionRuntimeParameters**
Structure containing a set of runtime parameters for the object detection module. |
| struct | **sl::CustomObjectDetectionProperties**
Structure containing a set of runtime properties of a certain class ID for the object detection module using a custom model. |
| struct | **sl::CustomObjectDetectionRuntimeParameters** |
| struct | **sl::BodyTrackingParameters**
Structure containing a set of parameters for the body tracking module. |
| struct | **sl::BodyTrackingRuntimeParameters**
Structure containing a set of runtime parameters for the body tracking module. |
| struct | **sl::ObjectData**
Structure containing data of a detected object such as its boundingBox, label, id and its 3D position. |
| struct | **sl::CustomBoxObjectData**
Structure that store externally detected objects. |
| struct | **sl::CustomMaskObjectData**
Structure that store external 2D mask. |
| struct | **sl::Objects**
Structure containing the results of the object detection module. It contains the number of object in the scene (numObject) and the objectData structure for each object. |
| struct | **sl::CovarMatrix**
Full covariance matrix for position (3x3). Only 6 values are necessary [p0, p1, p2] [p1, p3, p4] [p2, p4, p5] |
| struct | **sl::BodyData**
Structure containing data of a detected body/person such as its headBoundingBox, id and its 3D position. |
| struct | **sl::Bodies**
Structure containing the results of the body tracking module. |
| class | **sl::ObjectsBatch**
Class containing batched data of a detected objects from the object detection module. |
| struct | **sl::SynchronizationParameter**
Configuration parameters for data synchronization. |
| struct | **sl::InitFusionParameters**
Holds the options used to initialize the Fusion object. |
| struct | **sl::CommunicationParameters**
Holds the communication parameter to configure the connection between senders and receiver |
| struct | **sl::FusionConfiguration**
Stores the Fusion configuration, can be read from /write to a Json file. |
| struct | **sl::BodyTrackingFusionParameters**
Holds the options used to initialize the body tracking module of the Fusion. |
| struct | **sl::BodyTrackingFusionRuntimeParameters**
Holds the options used to change the behavior of the body tracking module at runtime. |
| struct | **sl::CameraIdentifier**
Used to identify a specific camera in the Fusion API |
| struct | **sl::CameraMetrics**
Holds the metrics of a sender in the fusion process. |
| struct | **sl::FusionMetrics**
Holds the metrics of the fusion process. |
| struct | **sl::FusedPositionalTrackingStatus**
Class containing the overall position fusion status |
| struct | **sl::Landmark**
Represents a 3d landmark. |
| struct | **sl::Landmark2D**
Represents a 2d landmark. |
| struct | **sl::GNSSData**
Structure containing GNSS data to be used for positional tracking as prior. |
| struct | **sl::GeoPose**
Holds Geo reference position. |
| struct | **sl::ECEF**
Represents a world position in ECEF format. |
| struct | **sl::ENU**
Represents a world position in ENU format. |
| struct | **sl::LatLng**
Represents a world position in LatLng format. |
| struct | **sl::UTM**
Represents a world position in UTM format. |
| class | **sl::GNSSCalibrationParameters**
Holds the options used for calibrating GNSS / VIO. |
| class | **sl::PositionalTrackingFusionParameters**
Holds the options used for initializing the positional tracking fusion module. |
| class | **sl::Fusion**
Holds Fusion process data and functions |
| struct | **sl::char2**
Represents a 2D vector of uchars for use on both the CPU and GPU. |
| struct | **sl::char3**
Represents a 3D vector of uchars for use on both the CPU and GPU. |
| struct | **sl::char4**
Represents a 4D vector of uchars for use on both the CPU and GPU. |
| struct | **sl::float2**
Represents a 2D vector of floats for use on both the CPU and GPU. |
| struct | **sl::float3**
Represents a 3D vector of floats for use on both the CPU and GPU. |
| struct | **sl::float4**
Represents a 4D vector of floats for use on both the CPU and GPU. |
| class | **sl::Mat**
Class representing 1 to 4-channel matrix of float or uchar, stored on CPU and/or GPU side. |
## Types Documentation
### enum Constant
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| MAX_OBJECTS | 75| |
| MAX_SUBMESH | 1000| Maximum number of chunks. It's best to get relatively few chunks and to update them quickly. |
| MAX_BATCH_SIZE | 200| Max size of trajectory data (number of frames stored) |
| MAX_CAMERA_PLUGIN | 20| Maximum number of cameras that can be instantiated at the same time. Used to initialize arrays of cameras (ex: GetDeviceList()). |
| MAX_FUSED_CAMERAS | 20| Maximum number of camera that can be fused by the Fusion API. |
Constant for plugin. Should not be changed
### enum POSITION_TYPE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| RAW | 0| The output position will be the raw position data. |
| FUSION | | The output position will be the fused position projected into the requested camera repository. |
Lists the types of possible position outputs.
### enum ERROR_CODE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| SENSOR_CONFIGURATION_CHANGED | -6| The sensor's configuration (mode, multicast, etc.) was changed externally while streaming. If auto_recovery_on_config_change is enabled, the SDK will automatically reconnect. This warning code is returned once after successful recovery. |
| POTENTIAL_CALIBRATION_ISSUE | -5| The camera has a potential calibration issue. |
| CONFIGURATION_FALLBACK | -4| The operation could not proceed with the target configuration but did success with a fallback. |
| SENSORS_DATA_REQUIRED | -3| The input data does not contains the high frequency sensors data, this is usually because it requires newer SVO/Streaming. In order to work this modules needs inertial data present in it input. |
| CORRUPTED_FRAME | -2| The image is corrupted with invalid colors (green/purple images). This indicates a serious hardware or driver issue. |
| CAMERA_REBOOTING | -1| The camera is currently rebooting. |
| SUCCESS | | Standard code for successful behavior. |
| FAILURE | | Standard code for unsuccessful behavior. |
| NO_GPU_COMPATIBLE | | No GPU found or CUDA capability of the device is not supported. |
| NOT_ENOUGH_GPUMEM | | Not enough GPU memory for this depth mode. Try a different mode (such as PERFORMANCE), or increase the minimum depth value (see InitParameters.depthMinimumDistance). |
| CAMERA_NOT_DETECTED | | No camera was detected. |
| SENSORS_NOT_INITIALIZED | | The MCU that controls the sensors module has an invalid serial number. You can try to recover it by launching the **ZED Diagnostic** tool from the command line with the option `-r`. |
| SENSOR_NOT_DETECTED | | A camera with sensor is detected but the sensors (IMU, barometer, ...) cannot be opened. Only the MODEL.ZED does not has sensors. Unplug/replug is required. |
| INVALID_RESOLUTION | | In case of invalid resolution parameter, such as an upsize beyond the original image size in Camera.RetrieveImage. |
| LOW_USB_BANDWIDTH | | Insufficient bandwidth for the correct use of the camera. This issue can occur when you use multiple cameras or a USB 2.0 port. |
| CALIBRATION_FILE_NOT_AVAILABLE | | The calibration file of the camera is not found on the host machine. Use **ZED Explorer** or **ZED Calibration** to download the factory calibration file. |
| INVALID_CALIBRATION_FILE | | The calibration file is not valid. Try to download the factory calibration file or recalibrate your camera using **ZED Calibration**. |
| INVALID_SVO_FILE | | The provided SVO file is not valid. |
| SVO_RECORDING_ERROR | | An error occurred while trying to record an SVO (not enough free storage, invalid file, ...). |
| SVO_UNSUPPORTED_COMPRESSION | | An SVO related error, occurs when NVIDIA based compression cannot be loaded. |
| END_OF_SVO_FILE_REACHED | | SVO end of file has been reached. No frame will be available until the SVO position is reset. |
| INVALID_COORDINATE_SYSTEM | | The requested coordinate system is not available. |
| INVALID_FIRMWARE | | The firmware of the camera is out of date. Update to the latest version. |
| INVALID_FUNCTION_PARAMETERS | | Invalid parameters have been given for the function. |
| CUDA_ERROR | | A CUDA error has been detected in the process, in Camera.Grab() or Camera.RetrieveXXX() only. Activate wrapperVerbose in ZEDManager.cs for more info. |
| CAMERA_NOT_INITIALIZED | | The ZED SDK is not initialized. Probably a missing call to Camera.Open(). |
| NVIDIA_DRIVER_OUT_OF_DATE | | Your NVIDIA driver is too old and not compatible with your current CUDA version. |
| INVALID_FUNCTION_CALL | | The call of the function is not valid in the current context. Could be a missing call of Camera.Open(). |
| CORRUPTED_SDK_INSTALLATION | | The ZED SDK was not able to load its dependencies or some assets are missing. Reinstall the ZED SDK or check for missing dependencies (cuDNN, TensorRT). |
| INCOMPATIBLE_SDK_VERSION | | The installed ZED SDK is incompatible with the one used to compile the program. |
| INVALID_AREA_FILE | | The given area file does not exist. Check the path. |
| INCOMPATIBLE_AREA_FILE | | The area file does not contain enough data to be used or the DEPTH_MODE used during the creation of the area file is different from the one currently set. |
| CAMERA_FAILED_TO_SETUP | | Failed to open the camera at the proper resolution. Try another resolution or make sure that the UVC driver is properly installed. |
| CAMERA_DETECTION_ISSUE | | Your camera can not be opened. Try replugging it to another port or flipping the USB-C connector (if there is one). |
| CAMERA_ALREADY_IN_USE | | Cannot start the camera stream. Make sure your camera is not already used by another process or blocked by firewall or antivirus. |
| NO_GPU_DETECTED | | No GPU found. CUDA is unable to list it. Can be a driver/reboot issue. |
| PLANE_NOT_FOUND | | Plane not found. Either no plane is detected in the scene, at the location or corresponding to the floor, or the floor plane doesn't match the prior given. |
| MODULE_NOT_COMPATIBLE_WITH_CAMERA | | The module you try to use is not compatible with your camera MODEL. |
| MOTION_SENSORS_REQUIRED | | The module needs the sensors to be enabled (see InitParameters.sensorsRequired). |
| MODULE_NOT_COMPATIBLE_WITH_CUDA_VERSION | | The module needs a newer version of CUDA. |
| DRIVER_FAILURE | | The drivers initialization has failed. When using gmsl cameras, try restarting with sudo systemctl restart zed_x_daemon.service |
| CAMERA_EXCEEDS_BANDWIDTH | 35| The camera configuration exceeds available PHY CSI bandwidth (GMSL). Reduce resolution or FPS, or adjust hardware configuration. |
List of error codes in the ZED SDK.
**Note**: For more info, read about the ZED SDK C++ enum it mirrors: [ERROR_CODE](https://www.stereolabs.com/docs/api/group__Core__group.html#ga4db9ee29f2ff83c71567c12f6bfbf28c)
### enum COORDINATE_SYSTEM
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| IMAGE | | Standard coordinates system in computer vision. Used in OpenCV: see [here](http://docs.opencv.org/2.4/modules/calib3d/doc/camera_calibration_and_3d_reconstruction.html). |
| LEFT_HANDED_Y_UP | | Left-handed with Y up and Z forward. Used in Unity3D with DirectX |
| RIGHT_HANDED_Y_UP | | Right-handed with Y pointing up and Z backward. Used in OpenGL. |
| RIGHT_HANDED_Z_UP | | Right-handed with Z pointing up and Y forward. Used in 3DSMax. |
| LEFT_HANDED_Z_UP | | Left-handed with Z axis pointing up and X forward Used in Unreal Engine. |
| RIGHT_HANDED_Z_UP_X_FWD | | Right-handed with Z pointing up and X forward. Used in ROS (REP 103) |
Lists available coordinates systems for positional tracking and 3D measures.
!CoordinateSystem.webp
### enum MODULE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| ALL | 0| All modules |
| DEPTH | 1| Depth module |
| POSITIONAL_TRACKING | 2| Positional tracking module |
| OBJECT_DETECTION | 3| Object Detection module |
| BODY_TRACKING | 4| Body Tracking module |
| SPATIAL_MAPPING | 5| Spatial mapping module |
| LAST | 6| |
Lists available modules.
### enum POSITIONAL_TRACKING_STATE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| SEARCHING | | \warn DEPRECATED: This state is no longer in use. |
| OK | | The positional tracking is working normally. |
| OFF | | The positional tracking is not enabled. |
| FPS_TOO_LOW | | The effective FPS is too low to give proper results for motion tracking. Consider using performance parameters (sl.DEPTH_MODE.PERFORMANCE, low camera resolution (sl.RESOLUTION.VGA / sl.RESOLUTION.HDSVGA or sl.RESOLUTION.HD720). |
| SEARCHING_FLOOR_PLANE | | The camera is searching for the floor plane to locate itself with respect to it. The sl.REFERENCE_FRAME.WORLD will be set afterward. |
| UNAVAILABLE | | The tracking module was unable to perform tracking from the previous frame to the current frame. |
Lists the different states of positional tracking.
### enum ODOMETRY_STATUS
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| OK | | The positional tracking module successfully tracked from the previous frame to the current frame. |
| UNAVAILABLE | | The positional tracking module failed to track from the previous frame to the current frame. |
Report the status of current odom tracking.
### enum SPATIAL_MEMORY_STATUS
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| OK | | |
| LOOP_CLOSED | | Found a loop closure, relocalized within the area map or corrected after a sudden localization loss. |
| SEARCHING | | |
| OFF | | Spatial memory is disabled. |
| INITIALIZING | 4| Camera has not yet acquired enough memory or found its first loop closure. Keep moving the camera. |
| KNOWN_MAP | 5| Camera is localized within the loaded area map. |
| MAP_UPDATE | 6| Camera is mapping or getting out of area map bounds. |
| LOST | 7| Localization cannot operate anymore (camera obstructed or sudden jumps). |
| NOT_ENOUGH_MEMORY_FOR_TRACKING | 8| Not enough memory to continue tracking. |
Report the status of current map tracking.
### enum POSITIONAL_TRACKING_FUSION_STATUS
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| VISUAL_INERTIAL | 0| |
| VISUAL | 1| |
| INERTIAL | 2| |
| GNSS | 3| |
| VISUAL_INERTIAL_GNSS | 4| |
| VISUAL_GNSS | 5| |
| INERTIAL_GNSS | 6| |
| UNAVAILABLE | 7| |
Report the status of the positional tracking fusion.
### enum POSITIONAL_TRACKING_MODE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| GEN_1 | | Default mode. Fast and stable mode, requires depth computation. Less accurate than GEN_3. |
| GEN_2 | | /Deprecated mode. Use GEN_3 instead. |
| GEN_3 | | Fast and accurate, in both exploratory mode and mapped environments.\Note Can be used even if depth_mode is set to DEPTH_MODE.NONE. |
Lists the mode of positional tracking that can be used.
### enum REFERENCE_FRAME
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| WORLD | | The transform of sl.Pose will contain the motion with reference to the world frame (previously called sl.PATH). |
| CAMERA | | The transform of sl.Pose will contain the motion with reference to the previous camera frame (previously called sl.POSE). |
Lists possible types of position matrix used to store camera path and pose.
### enum HEADING_STATE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| GOOD | | The heading is reliable and not affected by iron interferences. |
| OK | | The heading is reliable, but affected by slight iron interferences. |
| NOT_GOOD | | The heading is not reliable because affected by strong iron interferences. |
| NOT_CALIBRATED | | The magnetometer has not been calibrated. |
| MAG_NOT_AVAILABLE | | The magnetometer sensor is not available. |
Lists the different states of the magnetic heading.
### enum SENSOR_TYPE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| ACCELEROMETER | | Three-axis accelerometer sensor to measure the inertial accelerations. |
| GYROSCOPE | | Three-axis gyroscope sensor to measure the angular velocities. |
| MAGNETOMETER | | Three-axis magnetometer sensor to measure the orientation of the device with respect to the Earth's magnetic field. |
| BAROMETER | | Barometer sensor to measure the atmospheric pressure. |
Lists available sensor types.
**Note**: Sensors are not available on sl.MODEL.ZED.
### enum SENSORS_UNIT
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| M_SEC_2 | | m/s² (acceleration) |
| DEG_SEC | | deg/s (angular velocity) |
| U_T | | μT (magnetic field) |
| HPA | | hPa (atmospheric pressure) |
| CELSIUS | | °C (temperature) |
| HERTZ | | Hz (frequency) |
Lists available measurement units of onboard sensors.
**Note**: Sensors are not available on sl.MODEL.ZED.
### enum DEPTH_MODE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| NONE | | No depth map computation. Only rectified stereo images will be available. |
| PERFORMANCE | | Computation mode optimized for speed. |
| QUALITY | | Computation mode designed for challenging areas with untextured surfaces. |
| ULTRA | | Computation mode that favors edges and sharpness. Requires more GPU memory and computation power. |
| NEURAL_LIGHT | | End to End Neural disparity estimation. Requires AI module. |
| NEURAL | | End to End Neural disparity estimation. Requires AI module. |
| NEURAL_PLUS | | More accurate Neural disparity estimation. Requires AI module. |
Lists available depth computation modes.
**Note**: For more info, read about the ZED SDK C++ enum it mirrors: [DEPTH_MODE](https://www.stereolabs.com/docs/api/group__Depth__group.html#ga8d542017c9b012a19a15d46be9b7fa43)
### enum MEASURE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| DISPARITY | | Disparity map. Each pixel contains 1 float. Type: sl.MAT_TYPE.MAT_32F_C1 |
| DEPTH | | Depth map in sl.UNIT defined in sl.InitParameters.coordinateUnits. Each pixel contains 1 float. Type: sl.MAT_TYPE.MAT_32F_C1 |
| CONFIDENCE | | Certainty/confidence of the depth map. Each pixel contains 1 float. Type: sl.MAT_TYPE.MAT_32F_C1 |
| XYZ | | Point cloud. Each pixel contains 4 float (X, Y, Z, not used). Type: sl.MAT_TYPE.MAT_32F_C4 |
| XYZRGBA | | Colored point cloud. Each pixel contains 4 float (X, Y, Z, color). The color should to be read as an unsigned char[4] representing the RGBA color. Type: sl.MAT_TYPE.MAT_32F_C4 |
| XYZBGRA | | Colored point cloud. Each pixel contains 4 float (X, Y, Z, color). The color should to be read as an unsigned char[4] representing the BGRA color. Type: sl.MAT_TYPE.MAT_32F_C4 |
| XYZARGB | | Colored point cloud. Each pixel contains 4 float (X, Y, Z, color). The color should to be read as an unsigned char[4] representing the ARGB color. Type: sl.MAT_TYPE.MAT_32F_C4 |
| XYZABGR | | Colored point cloud. Each pixel contains 4 float (X, Y, Z, color). The color should to be read as an unsigned char[4] representing the ABGR color. Type: sl.MAT_TYPE.MAT_32F_C4 |
| NORMALS | | Normal vectors map. Each pixel contains 4 float (X, Y, Z, 0). Type: sl.MAT_TYPE.MAT_32F_C4 |
| DISPARITY_RIGHT | | Disparity map for right sensor. Each pixel contains 1 float. Type: sl.MAT_TYPE.MAT_32F_C1 |
| DEPTH_RIGHT | | Depth map for right sensor. Each pixel contains 1 float. Type: sl.MAT_TYPE.MAT_32F_C1 |
| XYZ_RIGHT | | Point cloud for right sensor. Each pixel contains 4 float (X, Y, Z, not used). Type: sl.MAT_TYPE.MAT_32F_C4 |
| XYZRGBA_RIGHT | | Colored point cloud for right sensor. Each pixel contains 4 float (X, Y, Z, color). The color needs to be read as an unsigned char[4] representing the RGBA color. Type: sl.MAT_TYPE.MAT_32F_C4 |
| XYZBGRA_RIGHT | | Colored point cloud for right sensor. Each pixel contains 4 float (X, Y, Z, color). The color needs to be read as an unsigned char[4] representing the BGRA color. Type: sl.MAT_TYPE.MAT_32F_C4 |
| XYZARGB_RIGHT | | Colored point cloud for right sensor. Each pixel contains 4 float (X, Y, Z, color). The color needs to be read as an unsigned char[4] representing the ARGB color. Type: sl.MAT_TYPE.MAT_32F_C4 |
| XYZABGR_RIGHT | | Colored point cloud for right sensor. Each pixel contains 4 float (X, Y, Z, color). The color needs to be read as an unsigned char[4] representing the ABGR color. Type: sl.MAT_TYPE.MAT_32F_C4 |
| NORMALS_RIGHT | | Normal vectors map for right view. Each pixel contains 4 float (X, Y, Z, 0). Type: sl.MAT_TYPE.MAT_32F_C4 |
| DEPTH_U16_MM | | Depth map in millimeter whatever the sl.UNIT defined in sl.InitParameters.coordinateUnits. Invalid values are set to 0 and depth values are clamped at 65000. Each pixel contains 1 unsigned short. Type: sl.MAT_TYPE.MAT_16U_C1. |
| DEPTH_U16_MM_RIGHT | | Depth map in millimeter for right sensor. Each pixel contains 1 unsigned short. Type: sl.MAT_TYPE.MAT_16U_C1. |
Lists retrievable measures.
**Note**: For more info, read about the ZED SDK C++ enum it mirrors: [MEASURE](https://www.stereolabs.com/docs/api/group__Depth__group.html#ga798a8eed10c573d759ef7e5a5bcd545d)
### enum VOXELIZATION_MODE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| FIXED | | No adaptation. Voxel size is used uniformly everywhere. |
| STEREO_UNCERTAINTY | | Quadratic growth matching stereo depth noise. |
| LINEAR | | Linear growth with depth. Suits lidar/ToF sensors. |
Controls how voxel size adapts with depth.
### enum REGION_OF_INTEREST_AUTO_DETECTION_STATE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| RUNNING | | The region of interest auto detection is initializing. |
| READY | | The region of interest mask is ready, if auto_apply was enabled, the region of interest mask is being used. |
| NOT_ENABLED | | The region of interest auto detection is not enabled. |
Lists the different states of region of interest auto detection.
### enum INPUT_TYPE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| USB | | USB input mode |
| SVO | | SVO file input mode |
| STREAM | | STREAM input mode (requires to use EnableStreaming() / DisableStreaming() on the "sender" side) |
| GMSL | | GMSL input mode |
Lists available input types in the ZED SDK.
### enum BUS_TYPE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| USB | | USB input mode |
| GMSL | | GMSL input mode |
| AUTO | | Automatically select the input type. Trying first for available USB cameras, then GMSL. |
Lists available LIVE input type in the ZED SDK.
### enum CAMERA_STATE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| AVAILABLE | | The camera can be opened by the ZED SDK. |
| NOT_AVAILABLE | | The camera is already opened and unavailable. |
Lists possible camera states.
### enum RESOLUTION
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| HD4K | | 3856x2180 for imx678 mono Available FPS: 15 |
| QHDPLUS | | 3800x1800 |
| HD2K | | 2208*1242 (x2) Available FPS: 15 |
| HD1536 | | 1920*1536 (x2) Available FPS: 15, 30*/ |
| HD1080 | | 1920*1080 (x2) Available FPS: 15, 30 |
| HD1200 | | 1920*1200 (x2) Available FPS: 15, 30, 60 |
| HD720 | | 1280*720 (x2) Available FPS: 15, 30, 60 |
| HDSVGA | | 960*600 (x2) Available FPS: 15, 30, 60, 120 |
| VGA | | 672*376 (x2) Available FPS: 15, 30, 60, 100 |
| XVGA | | 960*768 (x2) Available FPS: 30 Only supported with ZED-X HDR lineup (One/Stereo) |
| TXGA | | 640*512 (x2) Available FPS: 30 Only supported with ZED-X HDR lineup (One/Stereo) |
| AUTO | 11| Select the resolution compatible with the camera:
* ZED X/X Mini: HD1200
* other cameras: HD720 |
Lists available resolutions.
**Note**: The VGA resolution does not respect the 640*480 standard to better fit the camera sensor (672*376 is used).
**Warning**:
* All resolutions are not available for every camera.
* You can find the available resolutions for each camera in [our documentation](https://www.stereolabs.com/docs/video/camera-controls#selecting-a-resolution).
### enum FLIP_MODE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| OFF | 0| No flip applied. Default behavior. |
| ON | 1| Images and camera sensors' data are flipped useful when your camera is mounted upside down. |
| AUTO | 2| In LIVE mode, use the camera orientation (if an IMU is available) to set the flip mode. In SVO mode, read the state of this enum when recorded. |
Lists possible flip modes of the camera.
### enum MODEL
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| ZED | | ZED camera model |
| ZED_M | | ZED Mini (ZED M) camera model |
| ZED2 | | ZED 2 camera model |
| ZED2i | | ZED 2i camera model |
| ZED_X | | ZED X camera model |
| ZED_XM | | ZED X Mini (ZED XM) camera model |
| ZED_X_NANO | 9| ZED X Nano (18mm baseline) camera model with dual global shutter AR0234 sensor |
| VIRTUAL_ZED_X | 11| Virtual ZED X generated from 2 ZED X One |
| ZED_XONE_GS | 30| ZED X One with global shutter AR0234 sensor |
| ZED_XONE_UHD | 31| ZED X One with 4K rolling shutter IMX678 sensor |
| ZED_XONE_HDR | 32| ZED X One HDR. |
Lists ZED camera model. [SL_MODEL](https://www.stereolabs.com/docs/api/c/types__c_8h.html#aa71ca736d522c5f280cf90450665e749) in C wrapper.
### enum VIEW
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| LEFT | | Left BGRA image. Each pixel contains 4 unsigned char (B, G, R, A). Type: sl.MAT_TYPE.MAT_8U_C4. |
| RIGHT | | Right BGRA image. Each pixel contains 4 unsigned char (B, G, R, A). Type: sl.MAT_TYPE.MAT_8U_C4. |
| LEFT_GREY | | Left gray image. Each pixel contains 1 unsigned char. Type: sl.MAT_TYPE.MAT_8U_C1. |
| RIGHT_GREY | | Right gray image. Each pixel contains 1 unsigned char. Type: sl.MAT_TYPE.MAT_8U_C1. |
| LEFT_NV12_UNRECTIFIED | | Left NV12 unrectified image. |
| RIGHT_NV12_UNRECTIFIED | | Right NV12 unrectified image. |
| LEFT_UNRECTIFIED | | Left BGRA unrectified image. Each pixel contains 4 unsigned char (B, G, R, A). Type: sl.MAT_TYPE.MAT_8U_C4. |
| RIGHT_UNRECTIFIED | | Right BGRA unrectified image. Each pixel contains 4 unsigned char (B, G, R, A). Type: sl.MAT_TYPE.MAT_8U_C4. |
| LEFT_UNRECTIFIED_GREY | | Left gray unrectified image. Each pixel contains 1 unsigned char. Type: sl.MAT_TYPE.MAT_8U_C1. |
| RIGHT_UNRECTIFIED_GREY | | Right gray unrectified image. Each pixel contains 1 unsigned char. Type: sl.MAT_TYPE.MAT_8U_C1. |
| SIDE_BY_SIDE | | Left and right image (the image width is therefore doubled). Each pixel contains 4 unsigned char (B, G, R, A). Type: sl.MAT_TYPE.MAT_8U_C4. |
| DEPTH | | Color rendering of the depth. Each pixel contains 4 unsigned char (B, G, R, A). Type: sl.MAT_TYPE.MAT_8U_C4. |
| CONFIDENCE | | Color rendering of the depth confidence. Each pixel contains 4 unsigned char (B, G, R, A). Type: sl.MAT_TYPE.MAT_8U_C4. |
| NORMALS | | Color rendering of the normals. Each pixel contains 4 unsigned char (B, G, R, A). Type: sl.MAT_TYPE.MAT_8U_C4. |
| DEPTH_RIGHT | | Color rendering of the right depth mapped on right sensor. Each pixel contains 4 unsigned char (B, G, R, A). Type: sl.MAT_TYPE.MAT_8U_C4. |
| NORMALS_RIGHT | | Color rendering of the normals mapped on right sensor. Each pixel contains 4 unsigned char (B, G, R, A). Type: sl.MAT_TYPE.MAT_8U_C4. |
| LEFT_BGRA | | Alias of LEFT |
| LEFT_BGR | | Left image. Each pixel contains 3 unsigned char (B, G, R). Type: sl.MAT_TYPE.MAT_8U_C3. |
| RIGHT_BGRA | | Alias of RIGHT |
| RIGHT_BGR | | Right image. Each pixel contains 3 unsigned char (B, G, R). Type: sl.MAT_TYPE.MAT_8U_C3. |
| LEFT_UNRECTIFIED_BGRA | | Alias of LEFT_UNRECTIFIED |
| LEFT_UNRECTIFIED_BGR | | Left unrectified image. Each pixel contains 3 unsigned char (B, G, R). Type: sl.MAT_TYPE.MAT_8U_C3. |
| RIGHT_UNRECTIFIED_BGRA | | Alias of RIGHT_UNRECTIFIED |
| RIGHT_UNRECTIFIED_BGR | | Right unrectified image. Each pixel contains 3 unsigned char (B, G, R). Type: sl.MAT_TYPE.MAT_8U_C3. |
| SIDE_BY_SIDE_BGRA | | Alias of SIDE_BY_SIDE |
| SIDE_BY_SIDE_BGR | | Side by side image. Each pixel contains 3 unsigned char (B, G, R). Type: sl.MAT_TYPE.MAT_8U_C3. |
| SIDE_BY_SIDE_GRAY | | gray scale side by side image. Each pixel contains 1 unsigned char. Type: sl.MAT_TYPE.MAT_8U_C1. |
| SIDE_BY_SIDE_UNRECTIFIED_BGRA | | Unrectified side by side image. Each pixel contains 4 unsigned char (B, G, R, A). Type: sl.MAT_TYPE.MAT_8U_C4. |
| SIDE_BY_SIDE_UNRECTIFIED_BGR | | Unrectified side by side image. Each pixel contains 3 unsigned char (B, G, R). Type: sl.MAT_TYPE.MAT_8U_C3. |
| SIDE_BY_SIDE_UNRECTIFIED_GRAY | | Grayscale unrectified side by side image. Each pixel contains 1 unsigned char. Type: sl.MAT_TYPE.MAT_8U_C1. |
| DEPTH_BGRA | | Alias of DEPTH |
| DEPTH_BGR | | Depth image. Each pixel contains 3 unsigned char (B, G, R). Type: sl.MAT_TYPE.MAT_8U_C3. |
| DEPTH_GRAY | | Grayscale depth image. Each pixel contains 1 unsigned char. Type: sl.MAT_TYPE.MAT_8U_C1. |
| CONFIDENCE_BGRA | | Alias of CONFIDENCE |
| CONFIDENCE_BGR | | Confidence image. Each pixel contains 3 unsigned char (B, G, R). Type: sl.MAT_TYPE.MAT_8U_C3. |
| CONFIDENCE_GRAY | | Grayscale confidence image. Each pixel contains 1 unsigned char. Type: sl.MAT_TYPE.MAT_8U_C1. |
| NORMALS_BGRA | | Alias of NORMALS |
| NORMALS_BGR | | Normals image. Each pixel contains 3 unsigned char (B, G, R). Type: sl.MAT_TYPE.MAT_8U_C3. |
| NORMALS_GRAY | | Grayscale normals image. Each pixel contains 1 unsigned char. Type: sl.MAT_TYPE.MAT_8U_C1. |
| DEPTH_RIGHT_BGRA | | Alias of DEPTH_RIGHT |
| DEPTH_RIGHT_BGR | | Depth right image. Each pixel contains 3 unsigned char (B, G, R). Type: sl.MAT_TYPE.MAT_8U_C3. |
| DEPTH_RIGHT_GRAY | | Grayscale depth right image. Each pixel contains 1 unsigned char. Type: sl.MAT_TYPE.MAT_8U_C1. |
| NORMALS_RIGHT_BGRA | | Alias of NORMALS_RIGHT |
| NORMALS_RIGHT_BGR | | Normals right image. Each pixel contains 3 unsigned char (B, G, R). Type: sl.MAT_TYPE.MAT_8U_C3. |
| NORMALS_RIGHT_GRAY | | Grayscale normals right image. Each pixel contains 1 unsigned char. Type: sl.MAT_TYPE.MAT_8U_C1. |
Lists available views.
**Note**: For more info, read about the ZED SDK C++ enum it mirrors: [VIEW](https://www.stereolabs.com/docs/api/group__Video__group.html#ga77fc7bfc159040a1e2ffb074a8ad248c)
### enum VIDEO_SETTINGS
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| BRIGHTNESS | | Brightness control. Affected value should be between 0 and 8. |
| CONTRAST | | Contrast control Affected value should be between 0 and 8. |
| HUE | | Hue control Affected value should be between 0 and 11. |
| SATURATION | | Saturation control Affected value should be between 0 and 8. |
| SHARPNESS | | Digital sharpening control Affected value should be between 0 and 8. |
| GAMMA | | ISP gamma control Affected value should be between 1 and 9. |
| GAIN | | Gain control Affected value should be between 0 and 100 for manual control. |
| EXPOSURE | | Exposure control Affected value should be between 0 and 100 for manual control. The exposition is mapped linearly in a percentage of the following max values. Special case for `EXPOSURE = 0` that corresponds to 0.17072ms.
The conversion to milliseconds depends on the framerate:
* 15fps `EXPOSURE = 100` -> 19.97ms
* 30fps `EXPOSURE = 100` -> 19.97ms
* 60fps `EXPOSURE = 100` -> 10.84072ms
* 100fps `EXPOSURE = 100` -> 10.106624ms |
| AEC_AGC | | Defines if the GAIN and EXPOSURE are in automatic mode or not. Setting GAIN or EXPOSURE values will automatically set this value to 0. |
| AEC_AGC_ROI | | Defines the region of interest for automatic exposure/gain computation. To be used with overloaded SetCameraSettings() / GetCameraSettings() methods. |
| WHITEBALANCE_TEMPERATURE | | Color temperature control Affected value should be between 2800 and 6500 with a step of 100. |
| WHITEBALANCE_AUTO | | Defines if the white balance is in automatic mode or not. |
| LED_STATUS | | Status of the front LED of the camera. Set to 0 to disable the light, 1 to enable the light. Default value is on. |
| EXPOSURE_TIME | | Exposure time control in microseconds. Only available for GMSL2-based camera (ZED-X, ZED-X Mini, ZED-Xone,...) . |
| ANALOG_GAIN | | Analog gain (sensor) control in mDB. Use this value to get the real analog gain in mdB. |
| DIGITAL_GAIN | | Digital gain (ISP) as a factor. |
| AUTO_EXPOSURE_TIME_RANGE | | Range of exposure auto control in microseconds. Used with SetCameraSettings(). Min/max range between max range defined in DTS. By default : [28000 - fps_time or 19000] us. |
| AUTO_ANALOG_GAIN_RANGE | | Range of sensor gain in automatic control. Used with SetCameraSettings(). Min/max range between max range defined in DTS. By default: [1000 - 16000] mdB. |
| AUTO_DIGITAL_GAIN_RANGE | | Range of digital ISP gain in automatic control. Used with SetCameraSettings(). Min/max range between max range defined in DTS. By default: [1 - 256]. |
| EXPOSURE_COMPENSATION | | Exposure-target compensation made after auto exposure. Reduces the overall illumination target by factor of F-stops. Affected value should be between 0 and 100 (mapped between [-2.0,2.0]). Default value is 50, i.e. no compensation applied. |
| DENOISING | | Level of denoising applied on both left and right images. Affected value should be between 0 and 100. Default value is 50. |
| SCENE_ILLUMINANCE | | Level of illuminance of the scene calculated by the ISP. Can be used to determine the level of light in the scene and adjust settings accordingly. |
| AE_ANTIBANDING | | AE anti-banding mode. Affected value should be between 0 and 3. 0: OFF, 1: AUTO, 2: 50Hz, 3: 60Hz. Default value is 0 (OFF). |
Lists available camera settings for the camera (contrast, hue, saturation, gain, ...).
**Warning**: GAIN and EXPOSURE are linked in auto/default mode (see sl.Camera.SetCameraSettings()).
### enum TIME_REFERENCE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| IMAGE | | The requested timestamp or data will be at the time of the frame extraction. |
| CURRENT | | The requested timestamp or data will be at the time of the function call. |
Lists possible time references for timestamps or data.
### enum TIMESTAMP_CLOCK
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| SYSTEM_CLOCK | | Timestamps use the system (wall-clock) time. Affected by NTP/PTP adjustments. |
| MONOTONIC_CLOCK | | Timestamps use a monotonic clock. Immune to system clock step adjustments (NTP/PTP). |
Lists available clock sources for SDK timestamps.
Selects the clock used internally by the SDK to timestamp images and sensor data. Both image and IMU timestamps always use the same selected clock, ensuring coherent results.
Note: this is a process-wide setting. Use Camera.SetTimestampClock before opening any camera.
### enum SVO_COMPRESSION_MODE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| LOSSLESS_BASED | | PNG/ZSTD (lossless) CPU based compression. Average size: 42% of RAW |
| H264_BASED | | H264 (AVCHD) GPU based compression. Average size: 1% of RAW |
| H265_BASED | | H265 (HEVC) GPU based compression. Average size: 1% of RAW |
| H264_LOSSLESS_BASED | | H264 Lossless GPU/Hardware based compression. Average size: 25% of RAW Provides a SSIM/PSNR result (vs RAW) >= 99.9%. |
| H265_LOSSLESS_BASED | | H265 Lossless GPU/Hardware based compression. Average size: 25% of RAW Provides a SSIM/PSNR result (vs RAW) >= 99.9%. |
Lists available compression modes for SVO recording.
**Note**: LOSSLESS_BASED is an improvement of previous lossless compression (used in ZED Explorer), even if size may be bigger, compression time is much faster.
### enum SVO_ENCODING_PRESET
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| DEFAULT | | Encoder default. Maps to NVENC P4 / V4L2 default. |
| ULTRAFAST | | Fastest encoding, lowest quality. Maps to NVENC P1 / V4L2 ULTRAFAST. |
| FAST | | Fast encoding. Maps to NVENC P2 / V4L2 FAST. |
| MEDIUM | | Balanced speed/quality. Maps to NVENC P3 / V4L2 MEDIUM. |
| SLOW | | Slow encoding, higher quality. Maps to NVENC P5 / V4L2 SLOW. |
Lists available encoding presets for SVO recording. Controls the speed/quality tradeoff of the GPU hardware encoder.
**Note**: Only applicable when compression mode is H264 or H265.
### enum STREAMING_CODEC
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| H264_BASED | | AVCHD/H264 encoding |
| H265_BASED | | HEVC/H265 encoding |
Lists the different encoding types for image streaming.
### enum SIDE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| LEFT | 0| Left side only. |
| RIGHT | 1| Right side only. |
| BOTH | 2| Left and right side. |
Lists possible sides on which to get data from.
### enum AREA_EXPORTING_STATE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| SUCCESS | | The spatial memory file has been successfully created. |
| RUNNING | | The spatial memory is currently being written. |
| NOT_STARTED | | The spatial memory file exportation has not been called. |
| FILE_EMPTY | | The spatial memory contains no data, the file is empty. |
| FILE_ERROR | | The spatial memory file has not been written because of a wrong file name. |
| SPATIAL_MEMORY_DISABLED | | The spatial memory learning is disabled. No file can be created. |
Lists the different states of spatial memory area export.
### enum MAPPING_RESOLUTION
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| HIGH | | Creates a detailed geometry. Requires lots of memory. |
| MEDIUM | | Small variations in the geometry will disappear. Useful for big objects. |
| LOW | | Keeps only huge variations of the geometry. Useful for outdoor purposes. |
Lists the spatial mapping resolution presets.
### enum MAPPING_RANGE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| NEAR | | Geometry within 3.5 meters of the camera will be mapped. |
| MEDIUM | | Geometry within 5 meters of the camera will be mapped. |
| FAR | | Objects as far as 10 meters away are mapped. Useful for outdoors. |
Lists the spatial mapping depth range presets.
### enum SPATIAL_MAP_TYPE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| MESH | | The geometry is represented by a set of vertices connected by edges and forming faces. No color information is available. |
| FUSED_POINT_CLOUD | | The geometry is represented by a set of 3D colored points. |
Lists the types of spatial maps that can be created.
### enum MESH_FILE_FORMAT
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| PLY | | Contains only vertices and faces. |
| BIN | | Contains only vertices and faces encoded in binary. |
| OBJ | | Contains vertices, normals, faces, and texture information (if possible). |
Lists available mesh file formats.
### enum MESH_FILTER
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| LOW | | Clean the mesh by closing small holes and removing isolated faces. |
| MEDIUM | | Soft faces decimation and smoothing. |
| HIGH | | Drastically reduce the number of faces and apply a soft smooth. |
Lists available mesh filtering intensities.
### enum SPATIAL_MAPPING_STATE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| INITIALIZING | | The spatial mapping is initializing. |
| OK | | The depth and tracking data were correctly integrated in the mapping algorithm. |
| NOT_ENOUGH_MEMORY | | The maximum memory dedicated to the scanning has been reached. The mesh will no longer be updated. |
| NOT_ENABLED | | sl.Camera.EnableSpatialMapping() wasn't called or the scanning was stopped and not relaunched. |
| FPS_TOO_LOW | | The effective FPS is too low to give proper results for spatial mapping. Consider using performance parameters (sl.DEPTH_MODE.PERFORMANCE, sl.MAPPING_RESOLUTION.LOW, low camera resolution (sl.RESOLUTION.VGA / sl.RESOLUTION.HDSVGA or sl.RESOLUTION.HD720). |
Lists the different states of spatial mapping.
### enum UNIT
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| MILLIMETER | | International System (1/1000 meters) |
| CENTIMETER | | International System (1/100 meters) |
| METER | | International System (1 meter) |
| INCH | | Imperial Unit (1/12 foot) |
| FOOT | | Imperial Unit (1 feet) |
Lists available units for measures.
### enum PLANE_TYPE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| FLOOR | | Floor plane of a scene. Retrieved by sl.Camera.FindFloorPlane(). |
| HIT_HORIZONTAL | | Horizontal plane, such as a tabletop, floor, etc. Detected with sl.Camera.FindPlaneAtHit() using screen-space coordinates. |
| HIT_VERTICAL | | Vertical plane, such as a wall. Detected with sl.Camera.FindPlaneAtHit() using screen-space coordinates. |
| HIT_UNKNOWN | | Plane at an angle neither parallel nor perpendicular to the floor. Detected with sl.Camera.FindPlaneAtHit() using screen-space coordinates. |
Lists the available plane types detected based on its orientation and whether detected by sl.Camera.FindFloorPlane() or sl.Camera.FindPlaneAtHit().
### enum AREA_EXPORT_STATE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| AREA_EXPORT_STATE_SUCCESS | | Spatial memory file has been successfully created. |
| AREA_EXPORT_STATE_RUNNING | | Spatial memory file is currently being written to. |
| AREA_EXPORT_STATE_NOT_STARTED | | Spatial memory file export has not been called. |
| AREA_EXPORT_STATE_FILE_EMPTY | | Spatial memory contains no data; the file is empty. |
| AREA_EXPORT_STATE_FILE_ERROR | | Spatial memory file has not been written to because of a bad file name. |
| AREA_EXPORT_STATE_SPATIAL_MEMORY_DISABLED | | Spatial memory has been disabled, so no file can be created. |
Possible states of the ZED's spatial memory area export, for saving 3D features used by the tracking system to relocalize the camera. This is used when saving a mesh generated by spatial mapping when Save Mesh is enabled - a .area file is saved as well.
### enum BODY_FORMAT
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| BODY_18 | | 18-keypoint model Basic body model |
| BODY_34 | | 34-keypoint model |
| BODY_38 | | 38-keypoint model Including simplified face, hands and feet. |
Lists supported skeleton body models.
### enum BODY_KEYPOINTS_SELECTION
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| FULL | | Full keypoint model |
| UPPER_BODY | | Upper body keypoint model Will output only upper body (from hip). |
Lists supported models for skeleton keypoints selection.
### enum OBJECT_ACCELERATION_PRESET
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| DEFAULT | | The ZED SDK will automatically determine the appropriate maximum acceleration. |
| LOW | | Suitable for objects with relatively low maximum acceleration (e.g., a person walking). |
| MEDIUM | | Suitable for objects with moderate maximum acceleration (e.g., a person running). |
| HIGH | | Suitable for objects with high maximum acceleration (e.g., a car accelerating, a kicked sports ball). |
Lists of supported presets for maximum acceleration allowed for a given tracked object.
### enum OBJECT_CLASS
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| PERSON | 0| For people detection |
| VEHICLE | 1| For vehicle detection (cars, trucks, buses, motorcycles, etc.) |
| BAG | 2| For bag detection (backpack, handbag, suitcase, etc.) |
| ANIMAL | 3| For animal detection (cow, sheep, horse, dog, cat, bird, etc.) |
| ELECTRONICS | 4| For electronic device detection (cellphone, laptop, etc.) |
| FRUIT_VEGETABLE | 5| For fruit and vegetable detection (banana, apple, orange, carrot, etc.) |
| SPORT | 6| For sport-related object detection (sport ball, etc.) |
Lists available object classes.
### enum OBJECT_SUBCLASS
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| PERSON | 0| sl.OBJECT_CLASS.PERSON |
| BICYCLE | 1| sl.OBJECT_CLASS.VEHICLE |
| CAR | 2| sl.OBJECT_CLASS.VEHICLE |
| MOTORBIKE | 3| sl.OBJECT_CLASS.VEHICLE |
| BUS | 4| sl.OBJECT_CLASS.VEHICLE |
| TRUCK | 5| sl.OBJECT_CLASS.VEHICLE |
| BOAT | 6| sl.OBJECT_CLASS.VEHICLE |
| BACKPACK | 7| sl.OBJECT_CLASS.BAG |
| HANDBAG | 8| sl.OBJECT_CLASS.BAG |
| SUITCASE | 9| sl.OBJECT_CLASS.BAG |
| BIRD | 10| sl.OBJECT_CLASS.ANIMAL |
| CAT | 11| sl.OBJECT_CLASS.ANIMAL |
| DOG | 12| sl.OBJECT_CLASS.ANIMAL |
| HORSE | 13| sl.OBJECT_CLASS.ANIMAL |
| SHEEP | 14| sl.OBJECT_CLASS.ANIMAL |
| COW | 15| sl.OBJECT_CLASS.ANIMAL |
| CELLPHONE | 16| sl.OBJECT_CLASS.ELECTRONICS |
| LAPTOP | 17| sl.OBJECT_CLASS.ELECTRONICS |
| BANANA | 18| sl.OBJECT_CLASS.FRUIT_VEGETABLE |
| APPLE | 19| sl.OBJECT_CLASS.FRUIT_VEGETABLE |
| ORANGE | 20| sl.OBJECT_CLASS.FRUIT_VEGETABLE |
| CARROT | 21| sl.OBJECT_CLASS.FRUIT_VEGETABLE |
| PERSON_HEAD | 22| sl.OBJECT_CLASS.PERSON |
| SPORTSBALL | 23| sl.OBJECT_CLASS.SPORT |
| MACHINERY | 24| sl.OBJECT_CLASS.VEHICLE |
List available object subclasses.
Given as hint, when using object tracking an object can change of sl.OBJECT_SUBCLASS while keeping the same sl.OBJECT_CLASS (i.e.: frame n: sl.OBJECT_SUBCLASS.MOTORBIKE, frame n+1: sl.OBJECT_SUBCLASS.BICYCLE).
### enum OBJECT_TRACKING_STATE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| OFF | | The tracking is not yet initialized. The object id is not usable. |
| OK | | The object is tracked. |
| SEARCHING | | The object could not be detected in the image and is potentially occluded. The trajectory is estimated. |
| TERMINATE | | This is the last searching state of the track. The track will be deleted in the next sl.Camera.RetrieveObjects(). |
Lists the different states of object tracking.
### enum OBJECT_ACTION_STATE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| IDLE | 0| The object is staying static. |
| MOVING | 1| The object is moving. |
Lists the different states of an object's actions.
### enum OBJECT_DETECTION_MODEL
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| MULTI_CLASS_BOX_FAST | | Any objects, bounding box based. |
| MULTI_CLASS_BOX_MEDIUM | | Any objects, bounding box based, compromise between accuracy and speed. |
| MULTI_CLASS_BOX_ACCURATE | | Any objects, bounding box based, more accurate but slower than the base model. |
| PERSON_HEAD_BOX_FAST | | Bounding box detector specialized in person heads particularly well suited for crowded environments. The person localization is also improved. |
| PERSON_HEAD_BOX_ACCURATE | | Bounding box detector specialized in person heads, particularly well suited for crowded environments. The person localization is also improved, more accurate but slower than the base model. |
| CUSTOM_BOX_OBJECTS | | For external inference, using your own custom model and/or frameworks. This mode disables the internal inference engine, the 2D bounding box detection must be provided. |
Lists available models for the object detection module.
### enum BODY_TRACKING_MODEL
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| HUMAN_BODY_FAST | | Keypoints based, specific to human skeleton, real time performance even on Jetson or low end GPU cards. |
| HUMAN_BODY_MEDIUM | | Keypoints based, specific to human skeleton, compromise between accuracy and speed. |
| HUMAN_BODY_ACCURATE | | Keypoints based, specific to human skeleton, state of the art accuracy, requires powerful GPU. |
Lists available models for the body tracking module.
### enum AI_MODELS
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| MULTI_CLASS_DETECTION | | Related to sl.OBJECT_DETECTION_MODEL.MULTI_CLASS_BOX_FAST |
| MULTI_CLASS_MEDIUM_DETECTION | | Related to sl.OBJECT_DETECTION_MODEL.MULTI_CLASS_BOX_MEDIUM |
| MULTI_CLASS_ACCURATE_DETECTION | | Related to sl.OBJECT_DETECTION_MODEL.MULTI_CLASS_BOX_ACCURATE |
| HUMAN_BODY_FAST_DETECTION | | Related to sl.BODY_TRACKING_MODEL.HUMAN_BODY_FAST |
| HUMAN_BODY_MEDIUM_DETECTION | | Related to sl.BODY_TRACKING_MODEL.HUMAN_BODY_MEDIUM |
| HUMAN_BODY_ACCURATE_DETECTION | | Related to sl.BODY_TRACKING_MODEL.HUMAN_BODY_ACCURATE |
| HUMAN_BODY_38_FAST_DETECTION | | Related to sl.BODY_TRACKING_MODEL.HUMAN_BODY_FAST |
| HUMAN_BODY_38_MEDIUM_DETECTION | | Related to sl.BODY_TRACKING_MODEL.HUMAN_BODY_MEDIUM |
| HUMAN_BODY_38_ACCURATE_DETECTION | | Related to sl.BODY_TRACKING_MODEL.HUMAN_BODY_ACCURATE |
| PERSON_HEAD_DETECTION | | Related to sl.OBJECT_DETECTION_MODEL.PERSON_HEAD_BOX_FAST |
| PERSON_HEAD_ACCURATE_DETECTION | | Related to sl.OBJECT_DETECTION_MODEL.PERSON_HEAD_BOX_ACCURATE |
| REID_ASSOCIATION | | Related to sl.BatchParameters.enable |
| NEURAL_LIGHT_DEPTH | | Related to sl.DEPTH_MODE.NEURAL_LIGHT |
| NEURAL_DEPTH | | Related to sl.DEPTH_MODE.NEURAL |
| NEURAL_PLUS_DEPTH | | Related to sl.DEPTH_MODE.NEURAL_PLUS |
Lists available AI models.
### enum OBJECT_FILTERING_MODE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| NONE | | The ZED SDK will not apply any preprocessing to the detected objects. |
| NMS3D | | The ZED SDK will remove objects that are in the same 3D position as an already tracked object (independent of class id). |
| NMS3D_PER_CLASS | | The ZED SDK will remove objects that are in the same 3D position as an already tracked object of the same class id. |
Lists supported bounding box preprocessing.
### enum INFERENCE_PRECISION
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| FP32 | 0| |
| FP16 | 1| |
| INT8 | 2| |
Lists supported bounding box preprocessing.
### enum BODY_18_PARTS
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| NOSE | 0| |
| NECK | 1| |
| RIGHT_SHOULDER | 2| |
| RIGHT_ELBOW | 3| |
| RIGHT_WRIST | 4| |
| LEFT_SHOULDER | 5| |
| LEFT_ELBOW | 6| |
| LEFT_WRIST | 7| |
| RIGHT_HIP | 8| |
| RIGHT_KNEE | 9| |
| RIGHT_ANKLE | 10| |
| LEFT_HIP | 11| |
| LEFT_KNEE | 12| |
| LEFT_ANKLE | 13| |
| RIGHT_EYE | 14| |
| LEFT_EYE | 15| |
| RIGHT_EAR | 16| |
| LEFT_EAR | 17| |
Semantic of human body parts and order of sl.BodyData.keypoints for sl.BODY_FORMAT.BODY_18.
### enum BODY_34_PARTS
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| PELVIS | 0| |
| NAVAL_SPINE | 1| |
| CHEST_SPINE | 2| |
| NECK | 3| |
| LEFT_CLAVICLE | 4| |
| LEFT_SHOULDER | 5| |
| LEFT_ELBOW | 6| |
| LEFT_WRIST | 7| |
| LEFT_HAND | 8| |
| LEFT_HANDTIP | 9| |
| LEFT_THUMB | 10| |
| RIGHT_CLAVICLE | 11| |
| RIGHT_SHOULDER | 12| |
| RIGHT_ELBOW | 13| |
| RIGHT_WRIST | 14| |
| RIGHT_HAND | 15| |
| RIGHT_HANDTIP | 16| |
| RIGHT_THUMB | 17| |
| LEFT_HIP | 18| |
| LEFT_KNEE | 19| |
| LEFT_ANKLE | 20| |
| LEFT_FOOT | 21| |
| RIGHT_HIP | 22| |
| RIGHT_KNEE | 23| |
| RIGHT_ANKLE | 24| |
| RIGHT_FOOT | 25| |
| HEAD | 26| |
| NOSE | 27| |
| LEFT_EYE | 28| |
| LEFT_EAR | 29| |
| RIGHT_EYE | 30| |
| RIGHT_EAR | 31| |
| LEFT_HEEL | 32| |
| RIGHT_HEEL | 33| |
Semantic of human body parts and order of sl.BodyData.keypoints for sl.BODY_FORMAT.BODY_34.
### enum BODY_38_PARTS
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| PELVIS | 0| |
| SPINE_1 | 1| |
| SPINE_2 | 2| |
| SPINE_3 | 3| |
| NECK | 4| |
| NOSE | 5| |
| LEFT_EYE | 6| |
| RIGHT_EYE | 7| |
| LEFT_EAR | 8| |
| RIGHT_EAR | 9| |
| LEFT_CLAVICLE | 10| |
| RIGHT_CLAVICLE | 11| |
| LEFT_SHOULDER | 12| |
| RIGHT_SHOULDER | 13| |
| LEFT_ELBOW | 14| |
| RIGHT_ELBOW | 15| |
| LEFT_WRIST | 16| |
| RIGHT_WRIST | 17| |
| LEFT_HIP | 18| |
| RIGHT_HIP | 19| |
| LEFT_KNEE | 20| |
| RIGHT_KNEE | 21| |
| LEFT_ANKLE | 22| |
| RIGHT_ANKLE | 23| |
| LEFT_BIG_TOE | 24| |
| RIGHT_BIG_TOE | 25| |
| LEFT_SMALL_TOE | 26| |
| RIGHT_SMALL_TOE | 27| |
| LEFT_HEEL | 28| |
| RIGHT_HEEL | 29| |
| LEFT_HAND_THUMB_4 | 30| |
| RIGHT_HAND_THUMB_4 | 31| |
| LEFT_HAND_INDEX_1 | 32| |
| RIGHT_HAND_INDEX_1 | 33| |
| LEFT_HAND_MIDDLE_4 | 34| |
| RIGHT_HAND_MIDDLE_4 | 35| |
| LEFT_HAND_PINKY_1 | 36| |
| RIGHT_HAND_PINKY_1 | 37| |
Semantic of human body parts and order of sl.BodyData.keypoints for sl.BODY_FORMAT.BODY_38.
### enum FUSION_ERROR_CODE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| FUSION_INCONSISTENT_FPS | -5| Significant differences observed between sender's FPS. Fusion quality will be affected. |
| FUSION_FPS_TOO_LOW | -4| Fusion FPS is too low because at least one sender has an FPS lower than 10 FPS. Fusion quality will be affected. |
| INVALID_TIMESTAMP | -3| You have attempted to ingest GNSSData into the Fusion system with an invalid timestamp. It is essential to ensure that the timestamp of your GNSSData is set correctly. This issue may arise from a unit error in the ingested timestamp, such as providing the timestamp in microseconds instead of nanoseconds. |
| INVALID_COVARIANCE | -2| This is a warning message notifying you about an issue encountered while ingesting GNSSData into the Fusion system. The problem lies in the very low covariance value provided. To ensure stability and prevent potential issues, the system will automatically clamp this covariance value. |
| NO_NEW_DATA_AVAILABLE | -1| All data from all sources has been consumed. No new data is available for processing. |
| SUCCESS | 0| Standard code for successful behavior. |
| GNSS_DATA_NEED_FIX | 1| This is a warning message indicating an issue with the ingestGNSSData function call. The problem lies in the gnss_status field of the GNSSData parameter, which is currently set to UNKNOWN. To enhance the accuracy of the VPS (Visual Positioning System), it is essential to provide an appropriate value for this field. To rectify this issue, please consider setting the gnss_status field to a valid value that reflects the status of your GNSS sensor. If your GNSS sensor is unable to output a status, it is recommended to set the gnss_status field to sl::GNSS_STATUS::SINGLE. |
| GNSS_DATA_COVARIANCE_MUST_VARY | 2| to prevent users from repeatedly ingesting a fixed or manually crafted covariance. |
| BODY_FORMAT_MISMATCH | 3| Senders are using different body formats. Please use the same body format. |
| MODULE_NOT_ENABLED | 4| The following module was not enabled. Please enable it to proceed. |
| SOURCE_MISMATCH | 5| Some sources are provided by SVO and others by LIVE stream. |
| CONNECTION_TIMED_OUT | 6| Connection timed out. Unable to reach the sender. Verify the sender's IP/port. |
| MEMORY_ALREADY_USED | 7| Intra-process shared memory allocation issue. Multiple connections to the same data. Check memory usage. |
| INVALID_IP_ADDRESS | 8| The provided IP address format is incorrect. Please provide the IP in the format 'a.b.c.d', where (a, b, c, d) are numbers between 0 and 255. |
| FAILURE | 9| Standard code for unsuccessful behavior. |
Lists the types of error that can be raised by the Fusion.
### enum SENDER_ERROR_CODE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| GRAB_ERROR | -3| The sender encountered a grab error. |
| INCONSISTENT_FPS | -2| The sender does not run with a constant frame rate. |
| FPS_TOO_LOW | -1| The frame rate of the sender is lower than 10 FPS. |
| SUCCESS | 0| Standard code for successful behavior. |
| DISCONNECTED | 1| The sender has been disconnected. |
Lists the types of error that can be raised during the Fusion by senders.
### enum COMM_TYPE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| LOCAL_NETWORK | | The sender and receiver are on the same local network and communicate by RTP. The communication can be affected by the local network load. |
| INTRA_PROCESS | | Both sender and receiver are declared by the same process and can be in different threads. This type of communication is optimized. |
Lists the different types of communications available for Fusion module.
### enum GNSS_FUSION_STATUS
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| OK | 0| The GNSS fusion module is calibrated and working successfully. |
| OFF | 1| The GNSS fusion module is not enabled. |
| CALIBRATION_IN_PROGRESS | 2| Calibration of the GNSS/VIO fusion module is in progress. |
| RECALIBRATION_IN_PROGRESS | 3| Re-alignment of GNSS/VIO data is in progress, leading to potentially inaccurate global position |
Lists the different states of the GNSS fusion.
### enum GNSS_STATUS
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| UNKNOWN | 0| No GNSS fix data is available. |
| SINGLE | 1| Single Point Positioning. |
| DGNSS | 2| Differential GNSS. |
| RTK_FIX | 3| Real-Time Kinematic (RTK) GNSS fix in fixed mode. |
| RTK_FLOAT | 4| Real-Time Kinematic (RTK) GNSS fix in float mode. |
| PPS | 5| Precise Positioning Service. |
### enum GNSS_MODE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| UNKNOWN | 0| No GNSS fix data is available. |
| NO_FIX | 1| No GNSS fix is available. |
| FIX_2D | 2| 2D GNSS fix, providing latitude and longitude coordinates but without altitude information. |
| FIX_3D | 3| 3D GNSS fix, providing latitude, longitude, and altitude coordinates. |
Gnss mode
### enum FUSION_REFERENCE_FRAME
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| WORLD | | The world frame is the reference frame of the world according to the fused positional Tracking |
| BASELINK | | The base link frame is the reference frame where camera calibration is given |
Reference frame used for the positional tracking.
### enum MAT_TYPE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| MAT_32F_C1 | | 1-channel matrix of float |
| MAT_32F_C2 | | 2-channel matrix of float |
| MAT_32F_C3 | | 3-channel matrix of float |
| MAT_32F_C4 | | 4-channel matrix of float |
| MAT_8U_C1 | | 1-channel matrix of unsigned char |
| MAT_8U_C2 | | 2-channel matrix of unsigned char |
| MAT_8U_C3 | | 3-channel matrix of unsigned char |
| MAT_8U_C4 | | 4-channel matrix of unsigned char |
| MAT_16U_C1 | | 1-channel matrix of unsigned short |
| MAT_S8_C4 | | 4-channel matrix of signed char |
Lists available sl.Mat formats.
**Note**:
* sl.Mat type depends on image or measure type.
* For the dependencies, see sl.VIEW and sl.MEASURE.
### enum COPY_TYPE
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| CPU_CPU | | Copy data from CPU to CPU. |
| CPU_GPU | | Copy data from CPU to GPU. |
| GPU_GPU | | Copy data from GPU to GPU. |
| GPU_CPU | | Copy data from GPU to CPU. |
Lists available copy operation on sl.Mat.
### enum MEM
| Enumerator | Value | Description |
| ---------- | ----- | ----------- |
| CPU | 0| Data will be stored on the CPU (processor side). |
| GPU | 1| Data will be stored on the GPU (graphic card side). |
| BOTH | 2| Data will be stored on both the CPU and GPU |
Lists available memory type.
---
# sl::CameraParameters
**Module:** **Depth Sensing Module**
Structure containing the intrinsic parameters of a camera. More...
## Detailed Description
```csharp
struct sl::CameraParameters;
```
Structure containing the intrinsic parameters of a camera.
**Note**:
*
* For more info, read about the ZED SDK C++ struct it mirrors: [CameraParameters](https://www.stereolabs.com/docs/api/structsl_1_1CameraParameters.html)
## Public Attributes Documentation
### variable fx
```csharp
float fx;
```
Focal length in pixels along x axis.
### variable fy
```csharp
float fy;
```
Focal length in pixels along y axis.
### variable cx
```csharp
float cx;
```
Optical center along x axis, defined in pixels (usually close to width / 2).
### variable cy
```csharp
float cy;
```
Optical center along y axis, defined in pixels (usually close to height / 2).
### variable disto
```csharp
double[] disto;
```
Distortion factor : [k1, k2, p1, p2, k3, k4, k5, k6, s1, s2, s3, s4].
Radial (k1, k2, k3, k4, k5, k6), Tangential (p1,p2) and Prism (s1, s2, s3, s4) distortion.
### variable vFOV
```csharp
float vFOV;
```
Vertical field of view, in degrees.
### variable hFOV
```csharp
float hFOV;
```
Horizontal field of view, in degrees.
### variable dFOV
```csharp
float dFOV;
```
Diagonal field of view, in degrees.
### variable resolution
```csharp
Resolution resolution;
```
Size in pixels of the images given by the camera.
### variable focalLengthMetric
```csharp
float focalLengthMetric;
```
Real focal length in millimeters.
---
# sl::CalibrationParameters
**Module:** **Depth Sensing Module**
Structure containing intrinsic and extrinsic parameters of the camera (translation and rotation). More...
## Detailed Description
```csharp
struct sl::CalibrationParameters;
```
Structure containing intrinsic and extrinsic parameters of the camera (translation and rotation).
**Note**:
* The calibration/rectification process, called during sl.Camera.Open(), is using the raw parameters defined in the SNXXX.conf file, where XXX is the serial number of the camera.
* Those values may be adjusted or not by the self-calibration to get a proper image alignment.
* After sl.Camera.Open() is done (with or without self-calibration activated), most of the stereo parameters (except baseline of course) should be 0 or very close to 0.
* It means that images after rectification process (given by sl.Camera.RetrieveImage()) are aligned as if they were taken by a "perfect" stereo camera, defined by the new sl.CalibrationParameters.
* For more info, read about the ZED SDK C++ struct it mirrors: [CalibrationParameters](https://www.stereolabs.com/docs/api/structsl_1_1CalibrationParameters.html)
**Warning**: CalibrationParameters are returned in sl.COORDINATE_SYSTEM.IMAGE, they are not impacted by the sl.InitParameters.coordinateSystem.
That information about the camera will be returned by sl.Camera.GetCameraInformation().
## Public Attributes Documentation
### variable leftCam
```csharp
CameraParameters leftCam;
```
Intrinsic sl.CameraParameters of the left camera.
### variable rightCam
```csharp
CameraParameters rightCam;
```
Intrinsic sl.CameraParameters of the right camera.
### variable Rot
```csharp
Quaternion Rot;
```
Left to right camera rotation, expressed in user coordinate system and unit (defined by sl.InitParameters.coordinateSystem).
### variable Trans
```csharp
Vector3 Trans;
```
Left to right camera translation, expressed in user coordinate system and unit (defined by sl.InitParameters.coordinateSystem).
---
# sl::Pose
**Module:** **Positional Tracking Module**
Structure containing positional tracking data giving the position and orientation of the camera in 3D space. More...
## Detailed Description
```csharp
struct sl::Pose;
```
Structure containing positional tracking data giving the position and orientation of the camera in 3D space.
Different representations of position and orientation can be retrieved, along with timestamp and pose confidence.
## Public Attributes Documentation
### variable valid
```csharp
bool valid;
```
Whether the tracking is activated or not.
**Note**: You should check that first if something is wrong.
### variable timestamp
```csharp
ulong timestamp;
```
Timestamp of the sl.Pose.
This timestamp should be compared with the camera timestamp for synchronization.
### variable rotation
```csharp
Quaternion rotation;
```
Orientation component of the sl.Pose.
### variable translation
```csharp
Vector3 translation;
```
Translation component of the sl.Pose.
### variable pose_confidence
```csharp
int pose_confidence;
```
Confidence/quality of the pose estimation for the target frame.
A confidence metric of the tracking [0-100] with:
* 0: tracking is lost
* 100: tracking can be fully trusted
### variable pose_covariance
```csharp
float[] pose_covariance;
```
6x6 pose covariance matrix of translation (the first 3 values) and rotation in so3 (the last 3 values).
### variable twist
```csharp
float[] twist;
```
Twist of the camera available in reference camera.
This expresses velocity in free space, broken into its linear and angular parts.
### variable twist_covariance
```csharp
float[] twist_covariance;
```
Row-major representation of the 6x6 twist covariance matrix of the camera.
This expresses the uncertainty of the twist.
---
# sl::SensorsData
**Module:** **Core Module**
Structure containing all sensors data (except image sensors) to be used for positional tracking or environment study. More...
## Detailed Description
```csharp
struct sl::SensorsData;
```
Structure containing all sensors data (except image sensors) to be used for positional tracking or environment study.
**Note**:
* Some data are not available in SVO and streaming input mode.
* They are specified by a note "Not available in SVO or STREAM mode." in the documentation of a specific data.
* If nothing is mentioned in the documentation, they are available in all input modes.
## Public Attributes Documentation
### variable imu
```csharp
ImuData imu;
```
IMU data.
### variable barometer
```csharp
BarometerData barometer;
```
Barometer data.
### variable magnetometer
```csharp
MagnetometerData magnetometer;
```
Magnetometer data.
### variable temperatureSensor
```csharp
TemperatureSensorData temperatureSensor;
```
Temperature data.
### variable camera_moving_state
```csharp
int camera_moving_state;
```
Motion state of the camera.
* static: 0
* moving: 1
* falling: 2
### variable image_sync_val
```csharp
int image_sync_val;
```
Indicates if the sensors data has been taken during a frame capture on sensor.
If the value is 1, the data has been taken during the same time than a frame has been acquired by the left sensor (the time precision is linked to the IMU rate, therefore 800Hz == 1.3ms).
If the value is 0, the data has not been taken during a frame acquisition.
---
# sl::PositionalTrackingParameters
**Module:** **Positional Tracking Module**
Class containing a set of parameters for the positional tracking module initialization. More...
## Detailed Description
```csharp
class sl::PositionalTrackingParameters;
```
Class containing a set of parameters for the positional tracking module initialization.
**Note**: Parameters can be user adjusted.
The default constructor sets all parameters to their default settings.
## Public Attributes Documentation
### variable initialWorldRotation
```csharp
Quaternion initialWorldRotation = Quaternion.Identity;
```
Rotation of the camera in the world frame when the camera is started.
### variable initialWorldPosition
```csharp
Vector3 initialWorldPosition = Vector3.Zero;
```
Position of the camera in the world frame when the camera is started.
### variable enableAreaMemory
```csharp
bool enableAreaMemory = true;
```
Whether the camera can remember its surroundings.
**Warning**:
* This mode requires more resources to run, but greatly improves tracking accuracy.
* We recommend leaving it on by default.
This helps correct positional tracking drift and can be helpful for positioning different cameras relative to one other in space.
### variable enablePoseSmothing
```csharp
bool enablePoseSmothing = false;
```
Whether to enable smooth pose correction for small drift correction.
### variable setFloorAsOrigin
```csharp
bool setFloorAsOrigin = false;
```
Initializes the tracking to be aligned with the floor plane to better position the camera in space.
**Note**:
* This launches floor plane detection in the background until a suitable floor plane is found.
* The tracking will start in sl.POSITIONAL_TRACKING_STATE.SEARCHING state.
**Warning**:
* This features does not work with sl.MODEL.ZED since it needs an IMU to classify the floor.
* The camera needs to look at the floor during initialization for optimum results.
### variable setAsStatic
```csharp
bool setAsStatic = false;
```
Whether to define the camera as static.
If true, it will not move in the environment. This allows you to set its position using initialWorldPosition and initialWorldRotation.
All ZED SDK functionalities requiring positional tracking will be enabled without additional computation.
sl.Camera.GetPosition() will return the values set as initialWorldPosition and initialWorldRotation.
### variable enableIMUFusion
```csharp
bool enableIMUFusion = true;
```
Whether to enable the IMU fusion.
**Note**:
* This setting has no impact on the tracking of a camera.
* sl.MODEL.ZED does not have an IMU.
When set to false, only the optical odometry will be used.
### variable depthMinRange
```csharp
float depthMinRange = -1f;
```
Minimum depth used by the ZED SDK for positional tracking.
It may be useful for example if any steady objects are in front of the camera and may perturb the positional tracking algorithm.
Default: -1 (no minimum depth)
### variable setGravityAsOrigin
```csharp
bool setGravityAsOrigin = true;
```
Whether to override 2 of the 3 components from initialWorldRotation using the IMU gravity.
**Note**: This parameter does nothing on sl.ZED.MODEL since it does not have an IMU.
### variable areaFilePath
```csharp
string areaFilePath = "";
```
Path of an area localization file that describes the surroundings (saved from a previous tracking session).
**Note**: Loading an area file will start a search phase, during which the camera will try to position itself in the previously learned area.
**Warning**:
* The area file describes a specific location. If you are using an area file describing a different location, the tracking function will continuously search for a position and may not find a correct one.
* The '.area' file can only be used with the same depth mode (sl.DEPTH_MODE) as the one used during area recording.
### variable mode
```csharp
sl.POSITIONAL_TRACKING_MODE mode = sl.POSITIONAL_TRACKING_MODE.GEN_3;
```
Positional tracking mode used.
Can be used to improve accuracy in some types of scene at the cost of longer runtime.
### variable enableLocalizationOnly
```csharp
bool enableLocalizationOnly;
```
Whether to enable the area mode in localize only mode.
### variable enable2DGroundMode
```csharp
bool enable2DGroundMode;
```
Whether to enable the 2D ground mode.
---
# sl::RecordingParameters
**Module:** **Video Module**
Structure containing the options used to record. More...
## Detailed Description
```csharp
struct sl::RecordingParameters;
```
Structure containing the options used to record.
**Note**: For more info, read about the ZED SDK C++ class it mirrors: [RecordingParameters](https://www.stereolabs.com/docs/api/structsl_1_1RecordingParameters.html)
## Public Functions Documentation
### function RecordingParameters
```csharp
RecordingParameters(
string filename ="",
SVO_COMPRESSION_MODE compression =SVO_COMPRESSION_MODE.H264_BASED,
uint bitrate =0,
int fps =0,
bool transcode =false,
string encryptionKey ="",
SVO_ENCODING_PRESET encodingPreset =SVO_ENCODING_PRESET.DEFAULT
)
```
Default constructor.
All the parameters are set to their default values.
## Public Attributes Documentation
### variable videoFilename
```csharp
string videoFilename;
```
Filename of the file to save the recording into.
### variable compressionMode
```csharp
SVO_COMPRESSION_MODE compressionMode;
```
Compression mode the recording.
Default: sl.SVO_COMPRESSION_MODE.H264_BASED
### variable targetFPS
```csharp
int targetFPS;
```
Framerate for the recording file.
**Warning**:
* This framerate must be below or equal to the camera framerate and camera framerate must be a multiple of the target framerate.
* It means that it must respect ` cameraFPStargetFPS == 0`.
* Allowed framerates are 15,30, 60 or 100 if possible.
* Any other values will be discarded and camera FPS will be taken.
Default: 0 (camera framerate will be taken)
### variable bitrate
```csharp
uint bitrate;
```
Overrides the default bitrate of the SVO file, in kbits/s.
**Note**:
* Only works if compressionMode is sl.SVO_COMPRESSION_MODE.H264_BASED or sl.SVO_COMPRESSION_MODE.H265_BASED.
* Available range: 0 or [1000 - 60000]
Default: 0 (the default values associated with the resolution)
### variable transcode
```csharp
bool transcode;
```
Defines whether to decode and re-encode a streaming source.
**Note**:
* If set to false, it will avoid decoding/re-encoding and convert directly streaming input into a SVO file.
* This saves a encoding session and can be especially useful on NVIDIA Geforce cards where the number of encoding session is limited.
* compressionMode, targetFPS and bitrate will be ignored in this mode.
Default: false
### variable encryptionKey
```csharp
string encryptionKey;
```
Optional encryption key or passphrase to protect the SVO file (AES-256-CTR).
When set, the SVO file is encrypted on the fly during recording. The same value must be provided in sl.InitParameters.svoDecryptionKey for playback.
Default: "" (no encryption)
### variable encodingPreset
```csharp
SVO_ENCODING_PRESET encodingPreset;
```
Encoding preset for the hardware encoder.
**Note**: Only applicable when compressionMode is H264 or H265.
Controls the speed/quality tradeoff of the GPU encoder. Default: sl.SVO_ENCODING_PRESET.DEFAULT
---
# sl::StreamingParameters
**Module:** **Video Module**
Structure containing the options used to stream with the ZED SDK. More...
## Detailed Description
```csharp
struct sl::StreamingParameters;
```
Structure containing the options used to stream with the ZED SDK.
**Note**: For more info, read about the ZED SDK C++ class it mirrors: [StreamingParameters](https://www.stereolabs.com/docs/api/structsl_1_1StreamingParameters.html)
## Public Functions Documentation
### function StreamingParameters
```csharp
StreamingParameters(
STREAMING_CODEC codec =STREAMING_CODEC.H264_BASED,
ushort port =3000,
uint bitrate =8000,
int gopSize =-1,
bool adaptativeBitrate =false,
ushort chunkSize =32789,
int targetFPS =0
)
```
Default constructor.
All the parameters are set to their default values.
## Public Attributes Documentation
### variable codec
```csharp
STREAMING_CODEC codec;
```
Encoding used for streaming.
### variable port
```csharp
ushort port;
```
Port used for streaming.
**Warning**:
* Port must be an even number. Any odd number will be rejected.
* Port must be opened.
### variable bitrate
```csharp
uint bitrate;
```
Defines the streaming bitrate in Kbits/s.
**Note**: Available range: [1000 - 60000]
| sl.STREAMING_CODEC | sl.RESOLUTION | FPS | Bitrate (kbps) |
| -------- | -------- | -------- | -------- |
| H264 | HD2K | 15 | 8500 |
| H264 | HD1080 | 30 | 12500 |
| H264 | HD720 | 60 | 7000 |
| H265 | HD2K | 15 | 7000 |
| H265 | HD1080 | 30 | 11000 |
| H265 | HD720 | 60 | 6000 |
Default: 0 (it will be set to the best value depending on your resolution/FPS)
### variable gopSize
```csharp
int gopSize;
```
GOP size in number of frames.
**Note**:
* The GOP size determines the maximum distance between IDR/I-frames. Very high GOP size will result in slightly more efficient compression, especially on static scenes. But latency will increase.
* Maximum value: 256
Default: -1 (the GOP size will last at maximum 2 seconds, depending on camera FPS)
### variable adaptativeBitrate
```csharp
bool adaptativeBitrate;
```
Defines whether the adaptive bitrate is enable.
**Note**:
* Bitrate will be adjusted depending the number of packet dropped during streaming.
* If activated, the bitrate can vary between [bitrate/4, bitrate].
**Warning**: Currently, the adaptive bitrate only works when "sending" device is a NVIDIA Jetson (X1, X2, Xavier, Nano).
Default: false
### variable chunkSize
```csharp
ushort chunkSize;
```
Size of a single chunk.
**Note**:
* Stream buffers are divided into X number of chunks where each chunk is chunkSize bytes long.
* You can lower chunkSize value if network generates a lot of packet lost: this will generates more chunk for a single image, but each chunk sent will be lighter to avoid inside-chunk corruption.
* Increasing this value can decrease latency.
* Available range: [1024 - 65000]
Default: 16084
### variable targetFPS
```csharp
int targetFPS;
```
Framerate for the streaming output.
**Warning**:
* This framerate must be below or equal to the camera framerate.
* Allowed framerates are 15, 30, 60 or 100 if possible.
* Any other values will be discarded and camera FPS will be taken.
Default: 0 (camera framerate will be taken)
---
# sl::ObjectDetectionParameters
**Module:** **Object Detection Module**
Structure containing a set of parameters for the object detection module. More...
## Detailed Description
```csharp
struct sl::ObjectDetectionParameters;
```
Structure containing a set of parameters for the object detection module.
**Note**: Parameters can be user adjusted.
The default constructor sets all parameters to their default settings.
## Public Attributes Documentation
### variable instanceModuleId
```csharp
uint instanceModuleId;
```
Id of the module instance.
This is used to identify which object detection module instance is used.
### variable enableObjectTracking
```csharp
bool enableObjectTracking;
```
Whether the object detection system includes object tracking capabilities across a sequence of images.
Default: true
### variable enableSegmentation
```csharp
bool enableSegmentation;
```
Whether the object masks will be computed.
Default: false
### variable detectionModel
```csharp
sl.OBJECT_DETECTION_MODEL detectionModel;
```
sl.OBJECT_DETECTION_MODEL to use.
Default: sl.OBJECT_DETECTION_MODEL.MULTI_CLASS_BOX_FAST
### variable maxRange
```csharp
float maxRange;
```
Upper depth range for detections.
**Note**: The value cannot be greater than sl.InitParameters.depthMaximumDistance and its unit is defined in sl.InitParameters.coordinateUnits.
Default: -1 (value set in sl.InitParameters.depthMaximumDistance)
### variable batchParameters
```csharp
BatchParameters batchParameters;
```
Batching system parameters.
Batching system (introduced in 3.5) performs short-term re-identification with deep-learning and trajectories filtering.
sl.BatchParameters.enable must to be true to use this feature (by default disabled).
### variable filteringMode
```csharp
OBJECT_FILTERING_MODE filteringMode;
```
Filtering mode that should be applied to raw detections.
**Note**:
* This parameter is only used in detection model sl.OBJECT_DETECTION_MODEL.MULTI_CLASS_BOX_XXX and sl.OBJECT_DETECTION_MODEL.CUSTOM_BOX_OBJECTS.
* For custom object, it is recommended to use sl.OBJECT_FILTERING_MODE.NMS3D_PER_CLASS or sl.OBJECT_FILTERING_MODE.NONE.
* In this case, you might need to add your own NMS filter before ingesting the boxes into the object detection module.
Default: sl.OBJECT_FILTERING_MODE.NMS3D (same behavior as previous ZED SDK version)
### variable predictionTimeout_s
```csharp
float predictionTimeout_s;
```
Prediction duration of the ZED SDK when an object is not detected anymore before switching its state to sl.OBJECT_TRACKING_STATE.SEARCHING.
**Note**:
* During this time, the object will have sl.OBJECT_TRACKING_STATE.OK state even if it is not detected.
* The duration is expressed in seconds.
**Warning**:
* predictionTimeout_s will be clamped to 1 second as the prediction is getting worse with time.
* Setting this parameter to 0 disables the ZED SDK predictions.
It prevents the jittering of the object state when there is a short misdetection.
The user can define their own prediction time duration.
Default: 0.2f
### variable allowReducedPrecisionInference
```csharp
bool allowReducedPrecisionInference;
```
Whether to allow inference to run at a lower precision to improve runtime and memory usage.
**Note**:
* The fp16 is automatically enabled if the GPU is compatible and provides a speed up of almost x2 and reduce memory usage by almost half, no precision loss.
* This setting allow int8 precision which can speed up by another x2 factor (compared to fp16, or x4 compared to fp32) and half the fp16 memory usage, however some accuracy could be lost.
* The accuracy loss should not exceed 1-2% on the compatible models.
* The current compatible models are all sl.AI_MODELS.HUMAN_BODY_XXXX.
It might increase the initial optimization time and could include downloading calibration data or calibration cache and slightly reduce the accuracy.
---
# sl::BodyTrackingParameters
**Module:** **Body Tracking Module**
Structure containing a set of parameters for the body tracking module. More...
## Detailed Description
```csharp
struct sl::BodyTrackingParameters;
```
Structure containing a set of parameters for the body tracking module.
**Note**: Parameters can be user adjusted.
The default constructor sets all parameters to their default settings.
## Public Attributes Documentation
### variable instanceModuleId
```csharp
uint instanceModuleId;
```
Id of the module instance.
This is used to identify which body tracking module instance is used.
### variable enableObjectTracking
```csharp
bool enableObjectTracking;
```
Whether the body tracking system includes body/person tracking capabilities across a sequence of images.
Default: true
### variable enableSegmentation
```csharp
bool enableSegmentation;
```
Whether the body/person masks will be computed.
Default: false
### variable detectionModel
```csharp
sl.BODY_TRACKING_MODEL detectionModel;
```
sl.BODY_TRACKING_MODEL to use.
Default: sl.BODY_TRACKING_MODEL.HUMAN_BODY_ACCURATE
### variable enableBodyFitting
```csharp
bool enableBodyFitting;
```
Whether to apply the body fitting.
Default: false
### variable bodyFormat
```csharp
sl.BODY_FORMAT bodyFormat;
```
Body format to be outputted by the ZED SDK with sl.Camera.RetrieveBodies().
### variable bodySelection
```csharp
sl.BODY_KEYPOINTS_SELECTION bodySelection;
```
Selection of keypoints to be outputted by the ZED SDK with sl_retrieve_bodies().
Default: SL_BODY_KEYPOINTS_SELECTION_FULL
### variable maxRange
```csharp
float maxRange;
```
Upper depth range for detections.
**Note**: The value cannot be greater than sl.InitParameters.depthMaximumDistance and its unit is defined in sl.InitParameters.coordinateUnits.
Default: -1 (value set in sl.InitParameters.depthMaximumDistance)
### variable predictionTimeout_s
```csharp
float predictionTimeout_s;
```
Prediction duration of the ZED SDK when an object is not detected anymore before switching its state to sl.OBJECT_TRACKING_STATE.SEARCHING.
**Note**:
* During this time, the object will have sl.OBJECT_TRACKING_STATE.OK state even if it is not detected.
* The duration is expressed in seconds.
**Warning**:
* predictionTimeout_s will be clamped to 1 second as the prediction is getting worse with time.
* Setting this parameter to 0 disables the ZED SDK predictions.
It prevents the jittering of the object state when there is a short misdetection.
The user can define their own prediction time duration.
Default: 0.2f
### variable allowReducedPrecisionInference
```csharp
bool allowReducedPrecisionInference;
```
Whether to allow inference to run at a lower precision to improve runtime and memory usage.
**Note**:
* The fp16 is automatically enabled if the GPU is compatible and provides a speed up of almost x2 and reduce memory usage by almost half, no precision loss.
* This setting allow int8 precision which can speed up by another x2 factor (compared to fp16, or x4 compared to fp32) and half the fp16 memory usage, however some accuracy could be lost.
* The accuracy loss should not exceed 1-2% on the compatible models.
* The current compatible models are all sl.AI_MODELS.HUMAN_BODY_XXXX.
It might increase the initial optimization time and could include downloading calibration data or calibration cache and slightly reduce the accuracy.
---
# GNSS_STATUS
**Module:** **Positional Tracking Module**
Class representing the fix quality of GNSS signal.
---
# sl::FusedPointCloud
A fused point cloud contains both geometric and color data of the scene captured by spatial mapping.
## Public Attributes Documentation
### variable vertices
```csharp
Vector4[] vertices;
```
Array of vertices.
Vertices are defined by colored 3D points `{x, y, z, rgba}`.
---
# sl::Fusion
**Module:** **Fusion Module**
Holds Fusion process data and functions
## Public Classes
| | Name |
| -------------- | -------------- |
| struct | **sl_GNSSCalibrationParameters**
DLL-friendly version of GNSSCalibrationParameters (found in ZEDCommon.cs). |
| struct | **sl_PositionalTrackingFusionParameters**
DLL-friendly version of PositionalTrackingFusionParameters (found in ZEDCommon.cs). |
## Public Functions Documentation
### function Close
```csharp
void Close()
```
### function ReadFusionConfiguration
```csharp
void ReadFusionConfiguration(
System.Text.StringBuilder fusionConfiguration,
COORDINATE_SYSTEM coordinateSystem,
UNIT unit,
ref FusionConfiguration[] configs,
ref int nbCameras
)
```
Read a Configuration JSON string to configure a fusion process.
**Parameters**:
* **fusionConfiguration** The name of the JSON file containing the configuration.
* **coordinateSystem** The COORDINATE_SYSTEM in which you want the World Pose to be in.
* **unit** The UNIT in which you want the World Pose to be in.
* **configs** An array of FusionConfiguration for all the camera present in the file of size Constant.MAX_FUSED_CAMERAS.
* **nbCameras** Number of cameras
### function GetSenderState
```csharp
SENDER_ERROR_CODE GetSenderState(
ref CameraIdentifier uuid
)
```
Returns the state of a connected data sender.
**Parameters**:
* **uuid** Identifier of the camera.
**Return**: State of the sender
### function Init
```csharp
FUSION_ERROR_CODE Init(
ref InitFusionParameters initFusionParameters
)
```
FusionHandler initialisation. Initializes memory/generic datas
**Parameters**:
* **initFusionParameters**
**Return**:
### function Process
```csharp
FUSION_ERROR_CODE Process()
```
processes the fusion.
**Return**:
### function Subscribe
```csharp
FUSION_ERROR_CODE Subscribe(
ref CameraIdentifier uuid,
CommunicationParameters communicationParameters,
ref Vector3 poseTranslation,
ref System.Numerics.Quaternion poseRotation
)
```
adds a camera to the multi camera handler
**Parameters**:
* **uuid** The requested camera identifier.
* **communicationParameters** The communication parameters to connect to the camera..
* **poseTranslation** The World position of the camera, regarding the other camera of the setup.
* **poseRotation** The World rotation of the camera, regarding the other camera of the setup.
**Return**:
### function Unsubscribe
```csharp
FUSION_ERROR_CODE Unsubscribe(
ref CameraIdentifier uuid
)
```
Remove the specified camera from data provider.
**Parameters**:
* **uuid** The requested camera identifier.
**Return**: FUSION_ERROR_CODE "SUCCESS" if it goes as it should, otherwise it returns an FUSION_ERROR_CODE.
### function UpdatePose
```csharp
FUSION_ERROR_CODE UpdatePose(
ref CameraIdentifier uuid,
ref Vector3 poseTranslation,
ref System.Numerics.Quaternion poseRotation
)
```
updates the camera World pose
**Parameters**:
* **uuid** The requested camera identifier.
* **poseTranslation** The World position of the camera, regarding the other camera of the setup.
* **poseRotation** The World rotation of the camera, regarding the other camera of the setup.
**Return**:
### function GetPose
```csharp
FUSION_ERROR_CODE GetPose(
ref CameraIdentifier uuid,
ref Vector3 poseTranslation,
ref System.Numerics.Quaternion poseRotation
)
```
Get the specified camera position inside fusion WORLD
**Parameters**:
* **uuid**
* **poseTranslation**
* **poseRotation**
**Return**:
### function RetrieveImage
```csharp
FUSION_ERROR_CODE RetrieveImage(
Mat mat,
ref CameraIdentifier uuid,
Resolution resolution =new sl.Resolution()
)
```
Returns the current sl.VIEW.LEFT of the specified camera, the data is synchronized.
**Parameters**:
* **mat** the CPU BGRA image of the requested camera.
* **uuid** the requested camera identifier.
* **resolution** the requested resolution of the output image, can be lower or equal (default) to the original image resolution.
**Return**: FUSION_ERROR_CODE "SUCCESS" if it goes as it should, otherwise it returns an FUSION_ERROR_CODE.
### function RetrieveMeasure
```csharp
FUSION_ERROR_CODE RetrieveMeasure(
Mat mat,
ref CameraIdentifier uuid,
MEASURE measure =MEASURE.DEPTH,
Resolution resolution =new sl.Resolution(),
FUSION_REFERENCE_FRAME referenceFrame =FUSION_REFERENCE_FRAME.BASELINK
)
```
Returns the current measure of the specified camera, the data is synchronized.
**Parameters**:
* **mat** the CPU data of the requested camera.
* **uuid** the requested camera identifier.
* **type** the requested measure type, by default DEPTH (F32_C1)
* **resolution** the requested resolution of the output image, can be lower or equal (default) to the original image resolution.
**Return**: FUSION_ERROR_CODE "SUCCESS" if it goes as it should, otherwise it returns an FUSION_ERROR_CODE.
Only MEASURE: DEPTH, XYZ, XYZRGBA, XYZBGRA, XYZARGB, XYZABGR, DEPTH_U16_MM are available.
### function EnableBodyTracking
```csharp
FUSION_ERROR_CODE EnableBodyTracking(
ref BodyTrackingFusionParameters btfParams
)
```
enables the body tracking module
**Parameters**:
* **btfParams**
**Return**:
### function DisableBodyTracking
```csharp
void DisableBodyTracking()
```
disable the body tracking module
### function RetrieveBodies
```csharp
FUSION_ERROR_CODE RetrieveBodies(
ref Bodies bodies,
ref BodyTrackingFusionRuntimeParameters rtparams,
CameraIdentifier uuid,
FUSION_REFERENCE_FRAME referenceFrame =FUSION_REFERENCE_FRAME.BASELINK
)
```
retrieves the body data, can be the fused data (default), or the raw data provided by a specific sender
**Parameters**:
* **bodies**
* **rtparams**
* **uuid**
**Return**:
### function GetProcessMetrics
```csharp
FUSION_ERROR_CODE GetProcessMetrics(
ref FusionMetrics metrics
)
```
gets the metrics of the Fusion process, for the fused data as well as individual camera provider data
**Parameters**:
* **metrics**
**Return**:
### function EnablePositionalTracking
```csharp
FUSION_ERROR_CODE EnablePositionalTracking(
ref PositionalTrackingFusionParameters ptfParams
)
```
enables positional tracking module
**Parameters**:
* **ptfParams**
**Return**:
### function GetPosition
```csharp
POSITIONAL_TRACKING_STATE GetPosition(
ref Pose pose,
REFERENCE_FRAME referenceFrame,
ref CameraIdentifier uuid,
POSITION_TYPE retrieveType
)
```
Gets the Fused Position of the camera system
**Parameters**:
* **pose** contains the camera pose in world position (world position is given by the calibration of the cameras system)
* **referenceFrame** defines the reference from which you want the pose to be expressed. Default : REFERENCE_FRAME::WORLD.
* **coordinateSystem**
* **unit**
* **uuid**
* **retrieveType**
**Return**:
### function GetFusedPositionalTrackingStatus
```csharp
FusedPositionalTrackingStatus GetFusedPositionalTrackingStatus()
```
Gets the current status of fused position.
**Return**: The current status of the tracking process.
### function DisablePositionalTracking
```csharp
void DisablePositionalTracking()
```
Disables the positional tracking
### function IngestGNSSData
```csharp
FUSION_ERROR_CODE IngestGNSSData(
ref GNSSData data,
bool radian
)
```
ingests GNSS data from an external sensor into the fusion module
**Parameters**:
* **data** the current GNSS data to combine with the current positional tracking data
### function GetCurrentGNSSData
```csharp
POSITIONAL_TRACKING_STATE GetCurrentGNSSData(
ref GNSSData data,
bool radian
)
```
returns the current GNSS data
**Parameters**:
* **data** the current GNSS data
**Return**:
### function GetGeoPose
```csharp
GNSS_FUSION_STATUS GetGeoPose(
ref GeoPose pose,
bool radian
)
```
returns the current GeoPose
**Parameters**:
* **pose** the current GeoPose
**Return**:
### function GeoToCamera
```csharp
GNSS_FUSION_STATUS GeoToCamera(
ref LatLng inLatLng,
out Pose outPose
)
```
Converts latitude / longitude into position in sl::Fusion coordinate system.
**Parameters**:
* **inLatLng**
* **outPose**
**Return**:
### function CameraToGeo
```csharp
GNSS_FUSION_STATUS CameraToGeo(
ref Pose inPose,
out GeoPose outGeoPose,
bool radian
)
```
Converts a position in sl::Fusion coordinate system in real world coordinate.
**Parameters**:
* **inPose**
* **outGeoPose**
**Return**:
### function EnuToGeo
```csharp
FUSION_ERROR_CODE EnuToGeo(
ref ENU inPose,
out LatLng outPose,
bool radian
)
```
Converts a position in ENU coordinate system into latitude / longitude.
**Parameters**:
* **inPose**
* **outPose**
**Return**:
### function GeoToEnu
```csharp
FUSION_ERROR_CODE GeoToEnu(
ref LatLng inPose,
out ENU outPose,
bool radian
)
```
Converts a position in latitude / longitude into ENU coordinate system.
**Parameters**:
* **inPose**
* **outPose**
**Return**:
### function GetCurrentTimeStamp
```csharp
ulong GetCurrentTimeStamp()
```
Gets the current timestamp.
**Return**:
### function GetCurrentGNSSCalibrationStd
```csharp
GNSS_FUSION_STATUS GetCurrentGNSSCalibrationStd(
ref float yawStd,
ref Vector3 positionStd
)
```
Get the current calibration uncertainty defined during calibration process
**Parameters**:
* **yawStd** yaw uncertainty
* **positionStd** position uncertainty
**Return**:
### function GetGeoTrackingCalibration
```csharp
void GetGeoTrackingCalibration(
ref Vector3 position,
ref System.Numerics.Quaternion rotation
)
```
Get the calibration found between VIO and GNSS
**Parameters**:
* **position** calibration found between VIO and GNSS (Translation)
* **rotation** calibration found between VIO and GNSS (Rotation)
### function ReadConfigurationFile
```csharp
static List< FusionConfiguration > ReadConfigurationFile(
System.Text.StringBuilder jsonConfigFileName,
COORDINATE_SYSTEM coordinateSystem,
UNIT unit
)
```
Read a Configuration JSON file to configure a fusion process.
**Parameters**:
* **jsonConfigFileName** The name of the JSON file containing the configuration.
* **coordinateSystem** The COORDINATE_SYSTEM in which you want the World Pose to be in.
* **unit** The UNIT in which you want the World Pose to be in.
**Return**: A List of FusionConfiguration for all the camera present in the file.
---
# sl::GNSSCalibrationParameters
**Module:** **Fusion Module**
Holds the options used for calibrating GNSS / VIO.
## Public Functions Documentation
### function GNSSCalibrationParameters
```csharp
GNSSCalibrationParameters(
float targetYawUncertainty_ =0.1f,
bool enableTranslationUncertaintyTarget_ =false,
float targetTranslationUncertainty_ =0.01f,
bool enableReinitialization_ =true,
float gnssVioReinitThreshold_ =5,
bool enableRollingCalibration_ =true,
Vector3 gnssAntennaPosition_ =default(Vector3)
) =default
```
## Public Attributes Documentation
### variable targetYawUncertainty
```csharp
float targetYawUncertainty = 0.1f;
```
This parameter defines the target yaw uncertainty at which the calibration process between GNSS and VIO concludes. The unit of this parameter is in radian.
Default: 0.1 radians
### variable enableTranslationUncertaintyTarget
```csharp
bool enableTranslationUncertaintyTarget = false;
```
When this parameter is enabled (set to true), the calibration process between GNSS and VIO accounts for the uncertainty in the determined translation, thereby facilitating the calibration termination. The maximum allowable uncertainty is controlled by the 'target_translation_uncertainty' parameter.
Default: false
### variable targetTranslationUncertainty
```csharp
float targetTranslationUncertainty = 10e-2f;
```
This parameter defines the target translation uncertainty at which the calibration process between GNSS and VIO concludes.
Default: 10e-2 (10 centimeters)
### variable enableReinitialization
```csharp
bool enableReinitialization = true;
```
This parameter determines whether reinitialization should be performed between GNSS and VIO fusion when a significant disparity is detected between GNSS data and the current fusion data. It becomes particularly crucial during prolonged GNSS signal loss scenarios.
Default: true
### variable gnssVioReinitThreshold
```csharp
float gnssVioReinitThreshold = 5;
```
This parameter determines the threshold for GNSS/VIO reinitialization. If the fused position deviates beyond out of the region defined by the product of the GNSS covariance and the gnss_vio_reinit_threshold, a reinitialization will be triggered.
Default: 5
### variable enableRollingCalibration
```csharp
bool enableRollingCalibration = true;
```
If this parameter is set to true, the fusion algorithm will used a rough VIO / GNSS calibration at first and then refine it. This allow you to quickly get a fused position.
Default: true
### variable gnssAntennaPosition
```csharp
Vector3 gnssAntennaPosition = Vector3.Zero;
```
Define a transform between the GNSS antenna and the camera system for the VIO / GNSS calibration. Default value is [0,0,0], this position can be refined by the calibration if enabled
---
# sl::Mesh
**Module:** **Spatial Mapping Module**
Class representing a mesh and containing the geometric (and optionally texture) data of the scene captured by the spatial mapping module. More...
## Detailed Description
```csharp
class sl::Mesh;
```
Class representing a mesh and containing the geometric (and optionally texture) data of the scene captured by the spatial mapping module.
By default the mesh is defined as a set of chunks.
This way we update only the data that has to be updated avoiding a time consuming remapping process every time a small part of the sl.Mesh is updated.
## Public Attributes Documentation
### variable nbVerticesInSubmesh
```csharp
int[] nbVerticesInSubmesh = new int[(int)Constant.MAX_SUBMESH];
```
Number of vertices per chunk/sub-mesh.
### variable nbTrianglesInSubmesh
```csharp
int[] nbTrianglesInSubmesh = new int[(int)Constant.MAX_SUBMESH];
```
Number of triangles per chunk/sub-mesh.
### variable updatedIndices
```csharp
int[] updatedIndices = new int[(int)Constant.MAX_SUBMESH];
```
Number of indices per chunk/sub-mesh.
### variable nbVertices
```csharp
int nbVertices = 0;
```
Vertices count in current sub-mesh.
### variable nbTriangles
```csharp
int nbTriangles = 0;
```
Triangle count in current sub-mesh.
Every three values of triangles are the indexes of the three vertices constituting a triangular face.
### variable nbUpdatedSubmesh
```csharp
int nbUpdatedSubmesh = 0;
```
Number of updated sub-meshes.
### variable vertices
```csharp
Vector3[] vertices = new Vector3[(int)Constant.MAX_SUBMESH];
```
Vector of vertices.
### variable triangles
```csharp
int[] triangles = new int[(int)Constant.MAX_SUBMESH];
```
Vector of of triangles/faces.
Triangles are defined as a set of three vertices indexes `{v1, v2, v3}`.
### variable colors
```csharp
byte[] colors = new byte[(int)Constant.MAX_SUBMESH];
```
Vector of colors.
### variable uvs
```csharp
Vector2[] uvs = null;
```
UVs defines the 2D projection of each vertices onto the texture.
Values are normalized [0, 1] and start from the bottom left corner of the texture (as requested by OpenGL). In order to display a textured mesh you need to bind the texture and then draw each triangle by picking its uv values.
### variable textures
```csharp
IntPtr textures = IntPtr.Zero;
```
Texture of the sl.Mesh.
### variable texturesSize
```csharp
int[] texturesSize = new int[2];
```
Width and height of the sl.Mesh texture, if any.
### variable chunks
```csharp
Dictionary< int, Chunk > chunks = new Dictionary((int)Constant.MAX_SUBMESH);
```
Dictionary of all existing chunks.
---
# sl::ObjectsBatch
**Module:** **Object Detection Module**
Class containing batched data of a detected objects from the object detection module. More...
## Detailed Description
```csharp
class sl::ObjectsBatch;
```
Class containing batched data of a detected objects from the object detection module.
This class can be used to store trajectories.
## Public Attributes Documentation
### variable numData
```csharp
int numData = 0;
```
Number of objects in the sl.ObjectsBatch.
**Note**: Objects with greater indexes are empty.
Use this to iterate through the top of positions / velocities / boundingBoxes / etc.
### variable id
```csharp
int id = 0;
```
Id of the batch.
### variable label
```csharp
OBJECT_CLASS label = OBJECT_CLASS.LAST;
```
Objects class/category to identify the object type.
### variable sublabel
```csharp
OBJECT_SUBCLASS sublabel = OBJECT_SUBCLASS.LAST;
```
Objects sub-class/sub-category to identify the object type.
### variable trackingState
```csharp
OBJECT_TRACKING_STATE trackingState = OBJECT_TRACKING_STATE.TERMINATE;
```
Objects tracking state.
### variable positions
```csharp
Vector3[] positions = new Vector3[(int)Constant.MAX_BATCH_SIZE];
```
Array of positions for each object.
### variable positionCovariances
```csharp
float[,] positionCovariances = new float[(int)Constant.MAX_BATCH_SIZE, 6];
```
Array of positions' covariances for each object.
### variable velocities
```csharp
Vector3[] velocities = new Vector3[(int)Constant.MAX_BATCH_SIZE];
```
Array of 3D velocities for each object.
### variable timestamps
```csharp
ulong[] timestamps = new ulong[(int)Constant.MAX_BATCH_SIZE];
```
Array of timestamps for each object.
### variable boundingBoxes
```csharp
Vector3[,] boundingBoxes = new Vector3[(int)Constant.MAX_BATCH_SIZE, 8];
```
Array of 3D bounding boxes for each object.
**Note**: They are defined in sl.InitParameters.coordinateUnits and expressed in sl.RuntimeParameters.measure3DReferenceFrame.
```cpp
1 ------ 2
/ /|
0 ------ 3 |
| Object | 6
| |/
4 ------ 7
```
### variable boundingBoxes2D
```csharp
Vector2[,] boundingBoxes2D = new Vector2[(int)Constant.MAX_BATCH_SIZE, 4];
```
Array of 2D bounding boxes for each object.
**Note**: Expressed in pixels on the original image resolution, `[0, 0]` is the top left corner.
```cpp
A ------ B
| Object |
D ------ C
```
### variable confidences
```csharp
float[] confidences = new float[(int)Constant.MAX_BATCH_SIZE];
```
Array of confidences for each object.
### variable actionStates
```csharp
OBJECT_ACTION_STATE[] actionStates = new OBJECT_ACTION_STATE[(int)Constant.MAX_BATCH_SIZE];
```
Array of action states for each object.
### variable headBoundingBoxes2D
```csharp
Vector2[,] headBoundingBoxes2D = new Vector2[(int)Constant.MAX_BATCH_SIZE, 8];
```
Array of 2D bounding box of the head for each object (person).
**Note**: Expressed in pixels on the original image resolution, `[0, 0]` is the top left corner.
**Warning**: Not available with sl.OBJECT_DETECTION_MODEL.MULTI_CLASS_BOX_XXX.
### variable headBoundingBoxes
```csharp
Vector3[,] headBoundingBoxes = new Vector3[(int)Constant.MAX_BATCH_SIZE, 8];
```
Array of 3D bounding box of the head for each object (person).
**Note**: They are defined in sl.InitParameters.coordinateUnits and expressed in sl.RuntimeParameters.measure3DReferenceFrame.
**Warning**: Not available with sl.OBJECT_DETECTION_MODEL.MULTI_CLASS_BOX_XXX.
### variable headPositions
```csharp
Vector3[] headPositions = new Vector3[(int)Constant.MAX_BATCH_SIZE];
```
Array of 3D centroid of the head for each object (person).
**Note**: They are defined in sl.InitParameters.coordinateUnits and expressed in sl.RuntimeParameters.measure3DReferenceFrame.
**Warning**: Not available with sl.OBJECT_DETECTION_MODEL.MULTI_CLASS_BOX_XXX.
---
# sl::PlaneDetectionParameters
**Module:** **Spatial Mapping Module**
Class containing a set of parameters for the plane detection functionality. More...
## Detailed Description
```csharp
class sl::PlaneDetectionParameters;
```
Class containing a set of parameters for the plane detection functionality.
**Note**: Parameters can be adjusted by the user.
The default constructor sets all parameters to their default settings.
## Public Attributes Documentation
### variable maxDistanceThreshold
```csharp
float maxDistanceThreshold = 0.15f;
```
Controls the spread of plane by checking the position difference.
Default: 0.15 meters
### variable normalSimilarityThreshold
```csharp
float normalSimilarityThreshold = 15.0f;
```
Controls the spread of plane by checking the angle difference.
Default: 15 degrees
---
# sl::PositionalTrackingFusionParameters
**Module:** **Fusion Module**
Holds the options used for initializing the positional tracking fusion module.
## Public Functions Documentation
### function PositionalTrackingFusionParameters
```csharp
PositionalTrackingFusionParameters()
```
Constructor
## Public Attributes Documentation
### variable enableGNSSFusion
```csharp
bool enableGNSSFusion = false;
```
This attribute is responsible for enabling or not GNSS positional tracking fusion.
### variable gnssCalibrationParameters
```csharp
GNSSCalibrationParameters gnssCalibrationParameters;
```
Control the VIO / GNSS calibration process.
### variable baseFootprintToWorldTranslation
```csharp
Vector3 baseFootprintToWorldTranslation;
```
Position of the base footprint with respect to the user world.
### variable baseFootprintToWorldRotation
```csharp
Quaternion baseFootprintToWorldRotation;
```
Orientation of the base footprint with respect to the user world.
### variable baseFootprintToBaselinkTranslation
```csharp
Vector3 baseFootprintToBaselinkTranslation;
```
Position of the base footprint with respect to the baselink.
### variable baseFootprintToBaselinkRotation
```csharp
Quaternion baseFootprintToBaselinkRotation;
```
Orientation of the base footprint with respect to the baselink.
### variable SetGravityAsOrigin
```csharp
bool SetGravityAsOrigin;
```
Whether to override 2 of the 3 rotations from base_footprint_to_world_transform using the IMU gravity.
### variable trackingCameraID
```csharp
CameraIdentifier trackingCameraID;
```
ID of the camera used for positional tracking. If not specified, will use the first camera called with the subscribe() method.
---
# sl::SpatialMappingParameters
**Module:** **Spatial Mapping Module**
Class containing a set of parameters for the spatial mapping module. More...
## Detailed Description
```csharp
class sl::SpatialMappingParameters;
```
Class containing a set of parameters for the spatial mapping module.
**Note**: Parameters can be adjusted by the user.
The default constructor sets all parameters to their default settings.
## Public Functions Documentation
### function SpatialMappingParameters
```csharp
SpatialMappingParameters(
float resolutionMeter =0.05f,
float rangeMeter =0.0f,
bool saveTexture =false,
SPATIAL_MAP_TYPE map_type =SPATIAL_MAP_TYPE.MESH,
bool useChunkOnly =false,
int maxMemoryUsage =2048,
bool reverseVertexOrder =false,
int stabilityCounter =0
)
```
Default constructor.
Sets all parameters to their default and optimized values.
### function set
```csharp
void set(
MAPPING_RESOLUTION mappingResolution =MAPPING_RESOLUTION.MEDIUM
)
```
Sets the resolution to a sl.MAPPING_RESOLUTION preset.
**Parameters**:
* **mappingResolution** The desired sl.MAPPING_RESOLUTION. Default: sl.MAPPING_RESOLUTION.MEDIUM
### function set
```csharp
void set(
MAPPING_RANGE mappingRange =MAPPING_RANGE.MEDIUM
)
```
Sets the range to a sl.MAPPING_RANGE preset.
**Parameters**:
* **mappingRange** The desired sl.MAPPING_RANGE. Default: sl.MAPPING_RANGE.MEDIUM
### function get
```csharp
static float get(
MAPPING_RESOLUTION mappingResolution =MAPPING_RESOLUTION.MEDIUM
)
```
Returns the value corresponding to a sl.MAPPING_RESOLUTION preset in meters.
**Parameters**:
* **mappingResolution** The desired sl.MAPPING_RESOLUTION. Default: sl.MAPPING_RESOLUTION.MEDIUM
**Return**: The value of **mappingResolution** in meters.
### function get
```csharp
static float get(
MAPPING_RANGE mappingRange =MAPPING_RANGE.MEDIUM
)
```
Returns the value corresponding to a sl.MAPPING_RANGE preset in meters.
**Parameters**:
* **mappingRange** The desired sl.MAPPING_RANGE. Default: sl.MAPPING_RANGE.MEDIUM
**Return**: The value of **mappingRange** in meters.
## Public Attributes Documentation
### variable resolutionMeter
```csharp
float resolutionMeter = 0.05f;
```
Spatial mapping resolution in meters.
### variable rangeMeter
```csharp
float rangeMeter = 0.0f;
```
Depth range in meters.
**Note**: Set to 0 by default. In this case, the range is computed from resolutionMeter and from the current internal parameters to fit your application.
Can be different from the value set by sl.InitParameters.depthMaximumDistance.
### variable saveTexture
```csharp
bool saveTexture = false;
```
Whether to save the texture.
**Note**:
* This option will consume more memory.
* This option is only available for sl.SPATIAL_MAP_TYPE.MESH.
If set to true, you will be able to apply the texture to your mesh after it is created.
### variable useChunkOnly
```csharp
bool useChunkOnly = false;
```
Whether to only use chunks.
**Note**:
* Updating the mesh is time-consuming.
* Setting this to true results in better performance.
If set to false, you will ensure consistency between the mesh and its inner chunk data.
### variable maxMemoryUsage
```csharp
int maxMemoryUsage = 2048;
```
The maximum CPU memory (in MB) allocated for the meshing process.
### variable reverseVertexOrder
```csharp
bool reverseVertexOrder = false;
```
Whether to inverse the order of the vertices of the triangles.
**Note**: This option is only available for sl.SPATIAL_MAP_TYPE.MESH.
If your display process does not handle front and back face culling, you can use this to correct it.
### variable map_type
```csharp
SPATIAL_MAP_TYPE map_type = SPATIAL_MAP_TYPE.MESH;
```
The type of spatial map to be created. This dictates the format that will be used for the mapping(e.g. mesh, point cloud). See SPATIAL_MAP_TYPE
### variable stabilityCounter
```csharp
int stabilityCounter = 0;
```
Control the integration rate of the current depth into the mapping process.
This parameter controls how many times a stable 3D points should be seen before it is integrated into the spatial mapping.
Default: 0 (this will define the stability counter based on the mesh resolution, the higher the resolution, the higher the stability counter)
---
# sl::ZEDCommon
## Public Attributes Documentation
### variable NameDLL
```csharp
static const string NameDLL = "sl_zed_c";
```
---
# sl::AI_Model_status
Structure containing AI model status.
## Public Attributes Documentation
### variable downloaded
```csharp
bool downloaded;
```
The model file is currently present on the host.
### variable optimized
```csharp
bool optimized;
```
An engine file with the expected architecture is found.
---
# sl::BarometerData
**Module:** **Core Module**
Structure containing data from the barometer sensor.
## Public Attributes Documentation
### variable available
```csharp
bool available;
```
Whether the barometer sensor is available in your camera.
### variable timestamp
```csharp
ulong timestamp;
```
Data acquisition timestamp in nanoseconds.
### variable pressure
```csharp
float pressure;
```
Ambient air pressure in hectopascal (hPa).
### variable relativeAltitude
```csharp
float relativeAltitude;
```
Relative altitude from first camera position (at sl.Camera.Open() time).
---
# sl::BatchParameters
**Module:** **Object Detection Module**
Structure containing a set of parameters for batch object detection. More...
## Detailed Description
```csharp
struct sl::BatchParameters;
```
Structure containing a set of parameters for batch object detection.
**Note**: Parameters can be user adjusted.
The default constructor sets all parameters to their default settings.
## Public Attributes Documentation
### variable enable
```csharp
bool enable;
```
Whether to enable the batch option in the object detection module.
**Note**: To activate this option, enable must be set to true.
Batch queueing system provides:
* deep-learning based re-identification
* trajectory smoothing and filtering
Default: false
### variable idRetentionTime
```csharp
float idRetentionTime;
```
Max retention time in seconds of a detected object.
After this time, the same object will mostly have a different id.
### variable latency
```csharp
float latency;
```
Trajectories will be output in batch with the desired latency in seconds.
**Note**:
* Specifying a short latency will limit the search (falling in timeout) for previously seen object ids but will be closer to real time output.
* Specifying a long latency will reduce the change of timeout in re-identification but increase difference with live output.
During this waiting time, re-identification of objects is done in the background.
---
# sl::Bodies
**Module:** **Body Tracking Module**
Structure containing the results of the body tracking module. More...
## Detailed Description
```csharp
struct sl::Bodies;
```
Structure containing the results of the body tracking module.
The detected bodies/persons are listed in bodiesList.
## Public Attributes Documentation
### variable nbBodies
```csharp
int nbBodies;
```
Number of detected bodies/persons.
**Note**: You can use it to iterate through the bodiesList array.
### variable timestamp
```csharp
ulong timestamp;
```
Timestamp corresponding to the frame acquisition.
This value is especially useful for the async mode to synchronize the data.
### variable isNew
```csharp
int isNew;
```
Whether bodiesList has already been retrieved or not.
### variable isTracked
```csharp
int isTracked;
```
Whether both the body tracking and the world orientation has been setup.
### variable inferencePrecisionMode
```csharp
INFERENCE_PRECISION inferencePrecisionMode;
```
Status of the actual inference precision mode used to detect the bodies/persons. It depends on the GPU hardware support, the sl::BodyTrackingParameters.allowReducedPrecisionInference input parameter and the model support.
### variable bodyFormat
```csharp
BODY_FORMAT bodyFormat;
```
Body format used in sl::BodyTrackingParameters.body_format parameter.
### variable bodiesList
```csharp
BodyData[] bodiesList;
```
Array of detected bodies/persons.
**Note**:
* Since the data is transmitted from C++ to C#, the size of the structure must be constant.
* Therefore, there is a limitation of 75 (sl.Constant.MAX_OBJECTS) objects in the image.
---
# sl::BodyData
**Module:** **Body Tracking Module**
Structure containing data of a detected body/person such as its headBoundingBox, id and its 3D position.
## Public Attributes Documentation
### variable id
```csharp
int id;
```
Body/person identification number.
**Note**:
* Only available if sl.BodyTrackingParameters.enableTracking is activated.
* Otherwise, it will be set to -1.
It is used as a reference when tracking the body through the frames.
### variable uniqueObjectId
```csharp
string uniqueObjectId;
```
Unique id to help identify and track AI detections.
It can be either generated externally, or by using sl.Camera.GenerateUniqueID() or left empty.
### variable trackingState
```csharp
sl.OBJECT_TRACKING_STATE trackingState;
```
Body/person tracking state.
### variable actionState
```csharp
sl.OBJECT_ACTION_STATE actionState;
```
Body/person action state.
### variable position
```csharp
Vector3 position;
```
Body/person 3D centroid.
**Note**: It is defined in sl.InitParameters.coordinateUnits and expressed in sl.RuntimeParameters.measure3DReferenceFrame.
### variable velocity
```csharp
Vector3 velocity;
```
Body/person 3D velocity.
**Note**: It is defined in `sl.InitParameters.coordinateUnits / s` and expressed in sl.RuntimeParameters.measure3DReferenceFrame.
### variable positionCovariance
```csharp
float[] positionCovariance;
```
Covariance matrix of the 3D position.
**Note**: It is represented by its upper triangular matrix value
```cpp
= [p0, p1, p2]
[p1, p3, p4]
[p2, p4, p5]
```
where pi is `positionCovariance[i]`
### variable confidence
```csharp
float confidence;
```
Detection confidence value of the body/person.
From 0 to 100, a low value means the body might not be localized perfectly.
### variable mask
```csharp
System.IntPtr mask;
```
Mask defining which pixels which belong to the body/person (in boundingBox and set to 255) and those of the background (set to 0).
**Warning**:
* The mask information is only available for tracked bodies (sl.OBJECT_TRACKING_STATE.OK) that have a valid depth.
* Otherwise, the mask will not be initialized.
### variable boundingBox2D
```csharp
Vector2[] boundingBox2D;
```
2D bounding box of the body/person represented as four 2D points starting at the top left corner and rotation clockwise.
**Note**: Expressed in pixels on the original image resolution, `[0, 0]` is the top left corner.
```cpp
A ------ B
| Object |
D ------ C
```
### variable headPosition
```csharp
Vector3 headPosition;
```
3D centroid of the head of the body/person.
**Note**: It is defined in sl.InitParameters.coordinateUnits and expressed in sl.RuntimeParameters.measure3DReferenceFrame.
### variable dimensions
```csharp
Vector3 dimensions;
```
3D body/person dimensions: width, height, length.
**Note**: It is defined in sl.InitParameters.coordinateUnits and expressed in sl.RuntimeParameters.measure3DReferenceFrame.
### variable boundingBox
```csharp
Vector3[] boundingBox;
```
3D bounding box of the body/person represented as eight 3D points.
**Note**: It is defined in sl.InitParameters.coordinateUnits and expressed in sl.RuntimeParameters.measure3DReferenceFrame.
```cpp
1 ------ 2
/ /|
0 ------ 3 |
| Object | 6
| |/
4 ------ 7
```
### variable headBoundingBox
```csharp
Vector3[] headBoundingBox;
```
3D bounding box of the head of the body/person represented as eight 3D points.
**Note**: It is defined in sl.InitParameters.coordinateUnits and expressed in sl.RuntimeParameters.measure3DReferenceFrame.
### variable headBoundingBox2D
```csharp
Vector2[] headBoundingBox2D;
```
2D bounding box of the head of the body/person represented as four 2D points starting at the top left corner and rotation clockwise.
**Note**: Expressed in pixels on the original image resolution, `[0, 0]` is the top left corner.
### variable keypoints2D
```csharp
Vector2[] keypoints2D;
```
Set of useful points representing the human body in 2D.
**Note**: Expressed in pixels on the original image resolution, `[0, 0]` is the top left corner.
**Warning**: In some cases, eg. body partially out of the image, some keypoints can not be detected. They will have negatives coordinates.
### variable keypoints
```csharp
Vector3[] keypoints;
```
Set of useful points representing the human body in 3D.
**Note**: They are defined in sl.InitParameters.coordinateUnits and expressed in sl.RuntimeParameters.measure3DReferenceFrame.
**Warning**: In some cases, eg. body partially out of the image or missing depth data, some keypoints can not be detected. They will have non finite values.
### variable keypointConfidence
```csharp
float[] keypointConfidence;
```
Array of detection confidences for each keypoint.
**Note**: They can not be lower than the sl.BodyTrackingRuntimeParameters.detectionConfidenceThreshold.
**Warning**: In some cases, eg. body partially out of the image or missing depth data, some keypoints can not be detected. They will have non finite values.
### variable keypointCovariances
```csharp
CovarMatrix[] keypointCovariances;
```
Array of detection covariance for each keypoint.
**Warning**: In some cases, eg. body partially out of the image or missing depth data, some keypoints can not be detected. Their covariances will be 0.
### variable localPositionPerJoint
```csharp
Vector3[] localPositionPerJoint;
```
Array of local position (position of the child keypoint with respect to its parent expressed in its parent coordinate frame) for each keypoint.
**Note**: They are expressed in sl.REFERENCE_FRAME.CAMERA or sl.REFERENCE_FRAME.WORLD.
**Warning**: Not available with sl.BODY_FORMAT.BODY_18.
### variable localOrientationPerJoint
```csharp
Quaternion[] localOrientationPerJoint;
```
Array of local orientation for each keypoint.
**Note**: The orientation is represented by a quaternion.
**Warning**: Not available with sl.BODY_FORMAT.BODY_18.
### variable globalRootOrientation
```csharp
Quaternion globalRootOrientation;
```
Global root orientation of the skeleton.
**Note**: The global root position is already accessible in keypoint attribute by using the root index of a given sl.BODY_FORMAT.
**Warning**: Not available with sl.BODY_FORMAT.BODY_18.
The orientation is also represented by a quaternion.
---
# sl::BodyTrackingFusionParameters
**Module:** **Fusion Module**
Holds the options used to initialize the body tracking module of the Fusion.
## Public Attributes Documentation
### variable enableTracking
```csharp
bool enableTracking;
```
Defines if the object detection will track objects across images flow.
Default: true
### variable enableBodyFitting
```csharp
bool enableBodyFitting;
```
Defines if the body fitting will be applied.
**Note**: If you enable it and the camera provides data as BODY_18 the fused body format will be BODY_34.
Default: false
---
# sl::BodyTrackingFusionRuntimeParameters
**Module:** **Fusion Module**
Holds the options used to change the behavior of the body tracking module at runtime.
## Public Attributes Documentation
### variable skeletonMinimumAllowedKeypoints
```csharp
int skeletonMinimumAllowedKeypoints;
```
If the fused skeleton has less than skeleton_minimum_allowed_keypoints keypoints, it will be discarded.
Default: -1.
### variable skeletonMinimumAllowedCameras
```csharp
int skeletonMinimumAllowedCameras;
```
If a skeleton was detected in less than skeleton_minimum_allowed_camera cameras, it will be discarded.
Default: -1.
### variable skeletonSmoothing
```csharp
float skeletonSmoothing;
```
This value controls the smoothing of the tracked or fitted fused skeleton.
It is ranged from 0 (low smoothing) and 1 (high smoothing).
Default: 0.
---
# sl::BodyTrackingRuntimeParameters
**Module:** **Body Tracking Module**
Structure containing a set of runtime parameters for the body tracking module. More...
## Detailed Description
```csharp
struct sl::BodyTrackingRuntimeParameters;
```
Structure containing a set of runtime parameters for the body tracking module.
**Note**: Parameters can be adjusted by the user.
The default constructor sets all parameters to their default settings.
## Public Attributes Documentation
### variable detectionConfidenceThreshold
```csharp
float detectionConfidenceThreshold;
```
Confidence threshold.
**Note**: If the scene contains a lot of objects, increasing the confidence can slightly speed up the process, since every object instance is tracked.
From 1 to 100, with 1 meaning a low threshold, more uncertain objects and 99 very few but very precise objects.
Default: 20.f
### variable minimumKeypointsThreshold
```csharp
int minimumKeypointsThreshold;
```
Minimum threshold for the keypoints.
**Note**: It is useful, for example, to remove unstable fitting results when a skeleton is partially occluded.
The ZED SDK will only output the keypoints of the skeletons with threshold greater than this value.
Default: 0
### variable skeletonSmoothing
```csharp
float skeletonSmoothing;
```
Control of the smoothing of the fitted fused skeleton.
It is ranged from 0 (low smoothing) and 1 (high smoothing).
Default: 0
---
# sl::CameraConfiguration
**Module:** **Core Module**
Structure containing information about the camera sensor. More...
## Detailed Description
```csharp
struct sl::CameraConfiguration;
```
Structure containing information about the camera sensor.
**Note**: This object is meant to be used as a read-only container, editing any of its field won't impact the ZED SDK.
**Warning**: sl.CalibrationParameters are returned in sl.COORDINATE_SYSTEM.IMAGE, they are not impacted by the sl.InitParameters.coordinateSystem.
## Public Attributes Documentation
### variable calibrationParameters
```csharp
CalibrationParameters calibrationParameters;
```
Intrinsics and extrinsic stereo parameters for rectified/undistorted images.
### variable calibrationParametersRaw
```csharp
CalibrationParameters calibrationParametersRaw;
```
Intrinsics and extrinsic stereo parameters for unrectified/distorted images.
### variable firmwareVersion
```csharp
uint firmwareVersion;
```
Internal firmware version of the camera.
### variable fps
```csharp
float fps;
```
FPS of the camera.
### variable resolution
```csharp
Resolution resolution;
```
Resolution of the camera.
---
# sl::CameraIdentifier
**Module:** **Fusion Module**
Used to identify a specific camera in the Fusion API
## Public Functions Documentation
### function CameraIdentifier
```csharp
CameraIdentifier(
ulong _sn =0
)
```
Constructor with serial number.
**Parameters**:
* **_sn**
## Public Attributes Documentation
### variable sn
```csharp
ulong sn;
```
Serial Number of the camera.
---
# sl::CameraInformation
**Module:** **Core Module**
Structure containing information of a single camera (serial number, model, input type, etc.)
## Public Attributes Documentation
### variable serialNumber
```csharp
uint serialNumber;
```
Serial number of the camera.
### variable cameraModel
```csharp
MODEL cameraModel;
```
Model of the camera (see sl.MODEL).
### variable inputType
```csharp
INPUT_TYPE inputType;
```
Input type used in the ZED SDK.
### variable cameraConfiguration
```csharp
CameraConfiguration cameraConfiguration;
```
Camera configuration parameters stored in a sl.CameraConfiguration.
### variable sensorsConfiguration
```csharp
SensorsConfiguration sensorsConfiguration;
```
Sensors configuration parameters stored in a sl.SensorsConfiguration.
---
# sl::CameraMetrics
**Module:** **Fusion Module**
Holds the metrics of a sender in the fusion process.
## Public Attributes Documentation
### variable uuid
```csharp
CameraIdentifier uuid;
```
### variable receivedFps
```csharp
float receivedFps;
```
FPS of the received data.
### variable receivedLatency
```csharp
float receivedLatency;
```
Latency (in seconds) of the received data. Timestamp difference between the time when the data are sent and the time they are received (mostly introduced when using the local network workflow).
### variable syncedLatency
```csharp
float syncedLatency;
```
Latency (in seconds) after Fusion synchronization. Difference between the timestamp of the data received and the timestamp at the end of the Fusion synchronization.
### variable isPresent
```csharp
bool isPresent;
```
Is set to false if no data in this batch of metrics.
### variable ratioDetection
```csharp
float ratioDetection;
```
Skeleton detection percent during the last second. Number of frames with at least one detection / number of frames, over the last second. A low value means few detections occured lately for this sender.
### variable deltaTs
```csharp
float deltaTs;
```
Average data acquisition timestamp difference. Average standard deviation of sender's period since the start.
---
# sl::Camera::NativeRecordingParameters
## Public Attributes Documentation
### variable video_filename
```csharp
byte[] video_filename;
```
### variable compression_mode
```csharp
int compression_mode;
```
### variable bitrate
```csharp
uint bitrate;
```
### variable target_framerate
```csharp
uint target_framerate;
```
### variable transcode_streaming_input
```csharp
bool transcode_streaming_input;
```
### variable encryption_key
```csharp
byte[] encryption_key;
```
### variable encoding_preset
```csharp
int encoding_preset;
```
---
# sl::Camera::sl_PlaneDetectionParameters
DLL-friendly version of PlaneDetectionParameters (found in ZEDCommon.cs).
## Public Attributes Documentation
### variable maxDistanceThreshold
```csharp
float maxDistanceThreshold;
```
### variable normalSimilarityThreshold
```csharp
float normalSimilarityThreshold;
```
---
# sl::Camera::sl_PositionalTrackingParameters
DLL-friendly version of PositionalTrackingParameters (found in ZEDCommon.cs).
## Public Attributes Documentation
### variable initialWorldRotation
```csharp
Quaternion initialWorldRotation;
```
### variable initialWorldPosition
```csharp
Vector3 initialWorldPosition;
```
### variable enableAreaMemory
```csharp
bool enableAreaMemory;
```
### variable enablePoseSmothing
```csharp
bool enablePoseSmothing;
```
### variable setFloorAsOrigin
```csharp
bool setFloorAsOrigin;
```
### variable setAsStatic
```csharp
bool setAsStatic;
```
### variable enableIMUFusion
```csharp
bool enableIMUFusion;
```
### variable depthMinRange
```csharp
float depthMinRange;
```
### variable setGravityAsOrigin
```csharp
bool setGravityAsOrigin;
```
### variable mode
```csharp
sl.POSITIONAL_TRACKING_MODE mode;
```
---
# sl::Camera::sl_RuntimeParameters
DLL-friendly version of RuntimeParameters (found in ZEDCommon.cs).
## Public Functions Documentation
### function sl_RuntimeParameters
```csharp
sl_RuntimeParameters(
RuntimeParameters rt
)
```
Copy constructor.
## Public Attributes Documentation
### variable measure3DReferenceFrame
```csharp
sl.REFERENCE_FRAME measure3DReferenceFrame;
```
Provides 3D measures (point cloud and normals) in the desired reference frame (default is REFERENCE_FRAME_CAMERA).
### variable enableDepth
```csharp
bool enableDepth;
```
Defines whether the depth map should be computed.
### variable enableFillMode
```csharp
bool enableFillMode;
```
Defines if the depth map should be completed or not, similar to the removed SENSING_MODE::FILL. Warning: Enabling this will override the confidence values confidenceThreshold and textureConfidenceThreshold as well as removeSaturatedAreas
### variable confidenceThreshold
```csharp
int confidenceThreshold;
```
Defines the confidence threshold for the depth. Based on stereo matching score.
### variable textureConfidenceThreshold
```csharp
int textureConfidenceThreshold;
```
Defines texture confidence threshold for the depth. Based on textureness confidence.
### variable removeSaturatedAreas
```csharp
bool removeSaturatedAreas;
```
Defines if the saturated area (Luminance>=255) must be removed from depth map estimation
---
# sl::Camera::sl_SpatialMappingParameters
DLL-friendly version of SpatialMappingPara (found in ZEDCommon.cs).
## Public Attributes Documentation
### variable resolutionMeter
```csharp
float resolutionMeter;
```
### variable rangeMeter
```csharp
float rangeMeter;
```
### variable saveTexture
```csharp
bool saveTexture;
```
### variable useChunkOnly
```csharp
bool useChunkOnly;
```
### variable maxMemoryUsage
```csharp
int maxMemoryUsage;
```
### variable reverseVertexOrder
```csharp
bool reverseVertexOrder;
```
### variable mapType
```csharp
SPATIAL_MAP_TYPE mapType;
```
### variable stabilityCounter
```csharp
int stabilityCounter;
```
### variable disparity_std
```csharp
float disparity_std;
```
### variable decay
```csharp
float decay;
```
### variable enable_forget_past
```csharp
bool enable_forget_past;
```
---
# sl::Camera::sl_initParameters
DLL-friendly version of InitParameters (found in ZEDCommon.cs).
## Public Functions Documentation
### function sl_initParameters
```csharp
sl_initParameters(
InitParameters init
)
```
Copy constructor.
**Parameters**:
* **init**
## Public Attributes Documentation
### variable inputType
```csharp
sl.INPUT_TYPE inputType;
```
### variable resolution
```csharp
sl.RESOLUTION resolution;
```
Resolution the ZED will be set to.
### variable cameraFps
```csharp
int cameraFps;
```
Desired camera FPS. Max is set by resolution.
### variable cameraDeviceID
```csharp
int cameraDeviceID;
```
ID for identifying which of multiple connected ZEDs to use.
### variable cameraImageFlip
```csharp
int cameraImageFlip;
```
True to flip images horizontally.
### variable cameraDisableSelfCalib
```csharp
bool cameraDisableSelfCalib;
```
True to disable self-calibration, using unoptimized optional calibration parameters. False is recommended for optimized calibration.
### variable enableRightSideMeasure
```csharp
bool enableRightSideMeasure;
```
True if depth relative to the right sensor should be computed.
### variable svoRealTimeMode
```csharp
bool svoRealTimeMode;
```
True to skip dropped frames during SVO playback.
### variable depthMode
```csharp
sl.DEPTH_MODE depthMode;
```
Quality level of depth calculations. Higher settings improve accuracy but cost performance.
### variable depthStabilization
```csharp
int depthStabilization;
```
This sets the depth stabilizer temporal smoothing strength. the depth stabilize smooth range is [0, 100] 0 means a low temporal smmoothing behavior(for highly dynamic scene), 100 means a high temporal smoothing behavior(for static scene)
### variable depthMinimumDistance
```csharp
float depthMinimumDistance;
```
Minimum distance from the camera from which depth will be computed, in the defined coordinateUnit.
### variable depthMaximumDistance
```csharp
float depthMaximumDistance;
```
Maximum distance that can be computed.
### variable coordinateUnits
```csharp
UNIT coordinateUnits;
```
Coordinate unit for all measurements (depth, tracking, etc.).
### variable coordinateSystem
```csharp
COORDINATE_SYSTEM coordinateSystem;
```
Defines order and direction of coordinate system axes.
### variable sdkGPUId
```csharp
int sdkGPUId;
```
ID of the graphics card on which the ZED's computations will be performed.
### variable sdkVerbose
```csharp
int sdkVerbose;
```
True for the SDK to provide text feedback.
### variable sensorsRequired
```csharp
bool sensorsRequired;
```
True if sensors are required, false will not trigger an error if sensors are missing.
### variable enableImageEnhancement
```csharp
bool enableImageEnhancement;
```
Whether to enable improved color/gamma curves added in ZED SDK 3.0.
### variable openTimeoutSec
```csharp
float openTimeoutSec;
```
Define a timeout in seconds after which an error is reported if the open() command fails. Set to '-1' to try to open the camera endlessly without returning error in case of failure. Set to '0' to return error in case of failure at the first attempt. This parameter only impacts the LIVE mode.
### variable asyncGrabCameraRecovery
```csharp
bool asyncGrabCameraRecovery;
```
Define the behavior of the automatic camera recovery during grab() function call. When async is enabled and there's an issue with the communication with the camera the grab() will exit after a short period and return the ERROR_CODE::CAMERA_REBOOTING warning.The recovery will run in the background until the correct communication is restored. When async_grab_camera_recovery is false, the grab() function is blocking and will return only once the camera communication is restored or the timeout is reached. The default behavior is synchronous (false), like previous ZED SDK versions
### variable grabComputeCappingFPS
```csharp
float grabComputeCappingFPS;
```
Define a computation upper limit to the grab frequency. This can be useful to get a known constant fixed rate or limit the computation load while keeping a short exposure time by setting a high camera capture framerate. The value should be inferior to the InitParameters::camera_fps and strictly positive.It has no effect when reading an SVO file. This is an upper limit and won't make a difference if the computation is slower than the desired compute capping fps.
**Note**: Internally the grab function always tries to get the latest available image while respecting the desired fps as much as possible.
### variable enableImageValidityCheck
```csharp
bool enableImageValidityCheck;
```
Enable or disable the image validity verification. This will perform additional verification on the image to identify corrupted data.This verification is done in the grab function and requires some computations. If an issue is found, the grab function will output a warning as sl.ERROR_CODE.CORRUPTED_FRAME. This version doesn't detect frame tearing currently. default: disabled
### variable maximumWorkingResolution
```csharp
Resolution maximumWorkingResolution;
```
Set a maximum size for all SDK output, like retrieveImage and retrieveMeasure functions. This will override the default (0,0) and instead of outputting native image size sl::Mat, the ZED SDK will take this size as default. A custom lower size can also be used at runtime, but not bigger.This is used for internal optimization of compute and memory allocations The default is similar to previous version with(0,0), meaning native image size
**Note**: : if maximum_working_resolution field are lower than 64, it will be interpreted as dividing scale factor;
* maximum_working_resolution = sl::Resolution(1280, 2) -> 1280 x(image_height/2) = 1280 x(half height)
* maximum_working_resolution = sl::Resolution(4, 4) -> (image_width/4) x(image_height/4) = quarter size
### variable svoDecryptionKey
```csharp
byte[] svoDecryptionKey;
```
---
# sl::Chunk
**Module:** **Spatial Mapping Module**
Class representing a sub-mesh containing local vertices and triangles.
## Public Attributes Documentation
### variable vertices
```csharp
Vector3[] vertices;
```
Array of vertices.
Vertices are defined by a 3D point.
### variable triangles
```csharp
int[] triangles;
```
Triangles (or faces) contains the index of its three vertices.
It corresponds to the 3 vertices of the triangle `{v1, v2, v3}`.
### variable colors
```csharp
byte[] colors;
```
Colors of the vertices.
---
# sl::CommunicationParameters
**Module:** **Fusion Module**
Holds the communication parameter to configure the connection between senders and receiver
## Public Functions Documentation
### function SetIP
```csharp
void SetIP(
string Ip
)
```
Set the IP address of the sender
**Parameters**:
* **Ip**
### function SetPort
```csharp
void SetPort(
uint port
)
```
Set the port of the sender²
**Parameters**:
* **port**
## Public Attributes Documentation
### variable communicationType
```csharp
COMM_TYPE communicationType;
```
Type of communication
### variable ipPort
```csharp
uint ipPort;
```
The comm port used for streaming the data
### variable ipAdd
```csharp
char[] ipAdd;
```
The IP address of the sender
---
# sl::CovarMatrix
Full covariance matrix for position (3x3). Only 6 values are necessary [p0, p1, p2] [p1, p3, p4] [p2, p4, p5]
## Public Attributes Documentation
### variable values
```csharp
float[] values;
```
---
# sl::CustomBoxObjectData
**Module:** **Object Detection Module**
Structure that store externally detected objects. More...
## Detailed Description
```csharp
struct sl::CustomBoxObjectData;
```
Structure that store externally detected objects.
The objects can be ingested with sl.Camera.IngestCustomBoxObjects() to extract 3D and tracking information over time.
## Public Attributes Documentation
### variable uniqueObjectID
```csharp
string uniqueObjectID;
```
Unique id to help identify and track AI detections.
It can be either generated externally, or by using sl.Camera.GenerateUniqueID() or left empty.
### variable boundingBox2D
```csharp
Vector2[] boundingBox2D;
```
2D bounding box of the object represented as four 2D points starting at the top left corner and rotation clockwise.
**Note**: Expressed in pixels on the original image resolution, `[0, 0]` is the top left corner.
```cpp
A ------ B
| Object |
D ------ C
```
### variable label
```csharp
int label;
```
Object label.
**Note**: It should define an object class. This means that any similar object (in classification) should share the same label number.
This information is passed-through and can be used to improve object tracking.
### variable probability
```csharp
float probability;
```
Detection confidence value of the object.
**Note**:
* The value should be in `[0-1]`.
* It can be used to improve the object tracking.
### variable isGrounded
```csharp
bool isGrounded;
```
Provide hypothesis about the object movements (degrees of freedom or DoF) to improve the object tracking.
**Note**:
* This parameter cannot be changed for a given object tracking id.
* It is advised to set it by labels to avoid issues.
* true: 2 DoF projected alongside the floor plane. Case for object standing on the ground such as person, vehicle, etc.
The projection implies that the objects cannot be superposed on multiple horizontal levels.
* false: 6 DoF (full 3D movements are allowed).
### variable isStatic
```csharp
bool isStatic;
```
Provide hypothesis about the object staticity to improve the object tracking.
* true: the object will be assumed to never move nor being moved.
* false: the object will be assumed to be able to move or being moved.
### variable trackingTimeout
```csharp
float trackingTimeout;
```
Maximum tracking time threshold (in seconds) before dropping the tracked object when unseen for this amount of time. By default, let the tracker decide internally based on the internal sub class of the tracked object.
### variable trackingMaxDist
```csharp
float trackingMaxDist;
```
Maximum tracking distance threshold(in meters) before dropping the tracked object when unseen for this amount of meters. By default, do not discard tracked object based on distance. Only valid for static object.
### variable maxBoxWidthMeters
```csharp
float maxBoxWidthMeters;
```
Maximum allowed 3D width. Any prediction bigger than that will be either discarded (if object is tracked and in SEARCHING state) or clamped. Default: -1 (no filtering)
### variable minBoxWidthMeters
```csharp
float minBoxWidthMeters;
```
Minimum allowed 3D width. Any prediction smaller than that will be either discarded (if object is tracked and in SEARCHING state) or clamped. Default: -1 (no filtering)
### variable maxBoxHeightMeters
```csharp
float maxBoxHeightMeters;
```
Maximum allowed 3D height. Any prediction bigger than that will be either discarded (if object is tracked and in SEARCHING state) or clamped. Default: -1 (no filtering)
### variable minBoxHeightMeters
```csharp
float minBoxHeightMeters;
```
Minimum allowed 3D height. Any prediction smaller than that will be either discarded (if object is tracked and in SEARCHING state) or clamped. Default: -1 (no filtering)
### variable maxAllowedAcceleration
```csharp
float maxAllowedAcceleration;
```
Manually override the acceleration preset. If set, this value takes precedence over the selected preset, allowing for a custom maximum acceleration. Unit is m/s^2.
---
# sl::CustomMaskObjectData
Structure that store external 2D mask.
## Public Attributes Documentation
### variable uniqueObjectID
```csharp
string uniqueObjectID;
```
Unique id to help identify and track AI detections.
It can be either generated externally, or by using sl.Camera.GenerateUniqueID() or left empty.
### variable boundingBox2D
```csharp
Vector2[] boundingBox2D;
```
2D bounding box of the object represented as four 2D points starting at the top left corner and rotation clockwise.
**Note**: Expressed in pixels on the original image resolution, `[0, 0]` is the top left corner.
```cpp
A ------ B
| Object |
D ------ C
```
### variable label
```csharp
int label;
```
Object label.
**Note**: It should define an object class. This means that any similar object (in classification) should share the same label number.
This information is passed-through and can be used to improve object tracking.
### variable probability
```csharp
float probability;
```
Detection confidence value of the object.
**Note**:
* The value should be in `[0-1]`.
* It can be used to improve the object tracking.
### variable isGrounded
```csharp
bool isGrounded;
```
Provide hypothesis about the object movements (degrees of freedom or DoF) to improve the object tracking.
**Note**:
* This parameter cannot be changed for a given object tracking id.
* It is advised to set it by labels to avoid issues.
* true: 2 DoF projected alongside the floor plane. Case for object standing on the ground such as person, vehicle, etc.
The projection implies that the objects cannot be superposed on multiple horizontal levels.
* false: 6 DoF (full 3D movements are allowed).
### variable isStatic
```csharp
bool isStatic;
```
Provide hypothesis about the object staticity to improve the object tracking.
* true: the object will be assumed to never move nor being moved.
* false: the object will be assumed to be able to move or being moved.
### variable trackingTimeout
```csharp
float trackingTimeout;
```
Maximum tracking time threshold (in seconds) before dropping the tracked object when unseen for this amount of time. By default, let the tracker decide internally based on the internal sub class of the tracked object.
### variable trackingMaxDist
```csharp
float trackingMaxDist;
```
Maximum tracking distance threshold(in meters) before dropping the tracked object when unseen for this amount of meters. By default, do not discard tracked object based on distance. Only valid for static object.
### variable maxBoxWidthMeters
```csharp
float maxBoxWidthMeters;
```
Maximum allowed 3D width. Any prediction bigger than that will be either discarded (if object is tracked and in SEARCHING state) or clamped. Default: -1 (no filtering)
### variable minBoxWidthMeters
```csharp
float minBoxWidthMeters;
```
Minimum allowed 3D width. Any prediction smaller than that will be either discarded (if object is tracked and in SEARCHING state) or clamped. Default: -1 (no filtering)
### variable maxBoxHeightMeters
```csharp
float maxBoxHeightMeters;
```
Maximum allowed 3D height. Any prediction bigger than that will be either discarded (if object is tracked and in SEARCHING state) or clamped. Default: -1 (no filtering)
### variable minBoxHeightMeters
```csharp
float minBoxHeightMeters;
```
Minimum allowed 3D height. Any prediction smaller than that will be either discarded (if object is tracked and in SEARCHING state) or clamped. Default: -1 (no filtering)
### variable maxAllowedAcceleration
```csharp
float maxAllowedAcceleration;
```
Manually override the acceleration preset. If set, this value takes precedence over the selected preset, allowing for a custom maximum acceleration. Unit is m/s^2.
---
# sl::CustomObjectDetectionProperties
Structure containing a set of runtime properties of a certain class ID for the object detection module using a custom model.
## Public Attributes Documentation
### variable ClassID
```csharp
int ClassID;
```
Index of the class represented by this set of properties.
### variable enabled
```csharp
bool enabled;
```
Whether the object object is kept or not.
### variable detectionConfidenceThreshold
```csharp
float detectionConfidenceThreshold;
```
Confidence threshold. From 1 to 100, with 1 meaning a low threshold, more uncertain objects and 99 very few but very precise objects. If the scene contains a lot of objects, increasing the confidence can slightly speed up the process, since every object instance is tracked.
### variable isGrounded
```csharp
bool isGrounded;
```
Provide hypothesis about the object movements (degrees of freedom or DoF) to improve the object tracking.
* true: 2 DoF projected alongside the floor plane. Case for object standing on the ground such as person, vehicle, etc. The projection implies that the objects cannot be superposed on multiple horizontal levels.
* false: 6 DoF (full 3D movements are allowed).
### variable isStatic
```csharp
bool isStatic;
```
Provide hypothesis about the object staticity to improve the object tracking.
* true: the object will be assumed to never move nor being moved.
* false: the object will be assumed to be able to move or being moved.
### variable trackingTimeout
```csharp
float trackingTimeout;
```
Maximum tracking time threshold (in seconds) before dropping the tracked object when unseen for this amount of time. By default, let the tracker decide internally based on the internal sub class of the tracked object.
### variable trackingMaxDist
```csharp
float trackingMaxDist;
```
Maximum tracking distance threshold(in meters) before dropping the tracked object when unseen for this amount of meters. By default, do not discard tracked object based on distance. Only valid for static object.
### variable maxBoxWidthNormalized
```csharp
float maxBoxWidthNormalized;
```
Maximum allowed width normalized to the image size. Any prediction bigger than that will be filtered out. Default: -1 (no filtering)
### variable minBoxWidthNormalized
```csharp
float minBoxWidthNormalized;
```
Minimum allowed width normalized to the image size. Any prediction smaller than that will be filtered out. Default: -1 (no filtering)
### variable maxBoxHeightNormalized
```csharp
float maxBoxHeightNormalized;
```
Maximum allowed height normalized to the image size. Any prediction bigger than that will be filtered out. Default: -1 (no filtering)
### variable minBoxHeightNormalized
```csharp
float minBoxHeightNormalized;
```
Minimum allowed height normalized to the image size. Any prediction smaller than that will be filtered out. Default: -1 (no filtering)
### variable maxBoxWidthMeters
```csharp
float maxBoxWidthMeters;
```
Maximum allowed 3D width. Any prediction bigger than that will be either discarded (if object is tracked and in SEARCHING state) or clamped. Default: -1 (no filtering)
### variable minBoxWidthMeters
```csharp
float minBoxWidthMeters;
```
Minimum allowed 3D width. Any prediction smaller than that will be either discarded (if object is tracked and in SEARCHING state) or clamped. Default: -1 (no filtering)
### variable maxBoxHeightMeters
```csharp
float maxBoxHeightMeters;
```
Maximum allowed 3D height. Any prediction bigger than that will be either discarded (if object is tracked and in SEARCHING state) or clamped. Default: -1 (no filtering)
### variable minBoxHeightMeters
```csharp
float minBoxHeightMeters;
```
Minimum allowed 3D height. Any prediction smaller than that will be either discarded (if object is tracked and in SEARCHING state) or clamped. Default: -1 (no filtering)
### variable nativeMappedClass
```csharp
OBJECT_SUBCLASS nativeMappedClass;
```
For increased accuracy, the native sl.OBJECT_SUBCLASS mapping, if any. Native objects have refined internal parameters for better 3D projection and tracking accuracy. If one of the custom objects can be mapped to one the native sl.OBJECT_SUBCLASS, this can help to boost the tracking accuracy. Default: no mapping
### variable objectAccelerationPreset
```csharp
OBJECT_ACCELERATION_PRESET objectAccelerationPreset;
```
Preset defining the expected maximum acceleration of the tracked object. Determines how the ZED SDK interprets object acceleration, affecting tracking behavior and predictions. Default: OBJECT_ACCELERATION_PRESET.DEFAULT
### variable maxAllowedAcceleration
```csharp
float maxAllowedAcceleration;
```
Manually override the acceleration preset. If set, this value takes precedence over the selected preset, allowing for a custom maximum acceleration. Unit is m/s^2. Default: nan (no override)
### variable objectTrackingParameters
```csharp
ObjectTrackingParameters objectTrackingParameters;
```
Object tracking parameters for this class.
---
# sl::CustomObjectDetectionRuntimeParameters
## Public Functions Documentation
### function GetObjectClassDetectionProperties
```csharp
CustomObjectDetectionProperties[] GetObjectClassDetectionProperties()
```
## Public Attributes Documentation
### variable customObjectDetectionProperties
```csharp
CustomObjectDetectionProperties customObjectDetectionProperties;
```
### variable objectClassDetectionProperties
```csharp
IntPtr objectClassDetectionProperties;
```
### variable numberCustomDetectionProperties
```csharp
uint numberCustomDetectionProperties;
```
---
# sl::DeviceProperties
**Module:** **Video Module**
Structure containing information about the properties of a camera. More...
## Detailed Description
```csharp
struct sl::DeviceProperties;
```
Structure containing information about the properties of a camera.
**Note**: A cameraModelsl.MODEL.ZED_M with an id '-1' can be due to an inverted USB-C cable.
## Public Attributes Documentation
### variable cameraState
```csharp
sl.CAMERA_STATE cameraState;
```
State of the camera.
Default: Default: sl.CAMERA_STATE.NOT_AVAILABLE
### variable id
```csharp
int id;
```
Id of the camera.
Default: -1
### variable path
```csharp
string path;
```
System path of the camera.
### variable videoDevice
```csharp
string videoDevice;
```
System path of the camera
### variable i2cPort
```csharp
int i2cPort;
```
i2c port of the camera.
### variable cameraModel
```csharp
sl.MODEL cameraModel;
```
Model of the camera.
### variable sn
```csharp
uint sn;
```
Serial number of the camera.
**Warning**: Not provided for Windows.
Default: 0
### variable gmslPort
```csharp
int gmslPort;
```
GMSL port of the camera.
### variable identifiers
```csharp
byte[] identifiers;
```
[Cam model, eeprom version, white balance param]
### variable camera_badge
```csharp
string camera_badge;
```
badge name (zedx_ar0234)
### variable camera_sensor_model
```csharp
string camera_sensor_model;
```
Name of sensor (zedx)
### variable camera_name
```csharp
string camera_name;
```
Name of Camera in DT (ZED_CAM1)
### variable inputType
```csharp
sl.INPUT_TYPE inputType;
```
Input type of the camera.
### variable sensorAddressLeft
```csharp
byte sensorAddressLeft;
```
sensor_address when available (ZED-X HDR/XOne HDR only)
### variable sensorAddressRight
```csharp
byte sensorAddressRight;
```
sensor_address when available (ZED-X HDR/XOne HDR only)
---
# sl::ECEF
**Module:** **Fusion Module**
Represents a world position in ECEF format.
## Public Attributes Documentation
### variable x
```csharp
double x;
```
x coordinate of ECEF.
### variable y
```csharp
double y;
```
y coordinate of ECEF.
### variable z
```csharp
double z;
```
z coordinate of ECEF.
---
# sl::ENU
**Module:** **Fusion Module**
Represents a world position in ENU format.
## Public Attributes Documentation
### variable east
```csharp
double east;
```
East coordinate
### variable north
```csharp
double north;
```
north coordinate.
### variable up
```csharp
double up;
```
up coordinate.
---
# sl::FusedPositionalTrackingStatus
Class containing the overall position fusion status
## Public Attributes Documentation
### variable odometryStatus
```csharp
ODOMETRY_STATUS odometryStatus;
```
Represents the current state of Visual-Inertial Odometry (VIO) tracking between the previous frame and the current frame.
### variable spatialMemoryStatus
```csharp
SPATIAL_MEMORY_STATUS spatialMemoryStatus;
```
Represents the current state of camera tracking in the global map.
### variable gnssStatus
```csharp
GNSS_STATUS gnssStatus;
```
Represents the current state of GNSS.
### variable gnssMode
```csharp
GNSS_MODE gnssMode;
```
Represents the current mode of GNSS.
### variable gnssFusionStatus
```csharp
GNSS_FUSION_STATUS gnssFusionStatus;
```
Represents the current state of GNSS fusion for global localization.
### variable trackingFusionStatus
```csharp
POSITIONAL_TRACKING_FUSION_STATUS trackingFusionStatus;
```
Represents the current state of positional tracking fusion.
---
# sl::FusionConfiguration
**Module:** **Fusion Module**
Stores the Fusion configuration, can be read from /write to a Json file.
## Public Attributes Documentation
### variable serialNumber
```csharp
uint serialNumber;
```
The serial number of the used ZED camera.
### variable commParam
```csharp
CommunicationParameters commParam;
```
The communication parameters to connect this camera to the Fusion.
### variable position
```csharp
Vector3 position;
```
The WORLD position of the camera for Fusion.
### variable rotation
```csharp
Quaternion rotation;
```
The WORLD rotation of the camera for Fusion.
### variable inputType
```csharp
InputType inputType;
```
The input type for the current camera.
### variable overrideGravity
```csharp
bool overrideGravity;
```
Indicates the behavior of the fusion with respect to given calibration pose. The calibration pose directly specifies the camera's absolute pose relative to a global reference frame. The calibration pose (Pose_rel) is defined relative to the camera's IMU rotational pose. To determine the true absolute position, the Fusion process will compute Pose_abs = Pose_rel * Rot_IMU_camera.
---
# sl::FusionMetrics
**Module:** **Fusion Module**
Holds the metrics of the fusion process.
## Public Attributes Documentation
### variable meanCameraFused
```csharp
float meanCameraFused;
```
Mean number of camera that provides data during the past second.
### variable meanStdevBetweenCamera
```csharp
float meanStdevBetweenCamera;
```
Standard deviation of the data timestamp fused, the lower the better.
### variable cameraIndividualStats
```csharp
CameraMetrics[] cameraIndividualStats;
```
Sender metrics.
---
# sl::Fusion::sl_GNSSCalibrationParameters
DLL-friendly version of GNSSCalibrationParameters (found in ZEDCommon.cs).
## Public Functions Documentation
### function sl_GNSSCalibrationParameters
```csharp
sl_GNSSCalibrationParameters(
GNSSCalibrationParameters gnssCalibrationParameters
)
```
## Public Attributes Documentation
### variable targetYawUncertainty
```csharp
float targetYawUncertainty;
```
This parameter defines the target yaw uncertainty at which the calibration process between GNSS and VIO concludes. The unit of this parameter is in radian. By default, the threshold is set at 0.1 radians.
### variable enableTranslationUncertaintyTarget
```csharp
bool enableTranslationUncertaintyTarget;
```
When this parameter is enabled (set to true), the calibration process between GNSS and VIO accounts for the uncertainty in the determined translation, thereby facilitating the calibration termination. The maximum allowable uncertainty is controlled by the 'target_translation_uncertainty' parameter. By default, it is set to false.
### variable targetTranslationUncertainty
```csharp
float targetTranslationUncertainty;
```
This parameter defines the target translation uncertainty at which the calibration process between GNSS and VIO terminates. By default, the threshold is set at 10 centimeters (10e-2).
### variable enableReinitialization
```csharp
bool enableReinitialization;
```
This initialization parameter determines whether reinitialization should be performed between GNSS and VIO fusion when a significant disparity is detected between GNSS data and the current fusion data. It becomes particularly crucial during prolonged GNSS signal loss scenarios. By default, it is set to true.
### variable gnssVioReinitThreshold
```csharp
float gnssVioReinitThreshold;
```
This parameter determines the threshold for GNSS/VIO reinitialization. If the fused position deviates beyond the region defined by the product of the GNSS covariance and the gnss_vio_reinit_threshold, a reinitialization will be triggered. By default, it is set to 5.
### variable enableRollingCalibration
```csharp
bool enableRollingCalibration;
```
If this parameter is set to true, the fusion algorithm will used a rough VIO / GNSS calibration at first and then refine it. This allow you to quickly get a fused position. By default, it is set to true.
### variable gnssAntennaPosition
```csharp
Vector3 gnssAntennaPosition;
```
Define a transform between the GNSS antenna and the camera system for the VIO / GNSS calibration. Default value is [0,0,0], this position can be refined by the calibration if enabled
---
# sl::Fusion::sl_PositionalTrackingFusionParameters
DLL-friendly version of PositionalTrackingFusionParameters (found in ZEDCommon.cs).
## Public Functions Documentation
### function sl_PositionalTrackingFusionParameters
```csharp
sl_PositionalTrackingFusionParameters(
PositionalTrackingFusionParameters positionalTrackingFusionParameters
)
```
Constructor
## Public Attributes Documentation
### variable enableGNSSFusion
```csharp
bool enableGNSSFusion;
```
If the GNSS should be enabled.
### variable gnssCalibrationParameters
```csharp
sl_GNSSCalibrationParameters gnssCalibrationParameters;
```
GNSS calibration parameter. Determine target threshold for GNSS / VIO calibration.
### variable baseFootprintToWorldTranslation
```csharp
Vector3 baseFootprintToWorldTranslation;
```
Position of the base footprint with respect to the user world.
### variable baseFootprintToWorldRotation
```csharp
Quaternion baseFootprintToWorldRotation;
```
Orientation of the base footprint with respect to the user world.
### variable baseFootprintToBaselinkTranslation
```csharp
Vector3 baseFootprintToBaselinkTranslation;
```
Position of the base footprint with respect to the baselink.
### variable baseFootprintToBaselinkRotation
```csharp
Quaternion baseFootprintToBaselinkRotation;
```
Orientation of the base footprint with respect to the baselink.
### variable SetGravityAsOrigin
```csharp
bool SetGravityAsOrigin;
```
Whether to override 2 of the 3 rotations from base_footprint_to_world_transform using the IMU gravity.
---
# sl::GNSSData
**Module:** **Fusion Module**
Structure containing GNSS data to be used for positional tracking as prior.
## Public Attributes Documentation
### variable longitude
```csharp
double longitude;
```
Longitude in radian.
### variable latitude
```csharp
double latitude;
```
Latitude in radian.
### variable altitude
```csharp
double altitude;
```
Altitude in meter.
### variable ts
```csharp
ulong ts;
```
Timestamp of the GNSS position in nanoseconds (must be aligned with the camera time reference).
### variable positionCovariance
```csharp
double[] positionCovariance;
```
Covariance of the position in meter (must be expressed in the ENU coordinate system).
For eph, epv GNSS sensors, set it as follow: `{eph*eph, 0, 0, 0, eph*eph, 0, 0, 0, epv*epv}`.
### variable longitudeStd
```csharp
double longitudeStd;
```
Longitude standard deviation.
### variable latitudeStd
```csharp
double latitudeStd;
```
Latitude standard deviation.
### variable altitudeStd
```csharp
double altitudeStd;
```
Altitude standard deviation.
### variable status
```csharp
GNSS_STATUS status;
```
GNSS status.
### variable mode
```csharp
GNSS_MODE mode;
```
GNSS mode.
---
# sl::GeoPose
**Module:** **Fusion Module**
Holds Geo reference position.
## Public Attributes Documentation
### variable translation
```csharp
Vector3 translation;
```
The translation defining the pose in ENU.
### variable rotation
```csharp
Quaternion rotation;
```
The rotation defining the pose in ENU.
### variable poseCovariance
```csharp
float[] poseCovariance;
```
The pose covariance in ENU.
### variable horizontalAccuracy
```csharp
double horizontalAccuracy;
```
The horizontal accuracy.
### variable verticalAccuracy
```csharp
double verticalAccuracy;
```
The vertical accuracy.
### variable latCoordinate
```csharp
LatLng latCoordinate;
```
The latitude, longitude, altitude.
### variable heading
```csharp
double heading;
```
The heading.
### variable timestamp
```csharp
ulong timestamp;
```
The timestamp of GeoPose.
---
# sl::HealthStatus
**Module:** **Video Module**
Structure containing the self-diagnostic results of the camera (image, depth, sensor health). Retrieved via Camera.GetHealthStatus.
## Public Attributes Documentation
### variable enabled
```csharp
bool enabled;
```
Whether the health check is enabled.
### variable lowImageQuality
```csharp
bool lowImageQuality;
```
Poor image quality detected (hardware issue, occlusion, blurry, incorrect settings, etc.).
### variable lowLighting
```csharp
bool lowLighting;
```
Low-light conditions detected.
### variable lowDepthReliability
```csharp
bool lowDepthReliability;
```
Low depth map reliability (obstructed optics, heavy fog, etc.).
### variable lowMotionSensorsReliability
```csharp
bool lowMotionSensorsReliability;
```
IMU data reliability issue (corrupted stream, saturated sensors, shocks, etc.).
---
# sl::ImuData
**Module:** **Core Module**
Structure containing data from the IMU sensor.
## Public Attributes Documentation
### variable available
```csharp
bool available;
```
Whether the IMU sensor is available in your camera.
### variable timestamp
```csharp
ulong timestamp;
```
Data acquisition timestamp in nanoseconds.
### variable angularVelocity
```csharp
Vector3 angularVelocity;
```
Angular velocity vector of the gyroscope in deg/s.
**Note**:
* The value can be directly ingested in an IMU fusion algorithm to extract a quaternion.
* Not available in SVO or STREAM mode.
The value is corrected from bias, scale and misalignment.
### variable linearAcceleration
```csharp
Vector3 linearAcceleration;
```
Linear acceleration vector (3x1) of the gyroscope in m/s².
**Note**:
* The value can be directly ingested in an IMU fusion algorithm to extract a quaternion.
* Not available in SVO or STREAM mode.
The value is corrected from bias, scale and misalignment.
### variable angularVelocityUncalibrated
```csharp
Vector3 angularVelocityUncalibrated;
```
Angular velocity vector of the gyroscope in deg/s (uncorrected from the IMU calibration).
**Note**:
* The value is the exact raw values from the IMU.
* Not available in SVO or STREAM mode.
### variable linearAccelerationUncalibrated
```csharp
Vector3 linearAccelerationUncalibrated;
```
Linear acceleration vector of the gyroscope in m/s² (uncorrected from the IMU calibration).
**Note**:
* The value is the exact raw values from the IMU.
* Not available in SVO or STREAM mode.
### variable fusedOrientation
```csharp
Quaternion fusedOrientation;
```
Orientation from the IMU sensor.
### variable orientationCovariance
```csharp
Matrix3x3 orientationCovariance;
```
Covariance matrix of the quaternion.
### variable angularVelocityCovariance
```csharp
Matrix3x3 angularVelocityCovariance;
```
Covariance matrix of the angular velocity of the gyroscope in deg/s (angularVelocity).
**Note**: Not available in SVO or STREAM mode.
### variable linearAccelerationCovariance
```csharp
Matrix3x3 linearAccelerationCovariance;
```
Accelerometer raw data covariance matrix.
**Note**: Not available in SVO or STREAM mode.
---
# sl::InitFusionParameters
**Module:** **Fusion Module**
Holds the options used to initialize the Fusion object.
## Public Functions Documentation
### function InitFusionParameters
```csharp
InitFusionParameters(
bool verbose =false,
UNIT coordinateUnits =UNIT.MILLIMETER,
COORDINATE_SYSTEM coordinateSystem =COORDINATE_SYSTEM.IMAGE,
bool outputPerformanceMetrics =false,
uint timeoutPeriodsNumber =5,
SynchronizationParameter synchronizationParameters =new SynchronizationParameter(),
int sdkGpuId =-1,
IntPtr? sdkCudaCtx =null,
Resolution? maximumWorkingResolution =null
)
```
Default constructor.
## Public Attributes Documentation
### variable coordinateUnits
```csharp
UNIT coordinateUnits;
```
This parameter allows you to select the unit to be used for all metric values of the SDK (depth, point cloud, tracking, mesh, and others). Default : UNIT::MILLIMETER
### variable coordinateSystem
```csharp
COORDINATE_SYSTEM coordinateSystem;
```
Positional tracking, point clouds and many other features require a given COORDINATE_SYSTEM to be used as reference. This parameter allows you to select the COORDINATE_SYSTEM used by the Camera to return its measures. This defines the order and the direction of the axis of the coordinate system. Default : COORDINATE_SYSTEM::IMAGE
### variable outputPerformanceMetrics
```csharp
bool outputPerformanceMetrics;
```
It allows users to extract some stats of the Fusion API like drop frame of each camera, latency, etc...
### variable verbose
```csharp
bool verbose;
```
Enable the verbosity mode of the SDK.
### variable timeoutPeriodsNumber
```csharp
uint timeoutPeriodsNumber;
```
If specified change the number of period necessary for a source to go in timeout without data. For example, if you set this to 5 then, if any source do not receive data during 5 period, these sources will go to timeout and will be ignored. /// if any source does not receive data during 5 periods, these sources will go into timeout and will be ignored.
### variable sdkGpuId
```csharp
int sdkGpuId;
```
NVIDIA graphics card id to use. By default the SDK will use the most powerful NVIDIA graphics card found. However, when running several applications, or using several cameras at the same time, splitting the load over available GPUs can be useful. This parameter allows you to select the GPU used by the sl::Camera using an ID from 0 to n-1 GPUs in your PC. Default: -1
**Note**: A non-positive value will search for all CUDA capable devices and select the most powerful.
### variable sdkCudaCtx
```csharp
IntPtr sdkCudaCtx;
```
CUcontext to be used. If your application uses another CUDA-capable library, giving its CUDA context to the ZED SDK can be useful when sharing GPU memories. This parameter allows you to set the CUDA context to be used by the ZED SDK. Leaving this parameter empty asks the SDK to create its own context. Default: (empty)
**Note**:
* When creating you own CUDA context, you have to define the device you will use. Do not forget to also specify it on sdk_gpu_id.
* **On Jetson**, you have to set the flag CU_CTX_SCHED_YIELD, during CUDA context creation.
* You can also let the SDK create its own context, and use sl::Camera::getCUDAContext() to use it.
### variable synchronizationParameters
```csharp
SynchronizationParameter synchronizationParameters;
```
Specifies the parameters used for data synchronization during fusion. The SynchronizationParameter struct encapsulates the synchronization parameters that control the data fusion process.
### variable maximumWorkingResolution
```csharp
Resolution maximumWorkingResolution;
```
Sets the maximum resolution for all Fusion outputs, such as images and measures.
The default value is (-1, -1), which allows the Fusion to automatically select the optimal resolution for the best quality/runtime ratio.
* For images, the output resolution can be up to the native resolution of the camera.
* For measures involving depth, the output resolution can be up to the maximum working resolution.
Setting this parameter to (-1, -1) will ensure the best balance between quality and performance for depth measures.
---
# sl::InputType
**Module:** **Video Module**
Structure defining the input type used in the ZED SDK. More...
## Detailed Description
```csharp
struct sl::InputType;
```
Structure defining the input type used in the ZED SDK.
It can be used to select a specific camera with an id or serial number, or from a SVO file.
## Public Functions Documentation
### function GetType
```csharp
INPUT_TYPE GetType()
```
Returns the current input type.
**Return**:
## Public Attributes Documentation
### variable serialNumber
```csharp
uint serialNumber;
```
Serial number of the camera.
### variable id
```csharp
uint id;
```
Id of the camera.
### variable svoInputFilename
```csharp
char[] svoInputFilename;
```
Path to the SVO file.
### variable streamInputIp
```csharp
char[] streamInputIp;
```
IP address of the streaming camera.
### variable streamInputPort
```csharp
ushort streamInputPort;
```
Port of the streaming camera.
---
# sl::Landmark
Represents a 3d landmark.
## Public Attributes Documentation
### variable id
```csharp
ulong id;
```
Unique identifier for the landmark.
### variable position
```csharp
Vector3 position;
```
World position of the landmark.
---
# sl::Landmark2D
Represents a 2d landmark.
## Public Attributes Documentation
### variable id
```csharp
ulong id;
```
Unique identifier for the landmark.
### variable imagePosition
```csharp
Vector2 imagePosition;
```
Projection of the landmark in the image.
### variable dynamic_confidence
```csharp
float dynamic_confidence;
```
Confidence score indicating the likelihood that the landmark is associated with a dynamic object. The value ranges from 0 to 1, where a smaller value indicates greater confidence that the landmark is owned by a dynamic object. The value is -1 if the dynamic confidence is not computed.
---
# sl::LatLng
**Module:** **Fusion Module**
Represents a world position in LatLng format.
## Public Attributes Documentation
### variable latitude
```csharp
double latitude;
```
Latitude in radian.
### variable longitude
```csharp
double longitude;
```
Longitude in radian.
### variable altitude
```csharp
double altitude;
```
Altitude in meter.
---
# sl::MagnetometerData
**Module:** **Core Module**
Structure containing data from the magnetometer sensor.
## Public Attributes Documentation
### variable available
```csharp
bool available;
```
Whether the magnetometer sensor is available in your camera.
### variable timestamp
```csharp
ulong timestamp;
```
Data acquisition timestamp in nanoseconds.
### variable magneticField
```csharp
Vector3 magneticField;
```
Magnetic field local vector in microtesla (μT).
**Note**: To calibrate the magnetometer sensor, please use **ZED****Sensor****Viewer** tool after placing the camera in the final operating environment.
### variable magneticFieldUncalibrated
```csharp
Vector3 magneticFieldUncalibrated;
```
Uncalibrated magnetic field local vector in microtesla (μT).
**Note**:
* The magnetometer raw values are affected by soft and hard iron interferences.
* The sensor must be calibrated by placing the camera in the working environment and using **ZED****Sensor****Viewer** tool.
* Not available in SVO or STREAM mode.
### variable magneticHeading
```csharp
float magneticHeading;
```
Camera heading in degrees relative to the magnetic North Pole.
**Note**:
* The magnetic North Pole has an offset with respect to the geographic North Pole, depending on the geographic position of the camera.
* To get a correct magnetic heading, the magnetometer sensor must be calibrated using **ZED****Sensor****Viewer** tool.
### variable magnetic_heading_state
```csharp
HEADING_STATE magnetic_heading_state;
```
State of magneticHeading.
### variable magnetic_heading_accuracy
```csharp
float magnetic_heading_accuracy;
```
Accuracy of magnetic_heading measure in the range [0.0, 1.0].
**Note**: A negative value means that the magnetometer must be calibrated using **ZED****Sensor****Viewer** tool.
### variable effective_rate
```csharp
float effective_rate;
```
Realtime data acquisition rate in hertz (Hz).
---
# sl::Matrix3x3
**Module:** **Core Module**
Structure representing a generic 3*3 matrix.
## Public Functions Documentation
### function multiply
```csharp
float3 multiply(
float3 a
)
```
Gives the result of the multiplication between a sl.Matrix3x3 and a specified scalar value.
**Parameters**:
* **a** Scalar value to multiple the sl.Matrix3x3 with.
**Return**: The result of the multiplication with the scalar given as input.
## Public Attributes Documentation
### variable m
```csharp
float[] m;
```
Array containing the values fo the 3*3 matrix.
---
# sl::ObjectData
**Module:** **Object Detection Module**
Structure containing data of a detected object such as its boundingBox, label, id and its 3D position.
## Public Attributes Documentation
### variable id
```csharp
int id;
```
Object identification number.
**Note**:
* Only available if sl.ObjectDetectionParameters.enableTracking is activated.
* Otherwise, it will be set to -1.
It is used as a reference when tracking the object through the frames.
### variable uniqueObjectId
```csharp
string uniqueObjectId;
```
Unique id to help identify and track AI detections.
It can be either generated externally, or by using sl.Camera.GenerateUniqueID() or left empty.
### variable rawLabel
```csharp
int rawLabel;
```
Object raw label.
It is forwarded from sl.CustomBoxObjectData when using sl.OBJECT_DETECTION_MODEL.CUSTOM_BOX_OBJECTS.
### variable label
```csharp
sl.OBJECT_CLASS label;
```
Object class/category to identify the object type.
### variable sublabel
```csharp
sl.OBJECT_SUBCLASS sublabel;
```
Object sub-class/sub-category to identify the object type.
### variable objectTrackingState
```csharp
sl.OBJECT_TRACKING_STATE objectTrackingState;
```
Object tracking state.
### variable actionState
```csharp
sl.OBJECT_ACTION_STATE actionState;
```
Object action state.
### variable position
```csharp
Vector3 position;
```
Object 3D centroid.
**Note**: It is defined in sl.InitParameters.coordinateUnits and expressed in sl.RuntimeParameters.measure3DReferenceFrame.
### variable confidence
```csharp
float confidence;
```
Detection confidence value of the object.
From 0 to 100, a low value means the object might not be localized perfectly or the label (sl.OBJECT_CLASS) is uncertain.
### variable mask
```csharp
System.IntPtr mask;
```
Pointer of the sl.Mat representing the mask defining which pixels which belong to the object (in boundingBox and set to 255) and those of the background (set to 0). To access the pixels values, create a new sl.Mat from that IntPtr. Ex: sl.Mat mat = new sl.Mat(mask);
**Warning**:
* The mask information is only available for tracked objects (sl.OBJECT_TRACKING_STATE.OK) that have a valid depth.
* Otherwise, the mask will not be initialized.
### variable boundingBox2D
```csharp
Vector2[] boundingBox2D;
```
2D bounding box of the object represented as four 2D points starting at the top left corner and rotation clockwise.
**Note**: Expressed in pixels on the original image resolution, `[0, 0]` is the top left corner.
```cpp
A ------ B
| Object |
D ------ C
```
### variable headPosition
```csharp
Vector3 headPosition;
```
3D centroid of the head of the object (a person).
**Note**: It is defined in sl.InitParameters.coordinateUnits and expressed in sl.RuntimeParameters.measure3DReferenceFrame.
**Warning**: Not available with sl.OBJECT_DETECTION_MODEL.MULTI_CLASS_BOX_XXX.
### variable velocity
```csharp
Vector3 velocity;
```
Object 3D velocity.
**Note**: It is defined in `sl.InitParameters.coordinateUnits / s` and expressed in sl.RuntimeParameters.measure3DReferenceFrame.
### variable dimensions
```csharp
Vector3 dimensions;
```
3D object dimensions: width, height, length.
**Note**: It is defined in sl.InitParameters.coordinateUnits and expressed in sl.RuntimeParameters.measure3DReferenceFrame.
### variable boundingBox
```csharp
Vector3[] boundingBox;
```
3D bounding box of the object represented as eight 3D points.
**Note**: It is defined in sl.InitParameters.coordinateUnits and expressed in sl.RuntimeParameters.measure3DReferenceFrame.
```cpp
1 ------ 2
/ /|
0 ------ 3 |
| Object | 6
| |/
4 ------ 7
```
### variable headBoundingBox
```csharp
Vector3[] headBoundingBox;
```
3D bounding box of the head of the object (a person) represented as eight 3D points.
**Note**: It is defined in sl.InitParameters.coordinateUnits and expressed in sl.RuntimeParameters.measure3DReferenceFrame.
**Warning**: Not available with sl.OBJECT_DETECTION_MODEL.MULTI_CLASS_BOX_XXX.
### variable headBoundingBox2D
```csharp
Vector2[] headBoundingBox2D;
```
2D bounding box of the head of the object (a person) represented as four 2D points starting at the top left corner and rotation clockwise.
**Note**: Expressed in pixels on the original image resolution, `[0, 0]` is the top left corner.
**Warning**: Not available with sl.OBJECT_DETECTION_MODEL.MULTI_CLASS_BOX_XXX.
### variable positionCovariance
```csharp
float[] positionCovariance;
```
Covariance matrix of the 3D position.
**Note**: It is represented by its upper triangular matrix value
```cpp
= [p0, p1, p2]
[p1, p3, p4]
[p2, p4, p5]
```
where pi is `positionCovariance[i]`
---
# sl::ObjectDetectionRuntimeParameters
**Module:** **Object Detection Module**
Structure containing a set of runtime parameters for the object detection module. More...
## Detailed Description
```csharp
struct sl::ObjectDetectionRuntimeParameters;
```
Structure containing a set of runtime parameters for the object detection module.
**Note**: Parameters can be adjusted by the user.
The default constructor sets all parameters to their default settings.
## Public Attributes Documentation
### variable detectionConfidenceThreshold
```csharp
float detectionConfidenceThreshold;
```
Confidence threshold.
**Note**:
* If the scene contains a lot of objects, increasing the confidence can slightly speed up the process, since every object instance is tracked.
* detectionConfidenceThreshold is used as a fallback when sl::ObjectDetectionRuntimeParameters.objectConfidenceThreshold is partially set.
From 1 to 100, with 1 meaning a low threshold, more uncertain objects and 99 very few but very precise objects.
Default: 20.f
### variable objectClassFilter
```csharp
int[] objectClassFilter;
```
Defines which object types to detect and track.
**Note**:
* Fewer object types can slightly speed up the process since every object is tracked.
* Will output only the selected classes.
Default: `new int[(int)sl.OBJECT_CLASS.LAST)]` (all classes are tracked)
In order to get all the available classes, the filter list must be empty :
```cpp
objectClassFilter = new int[(int)sl.OBJECT_CLASS.LAST)];
```
To select a set of specific object classes, like vehicles, persons and animals for instance:
```cpp
objectClassFilter[(int)sl.OBJECT_CLASS.PERSON] = Convert.ToInt32(true);
objectClassFilter[(int)sl.OBJECT_CLASS.VEHICLE] = Convert.ToInt32(true);
objectClassFilter[(int)sl.OBJECT_CLASS.ANIMAL] = Convert.ToInt32(true);
```
### variable objectConfidenceThreshold
```csharp
int[] objectConfidenceThreshold;
```
Array of confidence thresholds for each class (can be empty for some classes).
**Note**: sl::ObjectDetectionRuntimeParameters.detectionConfidenceThreshold will be taken as fallback/default value.
### variable objectTrackingParameters
```csharp
ObjectTrackingParameters objectTrackingParameters;
```
Global tracking parameters.
### variable objectClassTrackingParameters
```csharp
ObjectTrackingParameters[] objectClassTrackingParameters;
```
Array of tracking parameters for each class (can be empty for some classes).
**Note**: sl::ObjectDetectionRuntimeParameters.objectTrackingParameters will be taken as fallback/default value.
---
# sl::ObjectTrackingParameters
**Module:** **Object Detection Module**
Structure containing a set of parameters for the object tracking module. More...
## Detailed Description
```csharp
struct sl::ObjectTrackingParameters;
```
Structure containing a set of parameters for the object tracking module.
**Note**: Parameters can be adjusted by the user.
The default constructor sets all parameters to their default settings.
## Public Attributes Documentation
### variable objectAccelerationPreset
```csharp
OBJECT_ACCELERATION_PRESET objectAccelerationPreset;
```
Preset defining the expected maximum acceleration of the tracked object.
Determines how the ZED SDK interprets object acceleration, affecting tracking behavior and predictions.
### variable velocitySmoothingFactor
```csharp
float velocitySmoothingFactor;
```
Control the smoothing of the velocity estimation. Manually override the acceleration preset.
Values between 0.0 and 1.0.
* High value (closer to 1.0): Very smooth, but may lag behind rapid changes.
* Low value (closer to 0.0): Very responsive to velocity changes, but may be jittery.
* 0.5: ZED SDK base tuning. Balanced smoothing and responsiveness. A negative value (e.g. -1) lets the ZED SDK interpret velocitySmoothingFactor. Default: -1
### variable minVelocityThreshold
```csharp
float minVelocityThreshold;
```
Threshold to force an object's velocity to zero.
If the calculated speed (m/s) is below this threshold, the object is considered static. This helps eliminate drift on stationary objects. A negative value (e.g. -1) lets the ZED SDK interpret minVelocityThreshold. Default: -1
### variable predictionTimeoutS
```csharp
float predictionTimeoutS;
```
Duration to keep predicting a track's position after occlusion.
When an object is no longer visible (occluded or out of frame), the tracker will predict its position for this duration before deleting the track.
* Short (e.g., 0.2s): Prevents "ghost" objects but may break tracks during short occlusions.
* Long (e.g., 2.0s): Maintains ID during long occlusions but may report objects that are gone. A negative value (e.g. -1) lets the ZED SDK interpret predictionTimeoutS. Default: -1
### variable minConfirmationTimeS
```csharp
float minConfirmationTimeS;
```
Minimum confirmation time required to validate a track.
The minimum duration (in seconds) an object must be continuously detected before it is reported as a valid track. Helps filter out spurious false positives that appear only briefly. A negative value (e.g. -1) lets the ZED SDK interpret minConfirmationTimeS. Default: -1
---
# sl::Objects
**Module:** **Object Detection Module**
Structure containing the results of the object detection module. It contains the number of object in the scene (numObject) and the objectData structure for each object. More...
## Detailed Description
```csharp
struct sl::Objects;
```
Structure containing the results of the object detection module. It contains the number of object in the scene (numObject) and the objectData structure for each object.
**Note**:
* Since the data is transmitted from C++ to C#, the size of the structure must be constant.
* Therefore, there is a limitation of 75 (sl.Constant.MAX_OBJECTS) objects in the image.
## Public Functions Documentation
### function GetObjectDataFromId
```csharp
bool GetObjectDataFromId(
ref sl.ObjectData objectData,
int objectDataId
)
```
Function that looks for a given object id in the current objects list.
**Parameters**:
* **objectData** [Out] sl.ObjectData to fill if the search succeeded.
* **objectDataId** [In] Id of the sl.ObjectData to search.
**Return**: True if found, otherwise False.
## Public Attributes Documentation
### variable numObject
```csharp
int numObject;
```
Number of detected objects.
**Note**: You can use it to iterate through the objectData array.
### variable timestamp
```csharp
ulong timestamp;
```
Timestamp corresponding to the frame acquisition.
This value is especially useful for the async mode to synchronize the data.
### variable isNew
```csharp
int isNew;
```
Whether objectData has already been retrieved or not.
### variable isTracked
```csharp
int isTracked;
```
Whether both the object tracking and the world orientation has been setup.
### variable detectionModel
```csharp
sl.OBJECT_DETECTION_MODEL detectionModel;
```
Current sl.OBJECT_DETECTION_MODEL used.
### variable objectData
```csharp
ObjectData[] objectData;
```
Array of detected objects.
**Note**:
* Since the data is transmitted from C++ to C#, the size of the structure must be constant.
* Therefore, there is a limitation of 75 (sl.Constant.MAX_OBJECTS) objects in the image.
---
# sl::PlaneData
Structure representing a plane defined by a point and a normal, or a plane equation. More...
## Detailed Description
```csharp
struct sl::PlaneData;
```
Structure representing a plane defined by a point and a normal, or a plane equation.
**Note**: The plane measurements are expressed in reference defined by sl.RuntimeParameters.measure3DReferenceFrame.
## Public Attributes Documentation
### variable ErrorCode
```csharp
sl.ERROR_CODE ErrorCode;
```
sl.ERROR_CODE returned by the ZED SDK when the plane detection was attempted.
### variable Type
```csharp
PLANE_TYPE Type;
```
Type of the plane defined by its orientation.
**Note**: It is deduced from the gravity vector and is therefore not available with on sl.MODEL.ZED.
### variable PlaneNormal
```csharp
Vector3 PlaneNormal;
```
Plane normalized normal vector.
### variable PlaneCenter
```csharp
Vector3 PlaneCenter;
```
Plane center point.
### variable PlaneTransformPosition
```csharp
Vector3 PlaneTransformPosition;
```
Plane position relative to the global reference frame.
### variable PlaneTransformOrientation
```csharp
Quaternion PlaneTransformOrientation;
```
Plane orientation relative to the global reference frame.
### variable PlaneEquation
```csharp
Vector4 PlaneEquation;
```
Plane equation coefficients `{a, b, c, d}`.
**Note**: The plane equation has the following form: `ax + by + cz = d`.
### variable Extents
```csharp
Vector2 Extents;
```
Gets the width and height of the bounding rectangle around the plane contours.
### variable BoundsSize
```csharp
int BoundsSize;
```
Size of Bounds.
### variable Bounds
```csharp
Vector3[] Bounds;
```
Array of 3D points forming a polygon bounds corresponding to the current visible limits of the plane.
---
# sl::PositionalTrackingStatus
**Module:** **Positional Tracking Module**
Lists the different status of positional tracking.
## Public Attributes Documentation
### variable odometryStatus
```csharp
ODOMETRY_STATUS odometryStatus;
```
Represents the current state of Visual-Inertial Odometry (VIO) tracking between the previous frame and the current frame.
### variable spatialMemoryStatus
```csharp
SPATIAL_MEMORY_STATUS spatialMemoryStatus;
```
Represents the current state of camera tracking in the global map.
### variable trackingFusionStatus
```csharp
POSITIONAL_TRACKING_FUSION_STATUS trackingFusionStatus;
```
Represents the current state of positional tracking fusion.
---
# sl::RecordingStatus
**Module:** **Video Module**
Structure containing information about the status of the recording. More...
## Detailed Description
```csharp
struct sl::RecordingStatus;
```
Structure containing information about the status of the recording.
**Note**: For more info, read about the ZED SDK C++ struct it mirrors: [RecordingStatus](https://www.stereolabs.com/docs/api/structsl_1_1RecordingStatus.html)
## Public Attributes Documentation
### variable is_recording
```csharp
bool is_recording;
```
Report if the recording has been enabled.
### variable is_paused
```csharp
bool is_paused;
```
Report if the recording has been paused.
### variable status
```csharp
bool status;
```
Status of current frame.
True for success or false if the frame could not be written in the SVO file.
### variable current_compression_time
```csharp
double current_compression_time;
```
Compression time for the current frame in milliseconds.
### variable current_compression_ratio
```csharp
double current_compression_ratio;
```
Compression ratio (% of raw size) for the current frame.
### variable average_compression_time
```csharp
double average_compression_time;
```
Average compression time in milliseconds since beginning of recording.
### variable average_compression_ratio
```csharp
double average_compression_ratio;
```
Average compression ratio (% of raw size) since beginning of recording.
---
# sl::Rect
Structure defining a 2D rectangle with top-left corner coordinates and width/height in pixels.
## Public Attributes Documentation
### variable x
```csharp
int x;
```
x coordinates of top-left corner.
### variable y
```csharp
int y;
```
y coordinates of top-left corner.
### variable width
```csharp
int width;
```
Width of the rectangle in pixels.
### variable height
```csharp
int height;
```
Height of the rectangle in pixels.
---
# sl::RegionOfInterestParameters
**Module:** **Positional Tracking Module**
Structure containing a set of parameters for the region of interest.
## Public Functions Documentation
### function RegionOfInterestParameters
```csharp
RegionOfInterestParameters(
float depthFarThresholdMeters_ =2.5f,
float imageHeightRatioCutoff_ =0.5f
)
```
### function RegionOfInterestParameters
```csharp
RegionOfInterestParameters(
bool[] autoApplyModule_,
float depthFarThresholdMeters_ =2.5f,
float imageHeightRatioCutoff_ =0.5f
)
```
## Public Attributes Documentation
### variable depthFarThresholdMeters
```csharp
float depthFarThresholdMeters;
```
Filtering how far object in the ROI should be considered, this is useful for a vehicle for instance Default is 2.5meters
### variable imageHeightRatioCutoff
```csharp
float imageHeightRatioCutoff;
```
By default consider only the lower half of the image, can be useful to filter out the sky Default is 0.5, corresponding to the lower half of the image.
### variable autoApplyModule
```csharp
bool[] autoApplyModule;
```
Once computed the ROI computed will be automatically applied.
---
# sl::Resolution
**Module:** **Core Module**
Structure containing the width and height of an image.
## Public Functions Documentation
### function Resolution
```csharp
Resolution(
int width =0,
int height =0
)
```
Default constructor.
**Parameters**:
* **width** Width of the image in pixels.
* **height** Height of the image in pixels.
## Public Attributes Documentation
### variable width
```csharp
int width;
```
Width of the image in pixels.
### variable height
```csharp
int height;
```
Height of the image in pixels.
---
# sl::SVOData
**Module:** **Depth Sensing Module**
Structure containing data that can be stored in and retrieved from SVOs. That information will be ingested with sl.Camera.ingestDataIntoSVO and retrieved with sl.Camera.retrieveSVOData.
## Public Functions Documentation
### function GetContent
```csharp
string GetContent()
```
**Return**:
### function SetContent
```csharp
void SetContent(
string c
)
```
**Parameters**:
* **c**
### function GetKey
```csharp
string GetKey()
```
**Return**:
### function SetKey
```csharp
void SetKey(
string k
)
```
**Parameters**:
* **k**
## Public Attributes Documentation
### variable key
```csharp
IntPtr key;
```
Key used to retrieve the data stored into SVOData's content. The key size must not exceed 128 characters.
### variable keySize
```csharp
int keySize;
```
Size of the key string
### variable content
```csharp
IntPtr content;
```
Content stored as SVOData Allow any type of content, including raw data like compressed images of json.
### variable contentSize
```csharp
int contentSize;
```
Size of the content data.
### variable timestamp
```csharp
ulong timestamp;
```
Timestamp of the data (in nanoseconds).
---
# sl::SensorParameters
**Module:** **Core Module**
Structure containing information about a single sensor available in the current device. More...
## Detailed Description
```csharp
struct sl::SensorParameters;
```
Structure containing information about a single sensor available in the current device.
**Note**:
* This structure is meant to be used as a read-only container.
* Editing any of its fields will not impact the ZED SDK.
Information about the camera sensors is available in the sl.CameraInformation struct returned by sl.Camera.GetCameraInformation().
## Public Attributes Documentation
### variable type
```csharp
SENSOR_TYPE type;
```
Type of the sensor.
### variable resolution
```csharp
float resolution;
```
Resolution of the sensor.
### variable sampling_rate
```csharp
float sampling_rate;
```
Sampling rate (or ODR) of the sensor.
### variable range
```csharp
float2 range;
```
Range of the sensor (minimum: `range.x`, maximum: `range.y`).
### variable noise_density
```csharp
float noise_density;
```
White noise density given as continuous (frequency-independent).
**Note**:
* The units will be expressed in `sensor_unit / √(Hz)`.
* `NAN` if the information is not available.
### variable random_walk
```csharp
float random_walk;
```
Random walk derived from the Allan Variance given as continuous (frequency-independent).
**Note**:
* The units will be expressed in `sensor_unit / √(Hz)`.
* `NAN` if the information is not available.
### variable sensor_unit
```csharp
SENSORS_UNIT sensor_unit;
```
Unit of the sensor.
### variable isAvailable
```csharp
bool isAvailable;
```
Whether the sensor is available in your camera.
---
# sl::SensorsConfiguration
**Module:** **Core Module**
Structure containing information about all the sensors available in the current device. More...
## Detailed Description
```csharp
struct sl::SensorsConfiguration;
```
Structure containing information about all the sensors available in the current device.
**Note**:
* This structure is meant to be used as a read-only container.
* Editing any of its fields will not impact the ZED SDK.
Information about the camera sensors is available in the sl.CameraInformation struct returned by sl.Camera.GetCameraInformation().
## Public Functions Documentation
### function isSensorAvailable
```csharp
bool isSensorAvailable(
SENSOR_TYPE sensor_type
)
```
Checks if a sensor is available on the.
**Parameters**:
* **sensor_type** Sensor type to check.
**Return**: true if the sensor is available on the device, otherwise false.
## Public Attributes Documentation
### variable firmware_version
```csharp
uint firmware_version;
```
Firmware version of the sensor module.
**Note**: 0 if no sensors are available (sl.MODEL.ZED).
### variable camera_imu_rotation
```csharp
float4 camera_imu_rotation;
```
IMU to left camera rotation (quaternion).
**Note**: It contains the rotation between the IMU frame and camera frame.
### variable camera_imu_translation
```csharp
float3 camera_imu_translation;
```
IMU to left camera translation.
**Note**: It contains the rotation between the IMU frame and camera frame.
### variable imu_magnometer_rotation
```csharp
float4 imu_magnometer_rotation;
```
Magnetometer to IMU rotation (quaternion).
**Note**: It contains rotation between IMU frame and magnetometer frame.
### variable imu_magnometer_translation
```csharp
float3 imu_magnometer_translation;
```
Magnetometer to IMU translation.
**Note**: It contains translation between IMU frame and magnetometer frame.
### variable accelerometer_parameters
```csharp
SensorParameters accelerometer_parameters;
```
Configuration of the accelerometer.
### variable gyroscope_parameters
```csharp
SensorParameters gyroscope_parameters;
```
Configuration of the gyroscope.
### variable magnetometer_parameters
```csharp
SensorParameters magnetometer_parameters;
```
Configuration of the magnetometer.
### variable barometer_parameters
```csharp
SensorParameters barometer_parameters;
```
Configuration of the barometer.
---
# sl::StreamingProperties
**Module:** **Video Module**
Structure containing information about the properties of a streaming device.
## Public Attributes Documentation
### variable ip
```csharp
string ip;
```
IP address of the streaming device.
### variable port
```csharp
ushort port;
```
Streaming port of the streaming device.
Default: 0
### variable serialNumber
```csharp
uint serialNumber;
```
Serial number of the streaming camera.
Default: 0
### variable currentBitrate
```csharp
int currentBitrate;
```
Current bitrate of encoding of the streaming device.
Default: 0
### variable cameraModel
```csharp
sl.MODEL cameraModel;
```
Model of the streaming device.
Default: sl.MODEL.LAST
### variable codec
```csharp
sl.STREAMING_CODEC codec;
```
Current codec used for compression in streaming device.
Default: sl.STREAMING_CODEC.H265_BASED
---
# sl::SynchronizationParameter
**Module:** **Fusion Module**
Configuration parameters for data synchronization.
## Public Functions Documentation
### function SynchronizationParameter
```csharp
SynchronizationParameter(
double windowSize,
double dataSourceTimeout,
bool keepLastData,
double maximumLateness
)
```
Default constructor.
## Public Attributes Documentation
### variable windowSize
```csharp
double windowSize;
```
Size of synchronization windows in milliseconds. The synchronization window is used by the synchronizer to return all data present inside the current synchronization window.For efficient fusion, the synchronization window size is expected to be equal to the mean `grab()` duration of the camera at the lowest FPS. If not provided, the fusion SDK will compute it from the data's sources. Default value: 0
### variable dataSourceTimeout
```csharp
double dataSourceTimeout;
```
Duration in milliseconds before considering a camera as inactive if no more data is present (for example camera disconnection). The data_source_timeout parameter specifies the duration to wait before considering a camera as inactive if no new data is received within the specified time frame.
### variable keepLastData
```csharp
bool keepLastData;
```
Determines whether to include the last data returned by a source in the final synchronized data. If the keep_last_data parameter is set to true and no data is present in the current synchronization window, the last data returned by the source will be included in the final synchronized data. This ensures continuity even in the absence of fresh data.
### variable maximumLateness
```csharp
double maximumLateness;
```
Maximum duration in milliseconds allowed for data to be considered as the last data. The maximum_lateness parameter sets the maximum duration within which data can be considered as the last available data. If the duration between the last received data and the current synchronization window exceeds this value, the data will not be included as the last data in the final synchronized output.
---
# sl::TemperatureSensorData
**Module:** **Core Module**
Structure containing data from the temperature sensors.
## Public Attributes Documentation
### variable imu_temp
```csharp
float imu_temp;
```
Temperature in °C at the IMU location (-100 if not available).
### variable barometer_temp
```csharp
float barometer_temp;
```
Temperature in °C at the barometer location (-100 if not available).
### variable onboard_left_temp
```csharp
float onboard_left_temp;
```
Temperature in °C next to the left image sensor (-100 if not available).
### variable onboard_right_temp
```csharp
float onboard_right_temp;
```
Temperature in °C next to the right image sensor (-100 if not available).
---
# sl::UTM
**Module:** **Fusion Module**
Represents a world position in UTM format.
## Public Attributes Documentation
### variable northing
```csharp
double northing;
```
Northing coordinate.
### variable easting
```csharp
double easting;
```
Easting coordinate.
### variable gamma
```csharp
double gamma;
```
Gamma coordinate.
### variable UTMZone
```csharp
string UTMZone;
```
UTMZone of the coordinate.
---
# sl::VoxelMeasureParameters
**Module:** **Depth Sensing Module**
Parameters controlling voxel decimation in Camera.RetrieveVoxelMeasure.
## Public Functions Documentation
### function VoxelMeasureParameters
```csharp
VoxelMeasureParameters(
float voxelSize =-1.0f,
bool centroid =true,
VOXELIZATION_MODE resolutionMode =VOXELIZATION_MODE.STEREO_UNCERTAINTY,
float resolutionScale =0.2f
)
```
## Public Attributes Documentation
### variable voxelSize
```csharp
float voxelSize;
```
Voxel grid cell size in coordinate units. Default: -1 (100mm equivalent).
### variable centroid
```csharp
bool centroid;
```
true = centroid, false = voxel grid center. Default: true.
### variable resolutionMode
```csharp
VOXELIZATION_MODE resolutionMode;
```
How voxel size adapts with depth. Default: STEREO_UNCERTAINTY.
### variable resolutionScale
```csharp
float resolutionScale;
```
Scale factor for depth-adaptive growth. Default: 0.2.
---
# sl::char2
Represents a 2D vector of uchars for use on both the CPU and GPU.
## Public Attributes Documentation
### variable r
```csharp
byte r;
```
### variable g
```csharp
byte g;
```
---
# sl::char3
Represents a 3D vector of uchars for use on both the CPU and GPU.
## Public Attributes Documentation
### variable r
```csharp
byte r;
```
### variable g
```csharp
byte g;
```
### variable b
```csharp
byte b;
```
---
# sl::char4
Represents a 4D vector of uchars for use on both the CPU and GPU.
## Public Attributes Documentation
### variable r
```csharp
byte r;
```
### variable g
```csharp
byte g;
```
### variable b
```csharp
byte b;
```
### variable a
```csharp
byte a;
```
---
# sl::float2
Represents a 2D vector of floats for use on both the CPU and GPU.
## Public Functions Documentation
### function float2
```csharp
float2(
float m_x,
float m_y
)
```
Constructor : Creates a float2 whose elements have the specified values.
**Parameters**:
* **m_x** value to assign to the x field
* **m_y** value to assign to the y field
### function add
```csharp
float2 add(
float2 b
)
```
### function sub
```csharp
float2 sub(
float2 b
)
```
## Public Attributes Documentation
### variable x
```csharp
float x;
```
the x component of the float2.
### variable y
```csharp
float y;
```
the y component of the float2.
---
# sl::float3
Represents a 3D vector of floats for use on both the CPU and GPU.
## Public Functions Documentation
### function float3
```csharp
float3(
float m_x,
float m_y,
float m_z
)
```
Constructor : Creates a float3 whose elements have the specified values.
**Parameters**:
* **m_x** value to assign to the x field.
* **m_y** value to assign to the y field.
* **m_z** value to assign to the z field
### function add
```csharp
float3 add(
float3 b
)
```
Returns the addition of two float3
**Parameters**:
* **b**
**Return**: The second vector to add.
### function sub
```csharp
float3 sub(
float3 b
)
```
Returns the substraction of two float3
**Parameters**:
* **b** The second vector.
**Return**:
### function divide
```csharp
void divide(
float a
)
```
Divides the float3 by a specified scalar value
**Parameters**:
* **a** The scalar value
### function multiply
```csharp
float3 multiply(
float a
)
```
Multiplies the float3 by a specified scalar value
**Parameters**:
* **a** The scalar value
**Return**:
### function norm
```csharp
float norm()
```
Returns the length of the float3
**Return**:
### function dot
```csharp
float dot(
float3 b
)
```
Returns the dot product of two vectors.
**Parameters**:
* **b** The second vector
**Return**:
### function cross
```csharp
float3 cross(
float3 b
)
```
Returns the cross product of two vectors
**Parameters**:
* **b** The second vector
**Return**:
## Public Attributes Documentation
### variable x
```csharp
float x;
```
The x component of the float3.
### variable y
```csharp
float y;
```
the y component of the float3.
### variable z
```csharp
float z;
```
the z component of the float3.
---
# sl::float4
Represents a 4D vector of floats for use on both the CPU and GPU.
## Public Attributes Documentation
### variable x
```csharp
float x;
```
The x component of the float4.
### variable y
```csharp
float y;
```
the y component of the float4.
### variable z
```csharp
float z;
```
the z component of the float4.
### variable w
```csharp
float w;
```
The w component of the float4.
---
# src/ZEDCamera.cs
## Namespaces
| Name |
| -------------- |
| **sl** |
| **System::Collections::Generic** |
| **System** |
| **System::Runtime::InteropServices** |
| **System::Numerics** |
## Classes
| | Name |
| -------------- | -------------- |
| class | **sl::Camera**
This class serves as the primary interface between the camera and the various features provided by the SDK. |
---
# src/ZEDCommon.cs
## Namespaces
| Name |
| -------------- |
| **sl** |
## Classes
| | Name |
| -------------- | -------------- |
| class | **sl::ZEDCommon** |
| struct | **sl::Matrix3x3**
Structure representing a generic 3*3 matrix. |
| struct | **sl::Resolution**
Structure containing the width and height of an image. |
| struct | **sl::Rect**
Structure defining a 2D rectangle with top-left corner coordinates and width/height in pixels. |
| struct | **sl::CameraConfiguration**
Structure containing information about the camera sensor. |
| struct | **sl::CameraInformation**
Structure containing information of a single camera (serial number, model, input type, etc.) |
| class | **sl::PositionalTrackingParameters**
Class containing a set of parameters for the positional tracking module initialization. |
| struct | **sl::Pose**
Structure containing positional tracking data giving the position and orientation of the camera in 3D space. |
| struct | **sl::RegionOfInterestParameters**
Structure containing a set of parameters for the region of interest. |
| struct | **sl::PositionalTrackingStatus**
Lists the different status of positional tracking. |
| struct | **sl::ImuData**
Structure containing data from the IMU sensor. |
| struct | **sl::BarometerData**
Structure containing data from the barometer sensor. |
| struct | **sl::MagnetometerData**
Structure containing data from the magnetometer sensor. |
| struct | **sl::TemperatureSensorData**
Structure containing data from the temperature sensors. |
| struct | **sl::SensorsData**
Structure containing all sensors data (except image sensors) to be used for positional tracking or environment study. |
| struct | **sl::SensorParameters**
Structure containing information about a single sensor available in the current device. |
| struct | **sl::SensorsConfiguration**
Structure containing information about all the sensors available in the current device. |
| class | **sl::RuntimeParameters**
Class containing parameters that defines the behavior of sl.Camera.Grab(). |
| struct | **sl::CameraParameters**
Structure containing the intrinsic parameters of a camera. |
| struct | **sl::CalibrationParameters**
Structure containing intrinsic and extrinsic parameters of the camera (translation and rotation). |
| struct | **sl::SVOData**
Structure containing data that can be stored in and retrieved from SVOs. That information will be ingested with sl.Camera.ingestDataIntoSVO and retrieved with sl.Camera.retrieveSVOData. |
| struct | **sl::VoxelMeasureParameters**
Parameters controlling voxel decimation in Camera.RetrieveVoxelMeasure. |
| class | **sl::InitParameters**
Class containing the options used to initialize the sl.Camera object. |
| struct | **sl::RecordingParameters**
Structure containing the options used to record. |
| struct | **sl::StreamingParameters**
Structure containing the options used to stream with the ZED SDK. |
| struct | **sl::DeviceProperties**
Structure containing information about the properties of a camera. |
| struct | **sl::StreamingProperties**
Structure containing information about the properties of a streaming device. |
| struct | **sl::HealthStatus**
Structure containing the self-diagnostic results of the camera (image, depth, sensor health). Retrieved via Camera.GetHealthStatus. |
| struct | **sl::RecordingStatus**
Structure containing information about the status of the recording. |
| struct | **sl::InputType**
Structure defining the input type used in the ZED SDK. |
| class | **sl::PlaneDetectionParameters**
Class containing a set of parameters for the plane detection functionality. |
| class | **sl::SpatialMappingParameters**
Class containing a set of parameters for the spatial mapping module. |
| class | **sl::Mesh**
Class representing a mesh and containing the geometric (and optionally texture) data of the scene captured by the spatial mapping module. |
| class | **sl::FusedPointCloud**
A fused point cloud contains both geometric and color data of the scene captured by spatial mapping. |
| struct | **sl::Chunk**
Class representing a sub-mesh containing local vertices and triangles. |
| struct | **sl::PlaneData**
Structure representing a plane defined by a point and a normal, or a plane equation. |
| struct | **sl::BatchParameters**
Structure containing a set of parameters for batch object detection. |
| struct | **sl::AI_Model_status**
Structure containing AI model status. |
| struct | **sl::ObjectDetectionParameters**
Structure containing a set of parameters for the object detection module. |
| struct | **sl::ObjectTrackingParameters**
Structure containing a set of parameters for the object tracking module. |
| struct | **sl::ObjectDetectionRuntimeParameters**
Structure containing a set of runtime parameters for the object detection module. |
| struct | **sl::CustomObjectDetectionProperties**
Structure containing a set of runtime properties of a certain class ID for the object detection module using a custom model. |
| struct | **sl::CustomObjectDetectionRuntimeParameters** |
| struct | **sl::BodyTrackingParameters**
Structure containing a set of parameters for the body tracking module. |
| struct | **sl::BodyTrackingRuntimeParameters**
Structure containing a set of runtime parameters for the body tracking module. |
| struct | **sl::ObjectData**
Structure containing data of a detected object such as its boundingBox, label, id and its 3D position. |
| struct | **sl::CustomBoxObjectData**
Structure that store externally detected objects. |
| struct | **sl::CustomMaskObjectData**
Structure that store external 2D mask. |
| struct | **sl::Objects**
Structure containing the results of the object detection module. It contains the number of object in the scene (numObject) and the objectData structure for each object. |
| struct | **sl::CovarMatrix**
Full covariance matrix for position (3x3). Only 6 values are necessary [p0, p1, p2] [p1, p3, p4] [p2, p4, p5] |
| struct | **sl::BodyData**
Structure containing data of a detected body/person such as its headBoundingBox, id and its 3D position. |
| struct | **sl::Bodies**
Structure containing the results of the body tracking module. |
| class | **sl::ObjectsBatch**
Class containing batched data of a detected objects from the object detection module. |
| struct | **sl::SynchronizationParameter**
Configuration parameters for data synchronization. |
| struct | **sl::InitFusionParameters**
Holds the options used to initialize the Fusion object. |
| struct | **sl::CommunicationParameters**
Holds the communication parameter to configure the connection between senders and receiver |
| struct | **sl::FusionConfiguration**
Stores the Fusion configuration, can be read from /write to a Json file. |
| struct | **sl::BodyTrackingFusionParameters**
Holds the options used to initialize the body tracking module of the Fusion. |
| struct | **sl::BodyTrackingFusionRuntimeParameters**
Holds the options used to change the behavior of the body tracking module at runtime. |
| struct | **sl::CameraIdentifier**
Used to identify a specific camera in the Fusion API |
| struct | **sl::CameraMetrics**
Holds the metrics of a sender in the fusion process. |
| struct | **sl::FusionMetrics**
Holds the metrics of the fusion process. |
| struct | **sl::FusedPositionalTrackingStatus**
Class containing the overall position fusion status |
| struct | **sl::Landmark**
Represents a 3d landmark. |
| struct | **sl::Landmark2D**
Represents a 2d landmark. |
| struct | **sl::GNSSData**
Structure containing GNSS data to be used for positional tracking as prior. |
| struct | **sl::GeoPose**
Holds Geo reference position. |
| struct | **sl::ECEF**
Represents a world position in ECEF format. |
| struct | **sl::ENU**
Represents a world position in ENU format. |
| struct | **sl::LatLng**
Represents a world position in LatLng format. |
| struct | **sl::UTM**
Represents a world position in UTM format. |
| class | **sl::GNSSCalibrationParameters**
Holds the options used for calibrating GNSS / VIO. |
| class | **sl::PositionalTrackingFusionParameters**
Holds the options used for initializing the positional tracking fusion module. |
---
# src/ZEDFusion.cs
## Namespaces
| Name |
| -------------- |
| **sl** |
## Classes
| | Name |
| -------------- | -------------- |
| class | **sl::Fusion**
Holds Fusion process data and functions |
| struct | **sl::Fusion::sl_GNSSCalibrationParameters**
DLL-friendly version of GNSSCalibrationParameters (found in ZEDCommon.cs). |
| struct | **sl::Fusion::sl_PositionalTrackingFusionParameters**
DLL-friendly version of PositionalTrackingFusionParameters (found in ZEDCommon.cs). |
---
# src/ZEDMat.cs
## Namespaces
| Name |
| -------------- |
| **sl** |
## Classes
| | Name |
| -------------- | -------------- |
| struct | **sl::char2**
Represents a 2D vector of uchars for use on both the CPU and GPU. |
| struct | **sl::char3**
Represents a 3D vector of uchars for use on both the CPU and GPU. |
| struct | **sl::char4**
Represents a 4D vector of uchars for use on both the CPU and GPU. |
| struct | **sl::float2**
Represents a 2D vector of floats for use on both the CPU and GPU. |
| struct | **sl::float3**
Represents a 3D vector of floats for use on both the CPU and GPU. |
| struct | **sl::float4**
Represents a 4D vector of floats for use on both the CPU and GPU. |
| class | **sl::Mat**
Class representing 1 to 4-channel matrix of float or uchar, stored on CPU and/or GPU side. |
---
# add-on-csharp.txt
---
# csharp-api
## Directories
| Name |
| -------------- |
| **src** |
---
# src
## Files
| Name |
| -------------- |
| **src/ZEDCamera.cs** |
| **src/ZEDCommon.cs** |
| **src/ZEDFusion.cs** |
| **src/ZEDMat.cs** |
---
# release-notes.md
---
# System
---
# System::Collections::Generic
---
# System::Numerics
---
# System::Runtime::InteropServices
---
# std
STL namespace.