Commit 351b0e4ca9c871907635c388f82157a0ff83d19d

Authored by 王军波
1 parent 05ef50d3

直播推流修改

LiveVideoCloud/Classes/Sections/UGCSections/Controller/LVCUGCLivePlayerController.m
@@ -78,7 +78,7 @@ @@ -78,7 +78,7 @@
78 [self.view addSubview:self.viewThird]; 78 [self.view addSubview:self.viewThird];
79 79
80 if ([_model.activityStatus isEqualToString:@"1"]) { 80 if ([_model.activityStatus isEqualToString:@"1"]) {
81 - [self addLiveBaseView]; 81 + [self addLiveBaseViewWithChannelId:_model.channelId];
82 } 82 }
83 83
84 [self.view addSubview:self.bgView]; 84 [self.view addSubview:self.bgView];
@@ -97,13 +97,14 @@ @@ -97,13 +97,14 @@
97 } 97 }
98 } 98 }
99 99
100 -- (void)addLiveBaseView 100 +- (void)addLiveBaseViewWithChannelId:(NSString *)channelId
101 { 101 {
102 if (_vodPlayerQuitBtn) { 102 if (_vodPlayerQuitBtn) {
103 [_vodPlayerQuitBtn removeFromSuperview]; 103 [_vodPlayerQuitBtn removeFromSuperview];
104 } 104 }
105 [_liveBaseView removeFromSuperview]; 105 [_liveBaseView removeFromSuperview];
106 [_viewSecond addSubview:self.liveBaseView ]; 106 [_viewSecond addSubview:self.liveBaseView ];
  107 + self.liveBaseView.roomId = channelId;
107 [_liveBaseView addGestureRecognizer:_pan]; 108 [_liveBaseView addGestureRecognizer:_pan];
108 } 109 }
109 110
@@ -271,7 +272,7 @@ @@ -271,7 +272,7 @@
271 272
272 } else if ([_playArray[_index].activityStatus isEqualToString:@"1"]) { 273 } else if ([_playArray[_index].activityStatus isEqualToString:@"1"]) {
273 274
274 - [self addLiveBaseView]; 275 + [self addLiveBaseViewWithChannelId:_playArray[_index].channelId];
275 276
276 _player = [[CNLiveMoviePlayerController alloc] initLivePlayWithChannelId:_playArray[_index].channelId anchorStatus:YES authSuccess:^{ 277 _player = [[CNLiveMoviePlayerController alloc] initLivePlayWithChannelId:_playArray[_index].channelId anchorStatus:YES authSuccess:^{
277 278
@@ -375,7 +376,7 @@ @@ -375,7 +376,7 @@
375 }]; 376 }];
376 377
377 } else if ([_playArray[_index].activityStatus isEqualToString:@"1"]) { 378 } else if ([_playArray[_index].activityStatus isEqualToString:@"1"]) {
378 - [self addLiveBaseView]; 379 + [self addLiveBaseViewWithChannelId:_playArray[_index].channelId];
379 380
380 _player = [[CNLiveMoviePlayerController alloc] initLivePlayWithChannelId:_playArray[_index].channelId anchorStatus:YES authSuccess:^{ 381 _player = [[CNLiveMoviePlayerController alloc] initLivePlayWithChannelId:_playArray[_index].channelId anchorStatus:YES authSuccess:^{
381 382