ZegoLiveRoom
Namespaces | Functions
zego-api-mediaplayer.h File Reference
#include <memory>
#include "zego-api-defines.h"
#include "media_player.h"
#include "zego-api-mediaplayer-defines.h"

Go to the source code of this file.

Namespaces

namespace  ZEGO
 
namespace  ZEGO::MEDIAPLAYER
 

Functions

ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::InitWithType (ZegoMediaPlayerType type, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::CreatePlayer (ZegoMediaPlayerType type, ZegoMediaPlayerIndex index)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::DestroyPlayer (ZegoMediaPlayerIndex index)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::SetVolume (int volume, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::SetPublishVolume (int volume, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::SetPlayVolume (int volume, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API int ZEGO::MEDIAPLAYER::GetPublishVolume (ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API int ZEGO::MEDIAPLAYER::GetPlayVolume (ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::SetPlaySpeed (float speed, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::Start (const char *path, bool repeat, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::Start (const char *path, bool repeat, long startPosition, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::Start (const char *path, long startPosition, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::Start (unsigned char *mediaData, int mediaDataLen, long startPosition, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::StartCopyrightedMusic (const char *resourceID, long startPosition, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::Stop (ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::Pause (ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::Resume (ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::SeekTo (long duration, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API long ZEGO::MEDIAPLAYER::GetDuration (ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API long ZEGO::MEDIAPLAYER::GetCurrentDuration (ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API long ZEGO::MEDIAPLAYER::GetCurrentRenderingDuration (ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::MuteLocal (bool mute, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::Load (const char *path, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::Load (const char *path, long startPosition, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::Load (unsigned char *mediaData, int mediaDataLen, long startPosition, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::LoadCopyrightedMusic (const char *resourceID, long startPosition, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::Load (const ZegoMediaPlayerResource &resource, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::SetView (void *view, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::SetView (const AV::ZegoView &view, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API long ZEGO::MEDIAPLAYER::SetAudioStream (long streamIndex, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::SetAudioPublishStream (long streamIndex, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::SetAudioTrackMode (ZegoMediaPlayerAudioTrackMode mode, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::SetPlayerType (ZegoMediaPlayerType type, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API long ZEGO::MEDIAPLAYER::GetAudioStreamCount (ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::EnableRepeatMode (bool enable, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::SetLoopCount (int loopCount, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::TakeSnapshot (ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API bool ZEGO::MEDIAPLAYER::SetProcessInterval (long interval, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API bool ZEGO::MEDIAPLAYER::RequireHWDecoder (ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::SetViewMode (AV::ZegoVideoViewMode mode, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::SetBackgroundColor (int color, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::ClearView (ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::EnableAccurateSeek (bool enable, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::SetAccurateSeekTimeout (long timeoutInMS, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::SetActiveAudioChannel (ZegoMediaPlayerAudioChannel channel, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::SetAudioChannelKeyShift (ZegoMediaPlayerAudioChannel channel, float keyShiftValue, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::EnableAudioChannelKeyShift (ZegoMediaPlayerAudioChannel channel, bool enable, float keyShiftValue, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::SetOnlineResourceCache (int timeInMS, int sizeInByte, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API bool ZEGO::MEDIAPLAYER::GetOnlineResourceCacheStat (int *timeInMS, int *sizeInByte, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::SetBufferThreshold (int thresholdInMS, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::SetLoadResourceTimeout (int timeoutInMS, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::SetHttpHeaders (ZegoMediaPlayerHttpHeader *headers, int headerSize, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::SetEventWithIndexCallback (IZegoMediaPlayerEventWithIndexCallback *callback, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::SetVideoDataWithIndexCallback (IZegoMediaPlayerVideoDataWithIndexCallback *callback, ZegoMediaPlayerVideoPixelFormat format, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::SetAudioDataCallback (IZegoMediaPlayerAudioDataCallback *callback, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::SetMediaSideInfoCallback (IZegoMediaPlayerMediaSideInfoCallback *callback, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::SetMediaPlayerFileReader (ZegoMediaPlayerFileReader *reader, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::SetSoundInfoCallback (IZegoMediaPlayerSoundInfoCallback *callback, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 设置声音信息回调,包括声浪、频谱。 More...
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::EnableSoundLevelMonitor (bool enable, unsigned int timeInMS=200, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 是否开启声浪监听 More...
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::EnableFrequencySpectrumMonitor (bool enable, unsigned int timeInMS=200, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 是否开启频谱监听 More...
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::SetBlockDataCallback (IZegoMediaPlayerBlockDataCallback *callback, int blockSize, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::AttachToPublishChannel (AV::PublishChannelIndex channel=AV::PUBLISH_CHN_AUX, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 指定某个播放器绑定到推流通道,注意不能为主路,当前复制播放器音频到辅路只支持channel 1,推荐设置到channel 1。 More...
 
ZEGOAVKIT_API const char * ZEGO::MEDIAPLAYER::GetMetaDataValue (const char *key, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 通过键值获取保存在媒体文件中的元数据信息 More...
 
ZEGOAVKIT_API ZegoMediaPlayerMediaInfo ZEGO::MEDIAPLAYER::GetMediaInfo (ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::UpdatePosition (const float position[3], ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 更新媒体播放器(音频源)位置 More...
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::EnableLiveAudioEffect (bool enable, ZegoLiveAudioEffectMode mode, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 开启现场音效 More...
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::SetPlayMediaStreamType (ZegoMediaStreamType type, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 设置媒体播放器播放的媒体流类型,用于仅播放音频流或者视频流的场景 More...
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::EnableLocalCache (bool enable, const char *cache_dir, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 开启本地缓存文件 More...
 
ZEGOAVKIT_API bool ZEGO::MEDIAPLAYER::GetPlaybackStatistics (ZegoMediaPlayerStatisticsInfo &stat, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 获取播放器当前播放统计信息 More...
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::EnableViewMirror (bool enable, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 开启画面镜像 More...
 
ZEGOAVKIT_API void ZEGO::MEDIAPLAYER::EnableStatusMonitor (bool enable, ZegoMediaPlayerIndex index=ZegoMediaPlayerIndexFirst)
 开启播放器启异常状态监控 More...