initWithWidth:height:frameRate:bitrate:orientationMode:mirrorMode:

  • macOS

更新时间不可用

指定视频宽高并初始化 AgoraVideoEncoderConfiguration 对象。

Objective-C
- (instancetype _Nonnull)initWithWidth:(NSInteger)width
                                height:(NSInteger)height
                             frameRate:(NSInteger)frameRate
                               bitrate:(NSInteger)bitrate
                       orientationMode:(AgoraVideoOutputOrientationMode)orientationMode
                            mirrorMode:(AgoraVideoMirrorMode)mirrorMode NS_SWIFT_NAME(init(width:height:frameRate:bitrate:orientationMode:mirrorMode:));

参数

参数名描述
width

视频的宽度。

height

视频的高度。

frameRate

视频帧率,详见 AgoraVideoFrameRate。

bitrate

编码视频的码率。

orientationMode

编码视频的方向模式,详见 AgoraVideoOutputOrientationMode。

mirrorMode

设置本地视频流的镜像模式,仅影响远端用户看到的视频,详见 AgoraVideoMirrorMode。

表格内容超出当前宽度,可横向滚动查看更多列。

返回值

方法调用成功,返回 AgoraVideoEncoderConfiguration 对象。

所属接口类

这个页面有帮助吗?