Coordinates from a sensor event will be remapped based on the angle.
BPS_API int sensor_remap_coordinates(int angle)
The angle (in degrees) to base the remapping off of. Must be a value of 0, 90, 180, or 270. A value of 0 effectively disables remapping.
Library:libbps (For the qcc command, use the -l bps option to link against this library)
The x, y, and z values are based off of an angle of 0. After calling this function, getting axis values from events will automatically be corrected based on the provided angle.
The initial angle of the application is provided in the "ORIENTATION" environment variable. That value can be converted to an int and passed into this function.
On a rotation event, the new angle will be provided in the event, it can be extracted and passed into this function.
BPS_SUCCESS upon success. Otherwise, BPS_FAILURE with the errno set.
Last modified: 2014-09-30