Video SDK for MacOS API Reference
Loading...
Searching...
No Matches
ZMVideoSDKUserHelper.h
Go to the documentation of this file.
1
5
6#import <Foundation/Foundation.h>
7#import <ZMVideoSDK/ZMVideoSDKDef.h>
8#import <ZMVideoSDK/ZMVideoSDKVideoCanvas.h>
9
11
12NS_ASSUME_NONNULL_BEGIN
17@interface ZMVideoSDKVideoStatus : NSObject
18
22@property (nonatomic, assign, readonly) BOOL isHasVideoDevice;
23
27@property (nonatomic, assign, readonly) BOOL isOn;
28@end
29
34@interface ZMVideoSDKAudioStatus : NSObject
35
39@property (nonatomic, assign, readonly) ZMVideoSDKAudioType audioType;
40
44@property (nonatomic, assign, readonly) BOOL isMuted;
45
49@property (nonatomic, assign, readonly) BOOL isTalking;
50@end
51
57@interface ZMVideoSDKQOSStatistics : NSObject
58
62@property (nonatomic, assign, readonly) ZMVideoSDKStatisticsDirection direction;
63
67@property (nonatomic, assign, readonly) NSInteger timestamp;
68
72@property (nonatomic, copy, readonly) NSString * _Nullable codecName;
73
77@property (nonatomic, assign, readonly) NSInteger rtt;
78
82@property (nonatomic, assign, readonly) double jitter;
83
87@property (nonatomic, assign, readonly) NSInteger width;
88
92@property (nonatomic, assign, readonly) NSInteger height;
93
97@property (nonatomic, assign, readonly) NSInteger fps;
98
102@property (nonatomic, assign, readonly) NSInteger bps;
103
107@property (nonatomic, assign, readonly) NSInteger bytesTransferred;
108
112@property (nonatomic, assign, readonly) NSInteger packetsLost;
113
117@property (nonatomic, assign, readonly) NSInteger packetsTransferred;
118
122@property (nonatomic, assign, readonly) ZMVideoSDKNetworkStatus networkLevel;
123
127@property (nonatomic, assign, readonly) ZMVideoSDKDataType statisticsType;
128
132@property (nonatomic, assign, readonly) NSInteger avg_loss;
133
137@property (nonatomic, assign, readonly) NSInteger max_loss;
138
142@property (nonatomic, assign, readonly) NSInteger bandwidth;
143
144@end
145
152
156@property (nonatomic, assign, readonly) NSInteger frameWidthInput;
157
161@property (nonatomic, assign, readonly) NSInteger frameHeightInput;
162
166@property (nonatomic, assign, readonly) NSInteger frameRateInput;
167
171@property (nonatomic, assign, readonly) NSInteger bytesSent;
172
176@property (nonatomic, assign, readonly) NSInteger packetsSent;
177
181@property (nonatomic, assign, readonly) NSInteger totalPacketSendDelay;
182
186@property (nonatomic, assign, readonly) NSInteger totalEncodeTime;
187
191@property (nonatomic, assign, readonly) NSInteger framesEncoded;
192
196@property (nonatomic, assign, readonly) NSUInteger headerBytesSent;
197
198@end
199
206
210@property (nonatomic, assign, readonly) unsigned long long bytesReceived;
211
215@property (nonatomic, assign, readonly) NSInteger packetsReceived;
216
220@property (nonatomic, assign, readonly) NSInteger estimatedPlayoutTimestamp;
221
225@property (nonatomic, assign, readonly) NSInteger totalDecodeTime;
226
230@property (nonatomic, assign, readonly) NSInteger framesDecoded;
231
235@property (nonatomic, assign, readonly) double jitterBufferDelay;
236
240@property (nonatomic, assign, readonly) unsigned long long jitterBufferEmittedCount;
241
245@property (nonatomic, assign, readonly) unsigned long long headerBytesReceived;
246
250@property (nonatomic, assign, readonly) NSUInteger packetsDiscarded;
251
255@property (nonatomic, assign, readonly) NSUInteger fecPacketsReceived;
256
260@property (nonatomic, assign, readonly) NSUInteger fecPacketsDiscarded;
261
265@property (nonatomic, assign, readonly) double jitterBufferTargetDelay;
266
270@property (nonatomic, assign, readonly) double jitterBufferMinimumDelay;
271
275@property (nonatomic, assign, readonly) unsigned long long totalSamplesReceived;
276
280@property (nonatomic, assign, readonly) unsigned long long concealedSamples;
281
285@property (nonatomic, assign, readonly) unsigned long long silentConcealedSamples;
286
290@property (nonatomic, assign, readonly) unsigned long long concealmentEvents;
291
295@property (nonatomic, assign, readonly) unsigned long long insertedSamplesForDeceleration;
296
300@property (nonatomic, assign, readonly) unsigned long long removedSamplesForAcceleration;
301
305@property (nonatomic, assign, readonly) double totalSamplesDuration;
306
310@property (nonatomic, assign, readonly) double audioLevel;
311
315@property (nonatomic, assign, readonly) double totalAudioEnergy;
316
317@end
318
324
329@property (nonatomic, assign, readonly) int bpf DEPRECATED_MSG_ATTRIBUTE("Use bps instead");
330
335@property (nonatomic, assign, readonly) ZMVideoSDKNetworkStatus videoNetworkStatus DEPRECATED_MSG_ATTRIBUTE("Use networkLevel instead");
336@end
337
343
348@property (nonatomic, assign, readonly) int bpf DEPRECATED_MSG_ATTRIBUTE("Use bps instead");
349
354@property (nonatomic, assign, readonly) ZMVideoSDKNetworkStatus shareNetworkStatus DEPRECATED_MSG_ATTRIBUTE("Use networkLevel instead");
355@end
356
361@interface ZMVideoSDKYUVRawDataI420 : NSObject
362
366@property (nonatomic, assign, readonly) char* _Nullable yBuffer;
367
371@property (nonatomic, assign, readonly) char* _Nullable uBuffer;
372
376@property (nonatomic, assign, readonly) char* _Nullable vBuffer;
377
381@property (nonatomic, assign, readonly) char* _Nullable buffer;
382
386@property (nonatomic, assign, readonly, nullable) char* alphaBuffer;
387
391@property (nonatomic, assign, readonly) unsigned int bufferLen;
392
396@property (nonatomic, assign, readonly) unsigned int alphaBufferLen;
397
401@property (nonatomic, assign, readonly) BOOL isLimitedI420;
402
406@property (nonatomic, assign, readonly) unsigned int streamWidth;
407
411@property (nonatomic, assign, readonly) unsigned int streamHeight;
412
416@property (nonatomic, assign, readonly) unsigned int rotation;
417
421@property (nonatomic, assign, readonly) unsigned int resourceID;
422
426@property (nonatomic, assign, readonly) long long timeStamp;
431- (BOOL)canAddRef;
432
438- (BOOL)addRef;
439
445@end
446
447
452@interface ZMVideoSDKShareCursorData : NSObject
453
457@property (nonatomic, assign, readonly) unsigned int sourceID;
458
462@property (nonatomic, assign, readonly) int x;
463
467@property (nonatomic, assign, readonly) int y;
468@end
469
474@protocol ZMVideoSDKRawDataPipeDelegate <NSObject>
475@optional
476
481- (void)onRawDataFrameReceived:(ZMVideoSDKYUVRawDataI420*)data;
482
487- (void)onRawDataStatusChanged:(ZMVideoSDKRawDataStatus)status;
488
493- (void)onShareCursorDataReceived:(ZMVideoSDKShareCursorData *)info;
494@end
495
500@interface ZMVideoSDKRawDataPipe : NSObject
501
508- (ZMVideoSDKErrors)subscribe:(ZMVideoSDKResolution)resolution listener:(id<ZMVideoSDKRawDataPipeDelegate>)listener;
509
515- (ZMVideoSDKErrors)unSubscribe:(id<ZMVideoSDKRawDataPipeDelegate>)listener;
516
522
528
533- (NSString* _Nullable)getVideoDeviceName;
534
540
547
553
559@end
560
566
572
578@end
579
585
591
597
603- (ZMVideoSDKErrors)turnLeft:(unsigned int)range;
604
610- (ZMVideoSDKErrors)turnRight:(unsigned int)range;
611
617- (ZMVideoSDKErrors)turnUp:(unsigned int)range;
618
624- (ZMVideoSDKErrors)turnDown:(unsigned int)range;
625
631- (ZMVideoSDKErrors)zoomIn:(unsigned int)range;
632
638- (ZMVideoSDKErrors)zoomOut:(unsigned int)range;
639@end
640
641
646@interface ZMVideoSDKUser : NSObject
651- (NSString* _Nullable)getUserID;
652
658- (NSString* _Nullable)getCustomIdentity DEPRECATED_MSG_ATTRIBUTE("Use -getUserKey instead");
659
664- (NSString* _Nullable)getUserKey;
665
670- (NSString* _Nullable)getUserName;
671
675- (NSString* _Nullable)getUserReference;
676
682
687- (BOOL)isHost;
688
693- (BOOL)isManager;
694
700
706
712
718
724
730
736
744- (BOOL)setUserVolume:(float)volume isSharingAudio:(BOOL)isSharingAudio DEPRECATED_MSG_ATTRIBUTE("Use -setUserPlaybackVolume:isSharingAudio: instead");
745
753- (BOOL)getUserVolume:(float*)volume isSharingAudio:(BOOL)isSharingAudio DEPRECATED_MSG_ATTRIBUTE("Use -getUserPlaybackVolume:isSharingAudio: instead");
754
761- (BOOL)canSetUserVolume:(BOOL)isShareAudio DEPRECATED_MSG_ATTRIBUTE("Use -canSetUserPlaybackVolume: instead");
762
769- (BOOL)setUserPlaybackVolume:(float)volume isSharingAudio:(BOOL)isSharingAudio;
770
777- (BOOL)getUserPlaybackVolume:(float*)volume isSharingAudio:(BOOL)isSharingAudio;
778
784- (BOOL)canSetUserPlaybackVolume:(BOOL)isShareAudio;
785
790- (unsigned int)getAudioLevel;
791
797
803- (ZMVideoSDKErrors)transferFile:(NSString *)filePath;
804
810
816
822
828
834
841
847@end
848
853@interface ZMVideoSDKUserHelper: NSObject
854
861- (BOOL)changeName:(NSString*)name user:(ZMVideoSDKUser*)user;
862
868- (BOOL)makeHost:(ZMVideoSDKUser*)user;
869
875- (BOOL)makeManager:(ZMVideoSDKUser*)user;
876
882- (ZMVideoSDKErrors)revokeManager:(ZMVideoSDKUser*)user;
883
889- (BOOL)removeUser:(ZMVideoSDKUser*)user;
890
896@end
897
898NS_ASSUME_NONNULL_END
899
ZMVideoSDKResolution
Enumeration of render resolution.
ZMVideoSDKRawDataType
Enumeration of raw data types.
ZMVideoSDKDataType
Enumeration of the data type for network quality monitoring.
ZMVideoSDKShareCapturePauseReason
Enumeration of reasons why screen sharing capture is paused in the Zoom Video SDK.
ZMVideoSDKShareType
Enumerates the types of content available for sharing in a session.
ZMVideoSDKStatisticsDirection
Direction of media statistics (send or receive).
ZMVideoSDKErrors
Enumerates all errors in the VideoSDK.
ZMVideoSDKWhiteboardStatus
Enumeration of the status of whiteboard sharing.
ZMVideoSDKRawDataStatus
Enumeration the statuses of raw data.
ZMVideoSDKNetworkStatus
Enumerates the network statuses.
ZMVideoSDKShareStatus
Enumerates the status of sharing.
ZMVideoSDKAudioType
Enumerates the types of audio.
Audio status interface.
BOOL isTalking
Determines whether the user is talking.
BOOL isMuted
Determines whether the audio is muted.
ZMVideoSDKAudioType audioType
Gets audio type: VOIP (Voice over IP), Telephony, or None.
Camera control request handler object interface.
ZMVideoSDKErrors approve()
Approve the remote camera control request.
ZMVideoSDKErrors decline()
Decline the remote camera control request.
QOS statistics for inbound media stream (receiving).
unsigned long long insertedSamplesForDeceleration
Gets samples inserted to slow down playout (deceleration) (receive only, audio only).
unsigned long long bytesReceived
Gets the total bytes received (receive only).
NSInteger totalDecodeTime
Gets the total time spent decoding in milliseconds (receive only).
double totalAudioEnergy
Gets accumulated audio energy (receive only, audio only).
NSUInteger fecPacketsReceived
Gets total number of FEC packets received (receive only, audio only).
unsigned long long jitterBufferEmittedCount
Gets the total audio samples decoded from RTP packets (receive only).
double audioLevel
Gets most recent audio level of the received stream, range [0.0, 1.0] (receive only,...
NSInteger estimatedPlayoutTimestamp
Gets the estimated playout timestamp (receive only).
double totalSamplesDuration
Gets total duration of all audio samples received, in seconds (receive only, audio only).
NSInteger packetsReceived
Gets the total number of packets received (receive only).
unsigned long long concealedSamples
Gets samples produced by concealment instead of real decode (receive only, audio only).
unsigned long long headerBytesReceived
Gets total bytes of RTP headers (and padding) received (receive only).
NSInteger framesDecoded
Gets the total number of frames decoded (receive only).
unsigned long long removedSamplesForAcceleration
Gets samples removed to speed up playout (acceleration) (receive only, audio only).
unsigned long long concealmentEvents
Gets number of concealment events (receive only, audio only).
NSUInteger packetsDiscarded
Gets non-FEC packets discarded by NetEQ (receive only, audio only).
unsigned long long totalSamplesReceived
Gets total audio samples generated by NetEQ (receive only, audio only).
NSUInteger fecPacketsDiscarded
Gets FEC packets discarded by NetEQ (receive only, audio only).
double jitterBufferDelay
Gets the accumulated playout delay introduced by the jitter buffer, in seconds (receive only).
double jitterBufferTargetDelay
Gets accumulated current target delay of the jitter buffer, in seconds (receive only,...
double jitterBufferMinimumDelay
Gets accumulated minimum achievable jitter buffer delay, in seconds (receive only,...
unsigned long long silentConcealedSamples
Gets subset of concealedSamples that are silent (receive only, audio only).
QOS statistics for outbound media stream (sending).
NSInteger totalEncodeTime
Gets the total time spent encoding in milliseconds (send only).
NSInteger frameHeightInput
Gets the height of the input frame (send only).
NSInteger packetsSent
Gets the total number of packets sent.
NSInteger totalPacketSendDelay
Gets the total packet send delay in milliseconds (send only).
NSUInteger headerBytesSent
Gets total bytes of RTP headers (and padding) sent (send only).
NSInteger frameRateInput
Gets the frame rate of input (send only).
NSInteger framesEncoded
Gets the total number of frames encoded (send only).
NSInteger bytesSent
Gets the total bytes sent.
NSInteger frameWidthInput
Gets the width of the input frame (send only).
Base QOS statistics for media streams (Audio, Video, Share).
NSInteger rtt
Gets the round-trip time in milliseconds.
NSString *_Nullable codecName
Gets the name of the codec. For video/share: "h264", "av1". For audio: "silk", "opus",...
NSInteger bps
Gets the bits per second.
NSInteger timestamp
Gets the timestamp of the statistics.
NSInteger height
Frame height (sent or received per direction).
ZMVideoSDKStatisticsDirection direction
Gets the direction of statistics (send or receive).
NSInteger fps
Frame rate in FPS (sent or received per direction).
ZMVideoSDKNetworkStatus networkLevel
Gets the network quality level.
ZMVideoSDKDataType statisticsType
Gets the statistics type (Audio, Video, or Share).
NSInteger max_loss
Gets the maximum packet loss ratio in per thousand (e.g. 100 means 10%).
NSInteger packetsLost
Gets the number of packets lost during transmission.
NSInteger packetsTransferred
Gets the total number of packets transferred (sent or received per direction).
NSInteger bytesTransferred
Gets the total bytes transferred (sent or received per direction).
double jitter
Gets the jitter in milliseconds.
NSInteger width
Frame width (sent or received per direction).
NSInteger avg_loss
Gets the average packet loss ratio in per thousand (e.g. 100 means 10%).
NSInteger bandwidth
Gets the estimated bandwidth in bps.
Video or share raw data pipe interface.
ZMVideoSDKRawDataType getRawdataType()
Gets the raw data data type.
ZMVideoSDKVideoStatisticInfo *_Nullable getVideoStatisticInfo()
Gets video statistic information.
ZMVideoSDKShareType getShareType()
Gets share type.
ZMVideoSDKVideoStatus *_Nullable getVideoStatus()
Gets video status.
ZMVideoSDKShareCapturePauseReason getShareCapturePauseReason()
Gets the reason why the share capture is paused.
NSString *_Nullable getVideoDeviceName()
Gets video device name.
ZMVideoSDKShareStatus getShareStatus()
Gets share status.
Remote camera control helper object interface.
ZMVideoSDKErrors requestControlRemoteCamera()
Requests to control remote camera.
ZMVideoSDKErrors giveUpControlRemoteCamera()
Give up control of the remote camera.
Represents the state and control interfaces of a share action in a Zoom session.
Represents the cursor position data during screen sharing.
unsigned int sourceID
The source id of the share cursor.
int y
The y value of the coordinate.
int x
The x value of the coordinate.
Share statistic information. Inherits QOS fields (width, height, fps, bps, direction,...
int bpf
Gets share bits per frame. Same as bps.
ZMVideoSDKNetworkStatus shareNetworkStatus
Gets share network status. Same as networkLevel.
User control interface.
BOOL reclaimHost()
Reclaim host permission. Allow the user whose role_type = 1 to reclaim the host role.
Zoom Video SDK user information.
unsigned int getAudioLevel()
Gets the current audio level of a remote user.
BOOL isIncomingLiveStreamUser()
Determines whether the user is incoming live stream user.
NSArray< ZMVideoSDKRawDataPipe * > *_Nullable getMultiCameraStreamList()
Gets the user's multi-camera stream list.
NSArray< ZMVideoSDKShareAction * > *_Nullable getShareActionList()
Gets the user's share-action list.
BOOL isInFailover()
Determines whether the user is in failover.
BOOL isInSubSession()
Determines whether the user is in a subsession.
BOOL isHost()
Determines whether the user is the host.
ZMVideoSDKWhiteboardStatus getWhiteboardStatus()
Gets the user's whiteboard sharing status.
BOOL isManager()
Determines whether the user is the manager.
NSString *_Nullable getUserKey()
Gets the user's key.
NSString *_Nullable getUserReference()
Gets the user's reference.
ZMVideoSDKRemoteCameraControlHelper *_Nullable getRemoteCameraControlHelper()
Gets the helper class instance to access the remote camera control.
ZMVideoSDKShareStatisticInfo *_Nullable getShareStatisticInfo()
Gets the user's share statistic information.
ZMVideoSDKVideoCanvas *_Nullable getVideoCanvas()
Gets the user's video canvas.
ZMVideoSDKVideoStatisticInfo *_Nullable getVideoStatisticInfo()
Gets the user's video statistic information.
NSString *_Nullable getCustomIdentity()
Gets the user's custom identity.
BOOL hasIndividualRecordingConsent()
Determines whether I agree to individual video recording.
NSString *_Nullable getUserName()
Gets the user's name in the session.
NSString *_Nullable getUserID()
Gets the user's ID.
ZMVideoSDKAudioStatus *_Nullable getAudioStatus()
Gets the user's audio status.
ZMVideoSDKRawDataPipe *_Nullable getVideoPipe()
Gets the user's video pipe.
ZMVideoSDKNetworkStatus getOverallNetworkLevel()
Gets the user's overall network quality level.
BOOL isVideoSpotLighted()
Check if user is spotlighted.
Manages the rendering of video or screen share content in the Zoom Video SDK.
Video statistic information. Inherits QOS fields (width, height, fps, bps, direction,...
int bpf
Gets video bits per frame. Same as bps.
ZMVideoSDKNetworkStatus videoNetworkStatus
Gets video network status. Same as networkLevel.
ZMVideoSDKVideoStatus provides information on the user's video device (the detected compatible video ...
BOOL isHasVideoDevice
Query if the user's device has a compatible camera. YES : compatible camera detected,...
BOOL isOn
Query if the camera is turned on. YES : camera turned on, NO : camera turned off.
YUV raw data 420 infomation interface.
BOOL canAddRef()
Determines if adding a reference to the raw data buffer is supported.
char *_Nullable yBuffer
Gets the YUVI420 Y buffer. The Y component represents the luma or brightness values.
unsigned int bufferLen
The buffer length of this data.
unsigned int resourceID
Gets the source_id of current YUV raw data.
char *_Nullable vBuffer
Gets the YUVI420 V buffer. The V component represents the chroma values.
BOOL isLimitedI420
Gets if this data is limited I420 format.
char *_Nullable buffer
The buffer data.
unsigned int streamWidth
Query stream width.
char *_Nullable uBuffer
Gets the YUVI420 U buffer. The U component represents the chroma values.
unsigned int rotation
Query the video raw data rotation.
unsigned int streamHeight
Gets the stream height.
unsigned int alphaBufferLen
Gets the alpha buffer length.
BOOL addRef()
Increase reference count by 1. Adding a reference ensures that the raw data buffer nots be released.
char * alphaBuffer
Gets video alpha mask data buffer.
int releaseRef()
Decrease reference count by 1. When finished using the raw data buffer, call releaseRef.
long long timeStamp
Millisecond timestamp.