Sets a callback for receiving video data on the global client
This function is part of the singleton API. The callback is triggered when video data is received from the meeting.
The callback function to invoke
true if the callback was set successfully
rtms.onVideoData((buffer, size, timestamp, trackId, metadata) => { console.log(`Received ${size} bytes of video from ${metadata.userName}`); console.log(`Track ID: ${trackId}`); // Process the video data...}); Copy
rtms.onVideoData((buffer, size, timestamp, trackId, metadata) => { console.log(`Received ${size} bytes of video from ${metadata.userName}`); console.log(`Track ID: ${trackId}`); // Process the video data...});
Sets a callback for receiving video data on the global client
This function is part of the singleton API. The callback is triggered when video data is received from the meeting.