TXLivePush.h
1.84 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
#import <Foundation/NSObject.h>
#import <UIKit/UIView.h>
#import "TXLivePushConfig.h"
#import "TXLivePushListener.h"
#import "TXLiveSDKTypeDef.h"
@interface TXLivePush : NSObject
@property (nonatomic, copy) TXLivePushConfig * config;
@property (nonatomic, weak) id<TXLivePushListener> delegate;
// 当前推流URL
@property (nonatomic, readonly) NSString * rtmpURL;
// 当前是否为前置camera
@property (nonatomic, readonly) BOOL frontCamera;
/* startPush 启动到指定URL推流(rtmpURL 腾讯云的推流地址)
* 参数:
* url : RTMP完整的URL
* 返回: 0 = OK
*/
-(int) startPush:(NSString*)rtmpURL;
/* stopPush 停止推流
*
*/
-(void) stopPush;
/* startPreview 开始推流画面的预览。
* 参数:
* view : 预览控件所在的父控件
*/
-(int) startPreview:(UIView*)view;
/* stopPreview 停止预览
*
*/
-(void) stopPreview;
/* switchCamera 切换前后摄像头
*
*/
-(int) switchCamera;
/* setBeautyFilterDepth 设置美颜 和 美白 效果级别
* 参数:
* beautyDepth : 美颜级别取值范围 0 ~ 9; 0 表示关闭 1 ~ 9值越大 效果越明显。
* whiteningDepth : 美白级别取值范围 0 ~ 9; 0 表示关闭 1 ~ 9值越大 效果越明显。
*/
-(void) setBeautyFilterDepth:(int)beautyDepth setWhiteningFilterDepth:(int)whiteningDepth;
/* toggleTorch, 打开闪关灯。
* 参数
* YES, 打开,
* NO, 关闭.
* 返回:
* YES,打开成功。
* NO,打开失败。
*/
-(BOOL) toggleTorch:(BOOL) bEnable;
/* setLogLevel 设置log输出级别
* level:参见 LOGLEVEL
*
*/
-(void) setLogLevel:(TX_Enum_Type_LogLevel) level;
/* getSDKVersion 获取SDK版本信息
*
*/
-(NSArray*) getSDKVersion;
@end