MobilityDB 1.3
Loading...
Searching...
No Matches

◆ get_axis_stbox()

static double get_axis_stbox ( const STBox box,
int  axis,
bool  upper 
)
static

Retrieves the value of a specific axis from an STBox.

Returns the coordinate or temporal value of a specified axis from the stbox. The axis is determined by the axis parameter, and whether the value is from the lower or upper bound of that axis is specified by the upper parameter. The function supports the X, Y, Z spatial axes and the temporal axis.

Parameters
[in]boxThe STBox structure from which the axis value is to be retrieved.
[in]axisThe axis to retrieve (0 = X, 1 = Y, 2 = time, 3 = Z).
[in]upperA boolean indicating whether to retrieve the upper (true) or lower (false) bound of the specified axis.
Returns
The value of the specified axis and bound as a double. Returns 0.0 if the axis is invalid.