setGravitySensorAdaptiveMode abstract method
- TRTCGSensorMode mode
Set the adaptation mode of gravity sensing
After turning on gravity sensing, if the device on the collection end rotates, the images on the collection end and the audience will be rendered accordingly to ensure that the image in the field of view is always facing up.
It only takes effect in the camera capture scene inside the SDK, and only takes effect on the mobile terminal.
Notes:
- This interface only works for the collection end. If you only watch the picture in the room, opening this interface is invalid.
- When the capture device is rotated 90 degrees or 270 degrees, the picture seen by the capture device or the audience may be cropped to maintain proportional coordination.
Parameters:
- mode(TRTCGSensorMode):
- Gravity sensing mode, , default value: TRTCGSensorMode.uiAutoLayout.
Implementation
void setGravitySensorAdaptiveMode(TRTCGSensorMode mode);