// // VideoSession.m // OpenLive // // Created by GongYuhua on 2016/9/12. // Copyright © 2016年 Agora. All rights reserved. // #import "VideoSession.h" @implementation VideoSession - (instancetype)initWithUid:(NSUInteger)uid { if (self = [super init]) { self.uid = uid; self.hostingView = [[UIView alloc] init]; self.hostingView.translatesAutoresizingMaskIntoConstraints = NO; self.canvas = [[AgoraRtcVideoCanvas alloc] init]; self.canvas.uid = uid; self.canvas.view = self.hostingView; self.canvas.renderMode = AgoraRtc_Render_Hidden; } return self; } + (instancetype)localSession { return [[VideoSession alloc] initWithUid:0]; } @end