简体   繁体   中英

How to identify opponent user enable or disable video in quickblox ios

How to identify opponent user enable or disable video in Quickblox SDK. Please give the solution or delegate methods

You can check this with the WebRTC Stats reporting. To start collecting report information do the following:

[QBRTCConfig setStatsReportTimeInterval:5]; // 5 seconds

And classes that adopt QBRTCClientDelegate protocol will be notified with

     - (void)session:(QBRTCSession *)session updatedStatsReport:(QBRTCStatsReport *)report forUserID:(NSNumber *)userID {
            double audioReceivedBitrate = report.audioReceivedBitrateTracker.bitrate;
            double videoReceivedBitrate = report.videoReceivedBitrateTracker.bitrate;

            //You can check Bitrate of the received video.
           NSMutableString *result = [NSMutableString string];
           // Video receive stats.
           NSString *videoReceiveFormat = @"VR (recv) %@x%@@%@fps | (decoded)%@ | (output)%@fps | %@/%@ | %@ms\n";
          [result appendString:[NSString stringWithFormat:videoReceiveFormat,
                              report.videoReceivedWidth, report.videoReceivedHeight, report.videoReceivedFps,
                              report.videoReceivedDecodedFps,
                              report.videoReceivedOutputFps,
                              report.videoReceivedBitrate, report.availableReceiveBandwidth,
                              report.videoReceivedDecodeMs]];
           NSLog(@"%@", result);


        }

For reference : Quickblox API

Also you can use System Notifications feature from QuickBlox SDK. For example, user will send system message with this event (disable camera) and other users will listen this event and do something needed action ( guide for Android )

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM