sl Namespace Reference

Classes

struct  RecordingStatus
 Recording structure that contains information about SVO. More...
 
class  InitParameters
 Holds the options used to initialize the Camera object.
Once passed to the Camera::open() function, these settings will be set for the entire execution life time of the Camera.
You can get further information in the detailed description bellow.
. More...
 
class  RuntimeParameters
 Parameters that defines the behavior of the grab. More...
 
class  PositionalTrackingParameters
 Parameters for positional tracking initialization. More...
 
class  SpatialMappingParameters
 Sets the spatial mapping parameters. More...
 
class  StreamingParameters
 Sets the streaming parameters. More...
 
class  RecordingParameters
 Sets the recording parameters. More...
 
class  BatchParameters
 sets batch trajectory parameters More...
 
class  ObjectDetectionParameters
 Sets the object detection parameters. More...
 
class  ObjectDetectionRuntimeParameters
 Sets the object detection runtime parameters. More...
 
class  Camera
 This class is the main interface with the camera and the SDK features, such as: video, depth, tracking, mapping, and more.
Find more information in the detailed description below.
. More...
 
class  String
 Defines a string. More...
 
struct  Resolution
 Width and height of an array. More...
 
class  Rect
 Defines a 2D rectangle with top-left corner coordinates and width/height in pixels. More...
 
struct  DeviceProperties
 Properties of a camera. More...
 
struct  StreamingProperties
 Properties of a streaming device. More...
 
class  InputType
 Defines the input type used in the ZED SDK. Can be used to select a specific camera with ID or serial number, or a svo file. More...
 
class  Matrix3f
 Represents a generic 3*3 matrix. More...
 
class  Matrix4f
 Represents a generic 4*4 matrix. More...
 
class  Vector2
 Represents a two dimensions vector for both CPU and GPU. More...
 
class  Vector3
 Represents a three dimensions vector for both CPU and GPU. More...
 
class  Vector4
 Represents a four dimensions vector for both CPU and GPU. More...
 
struct  Timestamp
 Timesamp representation and utilities. More...
 
class  Mat
 The Mat class can handle multiple matrix formats from 1 to 4 channels, with different value types (float or uchar), and can be stored CPU and/or GPU side. More...
 
class  Rotation
 Designed to contain rotation data of the positional tracking. It inherits from the generic Matrix3f. More...
 
class  Translation
 Designed to contain translation data of the positional tracking. More...
 
class  Orientation
 Designed to contain orientation (quaternion) data of the positional tracking. More...
 
class  Transform
 Designed to contain translation and rotation data of the positional tracking. More...
 
struct  CameraParameters
 Intrinsic parameters of a camera. More...
 
struct  CalibrationParameters
 Intrinsic and Extrinsic parameters of the camera (translation and rotation). More...
 
struct  SensorParameters
 Structure containing information about a single sensor available in the current device. More...
 
struct  SensorsConfiguration
 Structure containing information about all the sensors available in the current device. More...
 
struct  CameraConfiguration
 Structure containing information about the camera sensor. More...
 
struct  CameraInformation
 Structure containing information of a single camera (serial number, model, input type, etc.) More...
 
class  Pose
 Contains positional tracking data which gives the position and orientation of the ZED in 3D space. More...
 
class  SensorsData
 Contains all sensors data (except image sensors) to be used for positional tracking or environment study. More...
 
class  ObjectData
 Contains data of a detected object such as its bounding_box, label, id and its 3D position. More...
 
class  Objects
 Contains the result of the object detection module. The detected objects are listed in object_list. More...
 
class  ObjectsBatch
 Contains batched datas of a detected object. More...
 
class  MeshFilterParameters
 Defines the behavior of the sl::Mesh::filter function. More...
 
class  Chunk
 Represents a sub-mesh, it contains local vertices and triangles. More...
 
class  Mesh
 A mesh contains the geometric (and optionally texture) data of the scene captured by spatial mapping. More...
 
class  Plane
 A plane defined by a point and a normal, or a plane equation Other elements can be extracted such as the mesh, the 3D bounds... More...
 
class  PointCloudChunk
 Represents a sub fused point cloud, it contains local vertices and colors. More...
 
class  FusedPointCloud
 A fused point cloud contains both geometric and color data of the scene captured by spatial mapping. More...
 

Enumerations

enum class  SIDE
 defines left,right,both to distinguish between left and right or both sides More...
 
enum  FLIP_MODE : int
 Gives the camera flip mode. More...
 
enum class  RESOLUTION
 Represents the available resolution defined in the cameraResolution list. More...
 
enum class  VIDEO_SETTINGS
 Lists available camera settings for the ZED camera (contrast, hue, saturation, gain...). More...
 
enum class  DEPTH_MODE
 Lists available depth computation modes. More...
 
enum class  SENSING_MODE
 Lists available depth sensing modes. More...
 
enum class  MEASURE
 Lists retrievable measures. More...
 
enum class  VIEW
 Lists available views. More...
 
enum class  TIME_REFERENCE
 Lists specific and particular timestamps. More...
 
enum class  POSITIONAL_TRACKING_STATE
 Lists the different states of positional tracking. More...
 
enum class  AREA_EXPORTING_STATE
 Lists the different states of spatial memory area export. More...
 
enum class  REFERENCE_FRAME
 Defines which type of position matrix is used to store camera path and pose. More...
 
enum class  SPATIAL_MAPPING_STATE
 Gives the spatial mapping state. More...
 
enum class  SVO_COMPRESSION_MODE
 Lists available compression modes for SVO recording. More...
 
enum class  UNIT
 Lists available unit for measures. More...
 
enum class  COORDINATE_SYSTEM
 Lists available coordinates systems for positional tracking and 3D measures. More...
 
enum class  ERROR_CODE
 Lists error codes in the ZED SDK. More...
 
enum class  MODEL
 Lists compatible ZED Camera model. More...
 
enum class  INPUT_TYPE
 Lists available input type in SDK. More...
 
enum class  CAMERA_STATE
 List of possible camera state. More...
 
enum class  STREAMING_CODEC
 List of possible camera state. More...
 
enum class  SENSOR_TYPE
 
enum class  SENSORS_UNIT
 List of the available onboard sensors measurement units. More...
 
enum class  DETECTION_MODEL
 List available models for detection. More...
 
enum class  MEM
 List available memory type. More...
 
enum class  COPY_TYPE
 List available copy operation on Mat. More...
 
enum class  MAT_TYPE
 List available Mat formats. More...
 
enum class  OBJECT_CLASS
 Lists available object class. More...
 
enum class  OBJECT_SUBCLASS
 Available object subclass, given as hint, when using object tracking an object can change of OBJECT_SUBCLASS while keeping the same OBJECT_CLASS and id (i.e: frame M: MOTORBIKE, frame N:BICYCLE) More...
 
enum class  OBJECT_TRACKING_STATE
 Lists available object tracking state. More...
 
enum class  OBJECT_ACTION_STATE
 Lists available object action state. More...
 
enum class  BODY_PARTS
 semantic of human body parts and order of ObjectData::keypoint. More...
 
enum class  MESH_FILE_FORMAT
 Lists available mesh file formats. More...
 
enum class  MESH_TEXTURE_FORMAT
 Lists available mesh texture formats. More...
 
enum class  PLANE_TYPE
 List available plane type detected from the orientation. More...
 

Functions

toString (const FLIP_MODE &flip_mode)
 
inline ::std::ostream & operator<< (::std::ostream &os, const FLIP_MODE &flip_mode)
 
sl::Resolution getResolution (RESOLUTION resolution)
 Returns the actual size of the given resolution. More...
 
toString (const SVO_COMPRESSION_MODE &svo_compression)
 
inline ::std::ostream & operator<< (::std::ostream &os, const SVO_COMPRESSION_MODE &svo_compression)
 
toString (const SpatialMappingParameters::MAPPING_RESOLUTION &resolution)
 
std::ostream & operator<< (std::ostream &os, const SpatialMappingParameters::MAPPING_RESOLUTION &resolution)
 
String toString (const SpatialMappingParameters::MAPPING_RANGE &range)
 
std::ostream & operator<< (std::ostream &os, const SpatialMappingParameters::MAPPING_RANGE &range)
 
String toString (const SpatialMappingParameters::SPATIAL_MAP_TYPE &map_type)
 
std::ostream & operator<< (std::ostream &os, const SpatialMappingParameters::SPATIAL_MAP_TYPE &map_type)
 
String toVerbose (const ERROR_CODE &errorCode)
 Return a text explaining how to fix the given ERROR_CODE. More...
 
*String model2str (MODEL model)
 
String errorCode2str (ERROR_CODE errorCode)
 
String unit2str (UNIT unit)
 
UNIT str2unit (String unit)
 
void sleep_ms (int time)
 Tells the program to wait for x ms. More...
 
void sleep_us (int time)
 Tells the program to wait for x us. More...
 
Rotation computeRotationMatrixFromGravity (sl::float3 axis_to_align, sl::float3 gravity_vector)
 Compute the rotation matrix from the gravity vector : the rotation can used to find the world rotation from the gravity of an IMU. More...
 
Matrix3f getCoordinateTransformConversion3f (COORDINATE_SYSTEM coord_system_src, COORDINATE_SYSTEM coord_system_dst)
 Get the coordinate transform conversion matrix to change coordinate system. More...
 
Matrix4f getCoordinateTransformConversion4f (COORDINATE_SYSTEM coord_system_src, COORDINATE_SYSTEM coord_system_dst)
 Get the coordinate transform conversion matrix to change coordinate system. More...
 
ERROR_CODE convertCoordinateSystem (Mat &floatMat, COORDINATE_SYSTEM coord_system_src, COORDINATE_SYSTEM coord_system_dst, MEM mem=MEM::CPU)
 Change the coordinate system of a matrix. More...
 
ERROR_CODE convertCoordinateSystem (Transform &motionMat, COORDINATE_SYSTEM coord_system_src, COORDINATE_SYSTEM coord_system_dst)
 Change the coordinate system of a transform matrix. More...
 
float getUnitScale (UNIT unit_src, UNIT unit_dst)
 Get the unit factor to change units. More...
 
ERROR_CODE convertUnit (Mat &floatMat, UNIT unit_src, UNIT unit_dst, MEM mem=MEM::CPU)
 Change the unit of a matrix. More...
 
ERROR_CODE convertUnit (Transform &motionMat, UNIT unit_src, UNIT unit_dst)
 Change the unit (of the translations) of a transform matrix. More...
 
OBJECT_CLASS getObjectClass (OBJECT_SUBCLASS object_type)
 
std::vector< OBJECT_SUBCLASSgetObjectSubClasses (OBJECT_CLASS object_type)
 
int getIdx (BODY_PARTS part)
 return associated index of each BODY_PART More...
 
toString (const MESH_FILE_FORMAT &mesh_frmt)
 
std::ostream & operator<< (std::ostream &os, const MESH_FILE_FORMAT &mesh_frmt)
 
toString (const MESH_TEXTURE_FORMAT &text_frmt)
 
std::ostream & operator<< (std::ostream &os, const MESH_TEXTURE_FORMAT &text_frmt)
 
toString (const MeshFilterParameters::MESH_FILTER &mesh_filter)
 
std::ostream & operator<< (std::ostream &os, const MeshFilterParameters::MESH_FILTER &mesh_filter)
 
toString (const PLANE_TYPE &type)
 
std::ostream & operator<< (std::ostream &os, const PLANE_TYPE &type)
 

Variables

static const float INVALID_VALUE = NAN
 
const int VIDEO_SETTINGS_VALUE_AUTO = -1
 
const std::vector< std::pair< BODY_PARTS, BODY_PARTS > > BODY_BONES
 Links of human body keypoints, useful for display. More...
 
Unavailable Values
static const float TOO_FAR = INFINITY
 
static const float TOO_CLOSE = -INFINITY
 
static const float OCCLUSION_VALUE = NAN
 

Types definition

typedef float float1
 
typedef Vector2< float > float2
 
typedef Vector3< float > float3
 
typedef Vector4< float > float4
 
typedef unsigned char uchar1
 
typedef Vector2< unsigned char > uchar2
 
typedef Vector3< unsigned char > uchar3
 
typedef Vector4< unsigned char > uchar4
 
typedef double double1
 
typedef Vector2< double > double2
 
typedef Vector3< double > double3
 
typedef Vector4< double > double4
 
typedef unsigned int uint1
 
typedef Vector2< unsigned int > uint2
 
typedef Vector3< unsigned int > uint3
 
typedef Vector4< unsigned int > uint4
 
typedef unsigned short ushort1
 
bool operator< (const Timestamp &lhs, const Timestamp &rhs)
 
bool operator> (const Timestamp &lhs, const Timestamp &rhs)
 
bool operator<= (const Timestamp &lhs, const Timestamp &rhs)
 
bool operator>= (const Timestamp &lhs, const Timestamp &rhs)
 
bool operator== (const Timestamp &lhs, const Timestamp &rhs)
 
bool operator!= (const Timestamp &lhs, const Timestamp &rhs)
 
Timestamp operator+ (Timestamp lhs, const Timestamp &rhs)
 
Timestamp operator- (Timestamp lhs, const Timestamp &rhs)
 
Timestamp operator/ (Timestamp lhs, const Timestamp &rhs)
 
Timestamp operator* (Timestamp lhs, const Timestamp &rhs)
 

Typedef Documentation

◆ float1

typedef float float1

◆ float2

typedef Vector2<float> float2

◆ float3

typedef Vector3<float> float3

◆ float4

typedef Vector4<float> float4

◆ uchar1

typedef unsigned char uchar1

◆ uchar2

typedef Vector2<unsigned char> uchar2

◆ uchar3

typedef Vector3<unsigned char> uchar3

◆ uchar4

typedef Vector4<unsigned char> uchar4

◆ double1

typedef double double1

◆ double2

typedef Vector2<double> double2

◆ double3

typedef Vector3<double> double3

◆ double4

typedef Vector4<double> double4

◆ uint1

typedef unsigned int uint1

◆ uint2

typedef Vector2<unsigned int> uint2

◆ uint3

typedef Vector3<unsigned int> uint3

◆ uint4

typedef Vector4<unsigned int> uint4

◆ ushort1

typedef unsigned short ushort1

Enumeration Type Documentation

◆ SENSOR_TYPE

enum SENSOR_TYPE
strong
Enumerator
ACCELEROMETER 

Three axis Accelerometer sensor to measure the inertial accelerations.

GYROSCOPE 

Three axis Gyroscope sensor to measure the angular velocitiers.

MAGNETOMETER 

Three axis Magnetometer sensor to measure the orientation of the device respect to the earth magnetic field.

BAROMETER 

Barometer sensor to measure the atmospheric pressure.

◆ PLANE_TYPE

enum PLANE_TYPE
strong

List available plane type detected from the orientation.

Enumerator
HORIZONTAL 
VERTICAL 
UNKNOWN 

Function Documentation

◆ toString() [1/9]

* sl::toString ( const FLIP_MODE flip_mode)

Referenced by operator<<().

◆ operator<<() [1/9]

inline ::std::ostream& sl::operator<< ( ::std::ostream &  os,
const FLIP_MODE flip_mode 
)

◆ toString() [2/9]

* sl::toString ( const SVO_COMPRESSION_MODE svo_compression)

◆ operator<<() [2/9]

inline ::std::ostream& sl::operator<< ( ::std::ostream &  os,
const SVO_COMPRESSION_MODE svo_compression 
)

◆ toString() [3/9]

* sl::toString ( const SpatialMappingParameters::MAPPING_RESOLUTION resolution)

◆ operator<<() [3/9]

std::ostream& sl::operator<< ( std::ostream &  os,
const SpatialMappingParameters::MAPPING_RESOLUTION resolution 
)
inline

◆ toString() [4/9]

String sl::toString ( const SpatialMappingParameters::MAPPING_RANGE range)

◆ operator<<() [4/9]

std::ostream& sl::operator<< ( std::ostream &  os,
const SpatialMappingParameters::MAPPING_RANGE range 
)
inline

◆ toString() [5/9]

String sl::toString ( const SpatialMappingParameters::SPATIAL_MAP_TYPE map_type)

◆ operator<<() [5/9]

std::ostream& sl::operator<< ( std::ostream &  os,
const SpatialMappingParameters::SPATIAL_MAP_TYPE map_type 
)
inline

◆ model2str()

* String sl::model2str ( MODEL  model)

◆ errorCode2str()

String sl::errorCode2str ( ERROR_CODE  errorCode)

◆ unit2str()

String sl::unit2str ( UNIT  unit)

◆ str2unit()

UNIT sl::str2unit ( String  unit)

◆ operator<()

bool sl::operator< ( const Timestamp lhs,
const Timestamp rhs 
)
inline

◆ operator>()

bool sl::operator> ( const Timestamp lhs,
const Timestamp rhs 
)
inline

◆ operator<=()

bool sl::operator<= ( const Timestamp lhs,
const Timestamp rhs 
)
inline

◆ operator>=()

bool sl::operator>= ( const Timestamp lhs,
const Timestamp rhs 
)
inline

◆ operator==()

bool sl::operator== ( const Timestamp lhs,
const Timestamp rhs 
)
inline

◆ operator!=()

bool sl::operator!= ( const Timestamp lhs,
const Timestamp rhs 
)
inline

◆ operator+()

Timestamp sl::operator+ ( Timestamp  lhs,
const Timestamp rhs 
)
inline

◆ operator-()

Timestamp sl::operator- ( Timestamp  lhs,
const Timestamp rhs 
)
inline

◆ operator/()

Timestamp sl::operator/ ( Timestamp  lhs,
const Timestamp rhs 
)
inline

◆ operator*()

Timestamp sl::operator* ( Timestamp  lhs,
const Timestamp rhs 
)
inline

◆ computeRotationMatrixFromGravity()

Rotation sl::computeRotationMatrixFromGravity ( sl::float3  axis_to_align,
sl::float3  gravity_vector 
)

Compute the rotation matrix from the gravity vector : the rotation can used to find the world rotation from the gravity of an IMU.

Parameters
axis_to_align: define the axis to align with the gravity, for instance : to align the "y" axis, axis_to_align = (0, 1, 0)'
gravity_vector: the gravity vector, acceleration set by an IMU
Returns
Rotation : rotation matrix, useful for Camera::detectFloorPlane as a gravity prior

◆ getCoordinateTransformConversion3f()

Matrix3f sl::getCoordinateTransformConversion3f ( COORDINATE_SYSTEM  coord_system_src,
COORDINATE_SYSTEM  coord_system_dst 
)

Get the coordinate transform conversion matrix to change coordinate system.

Parameters
coord_system_src: the source coordinate system.
coord_system_dst: the destination coordinate system.
Returns
Matrix3f : transformation matrix, to apply to a float3 point simply multiply by this matrix (pt_coord_dst = tf_matrix * pt_coord_src).

◆ getCoordinateTransformConversion4f()

Matrix4f sl::getCoordinateTransformConversion4f ( COORDINATE_SYSTEM  coord_system_src,
COORDINATE_SYSTEM  coord_system_dst 
)

Get the coordinate transform conversion matrix to change coordinate system.

Parameters
coord_system_src: the source coordinate system.
coord_system_dst: the destination coordinate system.
Returns
Matrix4f : transformation matrix, to apply to a float4 point simply multiply by this matrix (pt_coord_dst = tf_matrix * pt_coord_src).

◆ convertCoordinateSystem() [1/2]

ERROR_CODE sl::convertCoordinateSystem ( Mat floatMat,
COORDINATE_SYSTEM  coord_system_src,
COORDINATE_SYSTEM  coord_system_dst,
MEM  mem = MEM::CPU 
)

Change the coordinate system of a matrix.

Parameters
floatMat: (in/out) matrix to transform, can be either a MAT_TYPE::F32_C4 (the fourth value will be ignored as it contained the color information) or a MAT_TYPE::F32_C3.
coord_system_src: the current coordinate system of floatMat.
coord_system_dst: the destination coordinate system for floatMat.
mem: define which memory should be transformed from floatMat.
Returns
SUCCESS if everything went well, ERROR_CODE::FAILURE otherwise.

◆ convertCoordinateSystem() [2/2]

ERROR_CODE sl::convertCoordinateSystem ( Transform motionMat,
COORDINATE_SYSTEM  coord_system_src,
COORDINATE_SYSTEM  coord_system_dst 
)

Change the coordinate system of a transform matrix.

Parameters
motionMat: (in/out) matrix to transform
coord_system_src: the current coordinate system of motionMat.
coord_system_dst: the destination coordinate system for motionMat.
Returns
SUCCESS if everything went well, ERROR_CODE::FAILURE otherwise.

◆ getUnitScale()

float sl::getUnitScale ( UNIT  unit_src,
UNIT  unit_dst 
)

Get the unit factor to change units.

Parameters
unit_src: the source coordinate system.
unit_dst: the destination coordinate system.
Returns
float : unit scale (pt_coord_dst = factor * pt_coord_src).

◆ convertUnit() [1/2]

ERROR_CODE sl::convertUnit ( Mat floatMat,
UNIT  unit_src,
UNIT  unit_dst,
MEM  mem = MEM::CPU 
)

Change the unit of a matrix.

Parameters
floatMat: (in/out) matrix to transform, can be either a MAT_TYPE::F32_C4 (the fourth value will be ignored as it contained the color information), MAT_TYPE::F32_C3 or a MAT_TYPE::F32_C1.
unit_src: the current unit of floatMat.
unit_dst: the destination unit for floatMat.
mem: define which memory should be transformed from floatMat.
Returns
SUCCESS if everything went well, ERROR_CODE::FAILURE otherwise.

◆ convertUnit() [2/2]

ERROR_CODE sl::convertUnit ( Transform motionMat,
UNIT  unit_src,
UNIT  unit_dst 
)

Change the unit (of the translations) of a transform matrix.

Parameters
motionMat: (in/out) matrix to transform
unit_src: the current unit of motionMat.
unit_dst: the destination unit for motionMat.
Returns
SUCCESS if everything went well, ERROR_CODE::FAILURE otherwise.

◆ getObjectClass()

OBJECT_CLASS sl::getObjectClass ( OBJECT_SUBCLASS  object_type)

◆ getObjectSubClasses()

std::vector<OBJECT_SUBCLASS> sl::getObjectSubClasses ( OBJECT_CLASS  object_type)

◆ toString() [6/9]

* sl::toString ( const MESH_FILE_FORMAT mesh_frmt)

◆ operator<<() [6/9]

std::ostream& sl::operator<< ( std::ostream &  os,
const MESH_FILE_FORMAT mesh_frmt 
)
inline

◆ toString() [7/9]

* sl::toString ( const MESH_TEXTURE_FORMAT text_frmt)

◆ operator<<() [7/9]

std::ostream& sl::operator<< ( std::ostream &  os,
const MESH_TEXTURE_FORMAT text_frmt 
)
inline

◆ toString() [8/9]

* sl::toString ( const MeshFilterParameters::MESH_FILTER mesh_filter)

◆ operator<<() [8/9]

std::ostream& sl::operator<< ( std::ostream &  os,
const MeshFilterParameters::MESH_FILTER mesh_filter 
)
inline

◆ toString() [9/9]

* sl::toString ( const PLANE_TYPE type)

◆ operator<<() [9/9]

std::ostream& sl::operator<< ( std::ostream &  os,
const PLANE_TYPE type 
)
inline

Variable Documentation

◆ TOO_FAR

const float TOO_FAR = INFINITY
static

Defines an unavailable depth value that is above the depth Max value.

◆ TOO_CLOSE

const float TOO_CLOSE = -INFINITY
static

Defines an unavailable depth value that is below the depth Min value.

◆ OCCLUSION_VALUE

const float OCCLUSION_VALUE = NAN
static

Defines an unavailable depth value that is on an occluded image area.

◆ INVALID_VALUE

const float INVALID_VALUE = NAN
static

◆ VIDEO_SETTINGS_VALUE_AUTO

const int VIDEO_SETTINGS_VALUE_AUTO = -1