| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495 |
- //
- // BGTPublishController.h
- // BuguLive
- //
- // Created by xfg on 16/12/5.
- // Copyright © 2016年 xfg. All rights reserved.
- // 腾讯云直播的主播控制类
- #import <UIKit/UIKit.h>
- #import <AVFoundation/AVFoundation.h>
- #import <TXLiteAVSDK_Professional/TXLivePush.h>
- #import <TXLiteAVSDK_Professional/TRTCCloud.h>
- #import "UserView.h"
- #import "TLiveMickListModel.h"
- @class BGTPublishController;
- typedef void(^LeaveRoomBlockSuccess)(void);
- @protocol FWTPublishControllerDelegate <NSObject>
- @required
- // 首帧回调
- - (void)firstIFrame:(BGTPublishController*)publishVC;
- // 网络断连,且经多次重连抢救无效后退出app
- - (void)exitPublishAndApp:(BGTPublishController*)publishVC;
- @end
- @interface BGTPublishController : UIViewController
- {
- BOOL _appIsInterrupt;
- UIView *_preViewContainer;
- UIView *_rightVideoContrainerView; // 放置右视频的view
-
- BOOL _hardware_switch;
- int _whitening_level;
-
- unsigned long long _startTime;
- unsigned long long _lastTime;
-
- NSString *_testPath;
- BOOL _isPreviewing;
-
- NSInteger _rePublishTime;
-
- UIView *blueBgView;
- UIView *redBgView;
- UIImageView *pkBgView;
- UIImageView *_loadingImageView;
- }
- @property (nonatomic, weak) id<FWTPublishControllerDelegate> delegate;
- @property (nonatomic, strong) NSMutableSet *linkMemeberSet; // 连麦观众列表
- @property (nonatomic, strong) TXLivePush *txLivePublisher;
- @property (nonatomic, strong) TXLivePushConfig *txLivePushonfig;
- @property (nonatomic, strong)TXLivePlayer *txLivePlayer;
- @property (nonatomic, strong) TXLivePlayConfig *txLivePlayConfig;
- @property (nonatomic, copy) LeaveRoomBlockSuccess leaveRoomBlockSuccess;
- @property (nonatomic, strong, readonly) TRTCCloud * trtcCloud;
- @property(nonatomic, strong) NSString *agora_token;
- - (void)adjustPlayItemAgora:(TLiveMickListModel *)mickListModel;
- @property (nonatomic, copy) NSString *pushUrlStr; // 推流地址
- @property (nonatomic, copy) NSString *kbpsSendStr; // 发送码率
- @property (nonatomic, copy) NSString *kbpsRecvStr; // 接收码率
- @property (nonatomic, strong) NSDictionary *qualityDict; // 直播质量相关参数
- @property (nonatomic, copy) NSString * roomIDStr; // 房间ID
- // 开始推流
- - (BOOL)startPushRtmpLiveMethod;
- // 停止推流
- - (void)stopRtmp;
- // 前置后置摄像头切换
- - (void)clickCamera:(UIButton*) btn;
- // 开、关闪光灯
- - (void)clickTorch:(BOOL) isOpen;
- - (void)toastTip:(NSString*)toastInfo;
- // 结束直播
- - (void)endLive;
- - (void)adjustPlayItemVoiceUserList:(NSArray *)userlist;
- -(void)updateLianMaiCoin;
- - (void)clickCloseBtn:(UserView *)view;
- @end
|