Triclops SDK
4.0.3.0
Functions
Camera configuration functions

Functions

enum TriclopsError triclopsGetBaseline (const TriclopsContext context, float *baseline)
 Retrieves the baseline of the cameras. More...
 
enum TriclopsError triclopsGetCameraConfiguration (const TriclopsContext context, TriclopsCameraConfiguration *config)
 Retrieves the current camera configuration for the stereo pipeline. More...
 
enum TriclopsError triclopsGetDeviceConfiguration (const TriclopsContext context, TriclopsCameraConfiguration *config)
 Retrieves the current camera configuration for the stereo pipeline. More...
 
enum TriclopsError triclopsGetFocalLength (const TriclopsContext context, float *focallength)
 Retrieves the focal length of the cameras. More...
 
enum TriclopsError triclopsGetImageCenter (const TriclopsContext context, float *centerRow, float *centerCol)
 Returns the optical center for pinhole calculations.It is important that the context already has the resolution set. If triclopsSetResolution is not set, the returned value cannot be used for calculations. This image center can be used as the position in the image plane of the optical center for pinhole camera calculations. More...
 
enum TriclopsError triclopsGetSerialNumber (const TriclopsContext context, int *serialNumber)
 Retrieves the serial number of the camera associated with a provided context. More...
 
enum TriclopsError triclopsSetCameraConfiguration (const TriclopsContext context, TriclopsCameraConfiguration config)
 Sets a new camera configuration for the stereo pipeline. More...
 

Detailed Description

Function Documentation

enum TriclopsError triclopsGetBaseline ( const TriclopsContext  context,
float *  baseline 
)

Retrieves the baseline of the cameras.

This function retrieves the baseline of the cameras in meters. The context must have already been read.

Parameters
contextThe context.
baselineA pointer to the retrieved value of the baseline in meters.
Returns
An error code representing the outcome of the function
Return values
TriclopsErrorOkThe function completed successfully.
TriclopsInvalidContextThe provided context is invalid
See also
triclopsGetDefaultContextFromFile()
enum TriclopsError triclopsGetCameraConfiguration ( const TriclopsContext  context,
TriclopsCameraConfiguration config 
)

Retrieves the current camera configuration for the stereo pipeline.

Parameters
contextThe context from which to get the camera configuration
configThe current camera configuration
Returns
An error code representing the outcome of the function
Return values
TriclopsErrorOkThe function completed successfully
TriclopsErrorInvalidContextThe provided context is invalid
See also
triclopsSetCameraConfiguration()
triclopsGetDeviceConfiguration()
enum TriclopsError triclopsGetDeviceConfiguration ( const TriclopsContext  context,
TriclopsCameraConfiguration config 
)

Retrieves the current camera configuration for the stereo pipeline.

This is a legacy function. Now it is just a renaming of triclopsGetCameraConfiguration().

Parameters
contextThe context from which to get the camera configuration
configThe current camera configuration
Returns
An error code representing the outcome of the function
Return values
TriclopsErrorOkThe function completed successfully
TriclopsErrorInvalidContextThe provided context is invalid
See also
triclopsSetCameraConfiguration()
enum TriclopsError triclopsGetFocalLength ( const TriclopsContext  context,
float *  focallength 
)

Retrieves the focal length of the cameras.

This function returns the focal length of the system. The focal length is in 'pixels' for the current selected output resolution. All cameras' rectified images have the same focal length. The default context must have been read before this call can be made.

Parameters
contextThe context.
focallengthA pointer to the retrieved value of the focallength in pixels.
Returns
An error code representing the outcome of the function
Return values
TriclopsErrorOkThe function completed successfully.
TriclopsInvalidContextThe provided context is invalid
See also
triclopsGetDefaultContextFromFile()
triclopsSetResolution()
enum TriclopsError triclopsGetImageCenter ( const TriclopsContext  context,
float *  centerRow,
float *  centerCol 
)

Returns the optical center for pinhole calculations.It is important that the context already has the resolution set. If triclopsSetResolution is not set, the returned value cannot be used for calculations. This image center can be used as the position in the image plane of the optical center for pinhole camera calculations.

Parameters
contextThe context.
centerRow- A pointer that will contain the row position of the image center for the current resolution.
centerCol- A pointer that will contain the column position of the image center for the current resolution.
Returns
An error code representing the outcome of the function
Return values
TriclopsErrorOkThe function completed successfully.
TriclopsInvalidContextThe provided context is invalid
enum TriclopsError triclopsGetSerialNumber ( const TriclopsContext  context,
int *  serialNumber 
)

Retrieves the serial number of the camera associated with a provided context.

Parameters
contextThe context from which to get the serial number
serialNumberThe serial number of the camera
Returns
An error code representing the outcome of the function
Return values
TriclopsErrorOkThe function completed successfully
TriclopsErrorInvalidContextThe provided context is invalid
enum TriclopsError triclopsSetCameraConfiguration ( const TriclopsContext  context,
TriclopsCameraConfiguration  config 
)

Sets a new camera configuration for the stereo pipeline.

This function sets which pair of sensors are used for the current context, which affects both rectification, stereo processing and world coordinates computation

Parameters
contextThe context for which to set the camera configuration
configThe new camera configuration
Returns
An error code representing the outcome of the function
Return values
TriclopsErrorOkThe function completed successfully
TriclopsErrorInvalidCameraConfigThe provided camera configuration is invalid (e.g. casted integer)
TriclopsErrorCameraConfigNotSetThe provided camera configuration is invalid for the current context (e.g. wide baseline for a two-sensors camera)
TriclopsErrorInvalidContextThe provided context is invalid
See also
triclopsGetDeviceConfiguration()
triclopsGetBaseline()
Contact Support Triclops SDK Programmer's Guide and API Reference