void ctl_forward_transform_axes(int transform,
                                float *axes);

ctl_forward_transform_axes applies the axis transformation transform to the samples pointed to by axes.

An axis transformation defines how to pick the sensor readings taken from a sensor in device mounting coordinates and transform them to body coordinates. Given the measurement (xdevice, ydevice, zdevice) in device coordinates, you transform this to body coordinates by applying a transformation generated by ctl_generate_axis_transform.

Assume that a sensor requires swapping the x and y axes and negating the z axis to transform from device to body coordinates. You would transform the coordinates using:

int transform = ctl_generate_axis_transform(AXIS_POSITIVE_Y,
ctl_forward_transform_axes(transform, axes);
See Also