JCSDK-iOS
构造函数 | 属性 | 所有成员列表
JCMediaDeviceVideoCanvas类 参考

#import <JCMediaDeviceVideoCanvas.h>

构造函数

(bool) - replace:
 
(void) - pause
 
(void) - resume
 
(void) - rotate:
 
(bool) - snapshot:heigh:filePath:
 
(instancetype) - initWithVideoSource:renderType: [implementation]
 
(instancetype) - initWithVideoSource:renderType:view: [implementation]
 

属性

NSString * videoSource
 
UIView * videoView
 
int renderType
 
bool isCamera
 
bool autoRotate [implementation]
 视频窗口是否跟着手机自动旋转,默认为false
 
JCMediaDeviceRotateAngle rotateAngleToScreen [implementation]
 当 autoRotate 为 true 时,窗口与手机屏幕的角度,默认为 JCMediaDeviceRotateAngle0 更多...
 

详细描述

视频对象

函数文档

◆ initWithVideoSource:renderType:

- (instancetype) initWithVideoSource: (NSString *)  videoSource
renderType: (int)  type 
implementation

@breif 构造视频对象

参数
videoSource视频源
type渲染模式,ZmfRenderMode
警告
上层不要直接调用此函数

◆ initWithVideoSource:renderType:view:

- (instancetype) initWithVideoSource: (NSString *)  videoSource
renderType: (int)  type
view: (UIView *)  view 
implementation

@breif 构造视频对象

参数
videoSource视频源
type渲染模式,ZmfRenderMode
view视图对象
警告
上层不要直接调用此函数

◆ pause

- (void) pause

暂停视频渲染

◆ replace:

- (bool) replace: (NSString *)  videoSource

更新视频渲染标识

参数
videoSource视频源
返回
成功返回 true,失败返回 false

◆ resume

- (void) resume

恢复视频渲染

◆ rotate:

- (void) rotate: (int)  angle

旋转角度,必须是90的倍数,该角度表示与屏幕正方向旋转后的夹角

参数
angle角度值

◆ snapshot:heigh:filePath:

- (bool) snapshot: (int)  width
heigh: (int)  height
filePath: (NSString *)  filePath 

视频通话截图

参数
width截屏宽度像素,-1为视频源像素
height截屏高度像素,-1为视频源像素
filePath文件路径,需精确到文件名及格式,例如:/Documents/JuphoonCloud/picture.png。请确保目录存在且可写。
返回
是否成功
  • true: 成功
  • false: 失败

属性说明

◆ isCamera

- (bool) isCamera
readnonatomicassign

是否摄像头

◆ renderType

- (int) renderType
readnonatomicassign

渲染模式

◆ rotateAngleToScreen

- (JCMediaDeviceRotateAngle) rotateAngleToScreen
readwritenonatomicassignimplementation

当 autoRotate 为 true 时,窗口与手机屏幕的角度,默认为 JCMediaDeviceRotateAngle0

参见
JCMediaDeviceRotateAngle

◆ videoSource

- (NSString*) videoSource
readnonatomiccopy

渲染标识

◆ videoView

- (UIView*) videoView
readnonatomicstrong

获取视频渲染视图