documentation

SimilarityTransformWrapper

Functions for managing SimilarityTransformWrapper objects. More...

Functions

VL_SDK_API void VL_CALLINGCONVENTION vlDelete_SimilarityTransformWrapper (vlSimilarityTransformWrapper_t *similarityTransformWrapper)
 Deletes a SimilarityTransformWrapper object. More...
 
VL_SDK_API vlSimilarityTransformWrapper_t *VL_CALLINGCONVENTION vlNew_SimilarityTransformWrapper ()
 Creates a new SimilarityTransformWrapper object and returns a pointer to it. More...
 
VL_SDK_API vlSimilarityTransformWrapper_t *VL_CALLINGCONVENTION vlSimilarityTransformWrapper_Clone (vlSimilarityTransformWrapper_t *similarityTransformWrapper)
 Creates a copy of the SimilarityTransformWrapper object and returns a pointer to it. More...
 
VL_SDK_API bool VL_CALLINGCONVENTION vlSimilarityTransformWrapper_GetR (vlSimilarityTransformWrapper_t *similarityTransformWrapper, float q[], unsigned int elementCount)
 Returns the rotation of the contained transform. More...
 
VL_SDK_API float VL_CALLINGCONVENTION vlSimilarityTransformWrapper_GetS (vlSimilarityTransformWrapper_t *similarityTransformWrapper)
 Returns the scale factor $s$ of the given SimilarityTransform. More...
 
VL_SDK_API bool VL_CALLINGCONVENTION vlSimilarityTransformWrapper_GetT (vlSimilarityTransformWrapper_t *similarityTransformWrapper, float t[], unsigned int elementCount)
 Returns the translational part of the contained transform. More...
 
VL_SDK_API bool VL_CALLINGCONVENTION vlSimilarityTransformWrapper_GetValid (vlSimilarityTransformWrapper_t *similarityTransformWrapper)
 Returns whether the contained transform is valid (the tracking was successful). More...
 
VL_SDK_API bool VL_CALLINGCONVENTION vlSimilarityTransformWrapper_SetR (vlSimilarityTransformWrapper_t *similarityTransformWrapper, const float q[], unsigned int elementCount)
 Sets the rotation of the contained transform. More...
 
VL_SDK_API bool VL_CALLINGCONVENTION vlSimilarityTransformWrapper_SetS (vlSimilarityTransformWrapper_t *similarityTransformWrapper, float s)
 Sets the scale factor $s$ of the given SimilarityTransform. More...
 
VL_SDK_API bool VL_CALLINGCONVENTION vlSimilarityTransformWrapper_SetT (vlSimilarityTransformWrapper_t *similarityTransformWrapper, const float t[], unsigned int elementCount)
 Sets the translational part of the contained transform. More...
 
VL_SDK_API bool VL_CALLINGCONVENTION vlSimilarityTransformWrapper_SetValid (vlSimilarityTransformWrapper_t *similarityTransformWrapper, bool value)
 Sets the valid flag of the given SimilarityTransform. More...
 

Detailed Description

Functions for managing SimilarityTransformWrapper objects.

The SimilarityTransformWrapper is a wrapper for a SimilarityTransform object. SimilarityTransform objects represent a transform that scales in addition to rotation and translation.

Function Documentation

◆ vlDelete_SimilarityTransformWrapper()

VL_SDK_API void VL_CALLINGCONVENTION vlDelete_SimilarityTransformWrapper ( vlSimilarityTransformWrapper_t similarityTransformWrapper)

Deletes a SimilarityTransformWrapper object.

Call this function if you used the vlNew_SimilarityTransformWrapper function to create the object and you are now done using it.

Parameters
similarityTransformWrapperPointer to a SimilarityTransformWrapper object.

◆ vlNew_SimilarityTransformWrapper()

VL_SDK_API vlSimilarityTransformWrapper_t *VL_CALLINGCONVENTION vlNew_SimilarityTransformWrapper ( )

Creates a new SimilarityTransformWrapper object and returns a pointer to it.

This pointer must be released using vlDelete_SimilarityTransformWrapper.

Returns
A pointer to a new SimilarityTransformWrapper object.

◆ vlSimilarityTransformWrapper_Clone()

VL_SDK_API vlSimilarityTransformWrapper_t *VL_CALLINGCONVENTION vlSimilarityTransformWrapper_Clone ( vlSimilarityTransformWrapper_t similarityTransformWrapper)

Creates a copy of the SimilarityTransformWrapper object and returns a pointer to it.

This pointer must be released using vlDelete_SimilarityTransformWrapper.

Parameters
similarityTransformWrapperPointer to a SimilarityTransformWrapper object.
Returns
A pointer to the new SimilarityTransformWrapper object.

◆ vlSimilarityTransformWrapper_GetR()

VL_SDK_API bool VL_CALLINGCONVENTION vlSimilarityTransformWrapper_GetR ( vlSimilarityTransformWrapper_t similarityTransformWrapper,
float  q[],
unsigned int  elementCount 
)

Returns the rotation of the contained transform.

Please notice, that $(s,R,t)$ represents the transformation of a 3D point as follows: $y = s * Rx + t$.

Parameters
similarityTransformWrapperPointer to a SimilarityTransformWrapper object.
qFloat array with 4 elements $(x,y,z,w)$ for storing the rotation as quaternion.
elementCountNumber of elements in the given array. This should be 4.
Returns
true, on success; false otherwise.

◆ vlSimilarityTransformWrapper_GetS()

VL_SDK_API float VL_CALLINGCONVENTION vlSimilarityTransformWrapper_GetS ( vlSimilarityTransformWrapper_t similarityTransformWrapper)

Returns the scale factor $s$ of the given SimilarityTransform.

Please notice, that $(s,R,t)$ represents the transformation of a 3D point as follows: $y = s * Rx + t$.

Parameters
similarityTransformWrapperPointer to a SimilarityTransformWrapper object.
Returns
The scale factor, on success; -1 otherwise

◆ vlSimilarityTransformWrapper_GetT()

VL_SDK_API bool VL_CALLINGCONVENTION vlSimilarityTransformWrapper_GetT ( vlSimilarityTransformWrapper_t similarityTransformWrapper,
float  t[],
unsigned int  elementCount 
)

Returns the translational part of the contained transform.

Please notice, that $(s,R,t)$ represents the transformation of a 3D point as follows: $y = s * Rx + t$.

Parameters
similarityTransformWrapperPointer to a SimilarityTransformWrapper object.
tFloat array with 3 elements $(x,y,z)$ for storing the translation.
elementCountNumber of elements in the given array. This should be 3.
Returns
true, on success; false otherwise.

◆ vlSimilarityTransformWrapper_GetValid()

VL_SDK_API bool VL_CALLINGCONVENTION vlSimilarityTransformWrapper_GetValid ( vlSimilarityTransformWrapper_t similarityTransformWrapper)

Returns whether the contained transform is valid (the tracking was successful).

Parameters
similarityTransformWrapperPointer to a SimilarityTransformWrapper object.
Returns
true, if the contained transform is valid; false otherwise.

◆ vlSimilarityTransformWrapper_SetR()

VL_SDK_API bool VL_CALLINGCONVENTION vlSimilarityTransformWrapper_SetR ( vlSimilarityTransformWrapper_t similarityTransformWrapper,
const float  q[],
unsigned int  elementCount 
)

Sets the rotation of the contained transform.

Please notice, that $(s,R,t)$ represents the transformation of a 3D point as follows: $y = s * Rx + t$.

Parameters
similarityTransformWrapperPointer to a SimilarityTransformWrapper object.
qFloat array with 4 elements $(x,y,z,w)$, which contains the rotation as quaternion.
elementCountNumber of elements in the given array. This should be 4.
Returns
true, on success; false otherwise.

◆ vlSimilarityTransformWrapper_SetS()

VL_SDK_API bool VL_CALLINGCONVENTION vlSimilarityTransformWrapper_SetS ( vlSimilarityTransformWrapper_t similarityTransformWrapper,
float  s 
)

Sets the scale factor $s$ of the given SimilarityTransform.

Please notice, that $(s,R,t)$ represents the transformation of a 3D point as follows: $y = s * Rx + t$.

Parameters
similarityTransformWrapperPointer to a SimilarityTransformWrapper object.
sThe scale factor
Returns
true, on success; false otherwise.

◆ vlSimilarityTransformWrapper_SetT()

VL_SDK_API bool VL_CALLINGCONVENTION vlSimilarityTransformWrapper_SetT ( vlSimilarityTransformWrapper_t similarityTransformWrapper,
const float  t[],
unsigned int  elementCount 
)

Sets the translational part of the contained transform.

Please notice, that $(s,R,t)$ represents the transformation of a 3D point as follows: $y = s * Rx + t$.

Parameters
similarityTransformWrapperPointer to a SimilarityTransformWrapper object.
tFloat array with 3 elements $(x,y,z)$, which contain the translation.
elementCountNumber of elements in the given array. This should be 3.
Returns
true, on success; false otherwise.

◆ vlSimilarityTransformWrapper_SetValid()

VL_SDK_API bool VL_CALLINGCONVENTION vlSimilarityTransformWrapper_SetValid ( vlSimilarityTransformWrapper_t similarityTransformWrapper,
bool  value 
)

Sets the valid flag of the given SimilarityTransform.

Parameters
similarityTransformWrapperPointer to a SimilarityTransformWrapper object.
valueThe new value of the valid flag.
Returns
true, if setting worked; false otherwise