ZegoAudioLivePublisherDelegate Protocol Reference

Conforms to NSObject
Declared in ZegoAudioRoomApi-Publisher.h

– onPublishStateUpdate:streamID:streamInfo: required method

推流状态更新

- (void)onPublishStateUpdate:(int)stateCode streamID:(NSString *)streamID streamInfo:(NSDictionary *)info

Parameters

stateCode

状态码

streamID

流ID

info

推流信息

Declared In

ZegoAudioRoomApi-Publisher.h

– onPublishQualityUpdate:quality:

发布质量更新

- (void)onPublishQualityUpdate:(NSString *)streamID quality:(ZegoApiPublishQuality)quality

Parameters

streamID

streamID 发布流 ID

quality

quality 参考ZegoApiPublishQuality定义

Discussion

startPublish 后,该 API 会被多次回调。调用者可以在此回调中获取当前的视频质量数据,加以处理

Declared In

ZegoAudioRoomApi-Publisher.h

– onAuxCallback:dataLen:sampleRate:channelCount:

混音数据输入回调

- (void)onAuxCallback:(void *)pData dataLen:(int *)pDataLen sampleRate:(int *)pSampleRate channelCount:(int *)pChannelCount

Parameters

pData

混音数据

pDataLen

缓冲区长度。实际填充长度必须为 0 或是缓冲区长度。0 代表无混音数据

pSampleRate

混音数据采样率,支持16k、32k、44.1k、48k

pChannelCount

混音数据声道数,支持1、2

Discussion

用户调用该 API 将混音数据传递给 SDK。混音数据 bit depth 必须为 16

Warning: Deprecated,请使用 ZegoAudioAuxDelgate 代替

Declared In

ZegoAudioRoomApi-Publisher.h

– onRelayCDNStateUpdate:streamID:

转推CDN状态信息

- (void)onRelayCDNStateUpdate:(NSArray<ZegoAPIStreamRelayCDNInfo*> *)statesInfo streamID:(NSString *)streamID

Parameters

statesInfo

CDN状态信息

streamID

推流的流ID

Declared In

ZegoAudioRoomApi-Publisher.h