ZegoOrientationMode Constants Reference
Declared in | ZegoExpressDefines.h |
---|
ZegoOrientationMode
Orientation mode of the video.
Definition
typedef NS_ENUM(NSUInteger, ZegoOrientationMode ) {
ZegoOrientationModeCustom = 0,
ZegoOrientationModeAdaption = 1,
ZegoOrientationModeAlignment = 2,
ZegoOrientationModeFixedResolutionRatio = 3,
};
Constants
ZegoOrientationModeCustom
-
Custom mode.Description: The default is the custom mode. In this mode, the user needs to set the orientation through [SetAppOrientation], and set the video resolution through [SetVideoConfig] to control the video ratio. The SDK rotates the video at the stream publishing end.
Declared In
ZegoExpressDefines.h
. ZegoOrientationModeAdaption
-
Player self adaption mode.Description: The video orientation of the stream playing end is automatically vertically upward, and the user of the stream publishing end no longer needs to set the orientation through [SetAppOrientation], and no longer need to set the video resolution to control the video ratio through [SetVideoConfig]. Caution: 1. Both the stream publishing end and the stream playing end need to be set to [ZegoOrientationModeAdaption] mode. 2. Media players, cloud recording, local recording, and publish or play streaming scenarios via CDN are not supported. 3. In this mode, the SDK will automatically swap the width and height of the encoding resolution according to the actual orientation of the device.
Declared In
ZegoExpressDefines.h
. ZegoOrientationModeAlignment
-
Player adapt to pulisher mode.Description: Taking the Status Bar as a reference, the video direction of the stream playing end is the same as the preview video direction of the stream publishing end. The SDK will use the Status Bar as a reference to rotate the image on the stream playing end, and the rotation angle is the same as the rotation angle of the preview on the stream publishing end. Stream publishing end users no longer need to set the orientation through [SetAppOrientation], and no longer need to set the video resolution to control the video ratio through [SetVideoConfig]. Caution: 1. Media players, cloud recording, local recording, and publish or play streaming scenarios via CDN are not supported.2. In this mode, the SDK will automatically swap the width and height of the encoding resolution according to the actual position of the Status Bar.
Declared In
ZegoExpressDefines.h
. ZegoOrientationModeFixedResolutionRatio
-
Fixed resolution ratio mode.Description: Taking the Status Bar as a reference, the video orientation of the stream playing end is the same as the previewed video direction of the stream publishing end, and the video resolution is the same as the encoding resolution. Users of the streaming end no longer need to set the orientation through [SetAppOrientation].
Declared In
ZegoExpressDefines.h
.
Declared In
ZegoExpressDefines.h