ZoomSDK MacOS Recording

Device (please complete the following information):

  • Device: [e.g. Apple MacBook Pro (13-inch, M1)]
  • OS: [e.g. macOS Big Sur 11.2.1 ]

Im using this code to record the video and audio for all participants but was able to record only the audio no video (Black Screen) any idea what could be causing this issue ?
-(void)startRecord {
NSArray *paths=NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES);
NSString *documentsDirectory = [paths objectAtIndex:0];

time_t timeStamp = [[NSDate date] timeIntervalSinceNow];
ZoomSDKMeetingRecordController *record = [[[ZoomSDK sharedSDK] getMeetingService] getRecordController];
[record setDelegate:self];
ZoomSDKError canStartRecording = [record canStartRecording:NO];
if (canStartRecording == ZoomSDKError_Success) {
    NSLog(@"canStartRecordingSuccess");
}

ZoomSDKError isSupportLocalRecording = [record isSupportLocalRecording:self.mySelfUserInfo.getUserID];
if (isSupportLocalRecording == ZoomSDKError_Success) {
    NSLog(@"isSupportLocalRecordingSuccess");
}

ZoomSDKError allowRecordingSupported = [record allowLocalRecording:YES User:self.mySelfUserInfo.getUserID];
if (allowRecordingSupported == ZoomSDKError_Success) {
    NSLog(@"allowRecordingSupportedSuccess");
}

[record startRecording:&timeStamp saveFilePath:documentsDirectory];
ZoomSDKError error = [record requestCustomizedLocalRecordingNotification:YES];
if (error == ZoomSDKError_Success) {
    NSLog(@"requestCustomizedLocalRecordingNotificationSuccess");
}

}

  • (void)onRecord2MP4Done:(BOOL)success Path:(NSString *)recordPath {
    if (success) {
    NSString *filePath = [NSString stringWithFormat:@"%@meetingrec_0.mp4",recordPath];

      NSURL *url = [NSURL fileURLWithPath:filePath];
      NSData *data = [NSData dataWithContentsOfURL:url];
      
      ZoomSDKMeetingService* meetingService = [[ZoomSDK sharedSDK] getMeetingService];
      [meetingService leaveMeetingWithCmd:(LeaveMeetingCmd_End)];
    

    }
    }

  • (void)onCustomizedRecordingSourceReceived:(CustomizedRecordingLayoutHelper *)helper {
    ZoomSDKError error = [helper selectShareSource:RecordingLayoutMode_VideoWall];
    if (error == ZoomSDKError_Success) {
    NSLog(@“selectShareSourceSuccess”);
    }

    ZoomSDKError error2 = [helper selectActiveVideoSource];
    if (error2 == ZoomSDKError_Success) {
    NSLog(@“selectActiveVideoSourceSuccess”);
    }

    NSArray users = [[[[ZoomSDK sharedSDK] getMeetingService] getMeetingActionController] getParticipantsList];
    for (NSNumber
    userID in users)
    {
    ZoomSDKError error3 = [helper addVideoSourceToResArray:userID.unsignedIntValue];
    if (error3 == ZoomSDKError_Success) {
    NSLog(@“addVideoSourceToResArraySuccess”);
    }
    }
    }

Hi @hkr.noel,

This post appears to be a duplicate of your reply in another thread which I have already responded to. Please try to avoid duplicate posts so that this forum remains as easy to navigate for other users as possible. :slightly_smiling_face:

Thanks!