Due to the openness of Android, there are some differences between different devices, some of the video data collected by some devices show a certain error in the direction, which is usually related to the driver of the hardware device, the new API interface is the remote display, can support manual to correct the direction of the remote video.
Add API interface parameter definitions (for example, Anychat for Web SDK):
Remote video direction correction flag definition
var brac_rotation_flags_mirrored = 0x1000; Image needs mirror Rollover
var brac_rotation_flags_rotation90 = 0x2000; Rotate clockwise 90 degrees
var brac_rotation_flags_rotation180 = 0x4000; Rotate clockwise 180 degrees
var brac_rotation_flags_rotation270 = 0x8000; Rotate clockwise 270 degrees
User Information control type definition (Api:brac_userinfocontrol incoming parameter)
var brac_userinfo_ctrlcode_rotation = 8; Lets the specified user video rotate on display, wparam as the rotation angle parameter
Copy Code
In the video display process, if you need to rotate the video 90 degrees clockwise, you can call the following API:
Brac_userinfocontrol (Mtargetuserid, brac_userinfo_ctrlcode_rotation, Brac_rotation_flags_rotation90, 0, "");
Copy Code
In the video display process, if you need to rotate the video 90 degrees clockwise, and then mirror the rollover, you can call the following API:
Brac_userinfocontrol (Mtargetuserid, brac_userinfo_ctrlcode_rotation, Brac_rotation_flags_rotation90 + BRAC_ rotation_flags_mirrored, 0, "");
Copy Code
In the video display process, if you need to cancel the rotation, pass the parameter 0, refer to the following API call:
Brac_userinfocontrol (Mtargetuserid, brac_userinfo_ctrlcode_rotation, 0, 0, "");
Copy Code
The newly added API interface currently supports only anychat for the Windows sdk,anychat for Web SDK, starting with the Anychat r3997 version.