-
Notifications
You must be signed in to change notification settings - Fork 2.8k
大牛直播iOS播放端SDK说明
- 相关库:libSmartPlayerSDK.a
- 相关头文件:
- nt_event_define.h
- SmartPublisherSDK.h
- 如集需要引入的framework
- libbz.tbd
- libiconv.tbd
- libstdc++.tbd
- Accelerate.framework
- AssetsLibrary.framework
- AudioToolBox.framework
- AVFoundation.framework
- CoreMedia.framework
- Foundation.framework
- UIKit.framework
- VideoToolBox.framework
- 如需集成到自己系统测试,请用大牛直播的app name:
Info.plist-->右键Open As-->Source Code
- 添加或者编辑
<key>CFBundleName</key>
<string>SmartiOSPlayer</string>
- 快照添加到“照片”权限:
Info.plist-->右键Open As-->Source Code
- 添加
<key>NSPhotoLibraryUsageDescription</key>
<string>1</string>
1.SmartPlayerInitPlayer,初始化,创建player实例;
2.SmartPlayerSetVideoDecoderMode,设置视频解码模式,如不设置,默认软解码,0:软解码,1:硬解码;
3.SmartPlayerCreatePlayView,创建播放view;
4.SmartPlayeReleasePlayView,释放播放view;
5.SmartPlayerSetPlayView,设置播放view;
6.SmartPlayerSetBuffer,设置播放端缓存数据buffer;
7.SmartPlayerSetRTSPTcpMode,设置TCP播放模式,注意:此接口仅用于RTSP流;
8.SmartPlayerSetFastStartup,Set fast startup(快速启动),设置快速启动后,如果CDN缓存GOP,player可快速播放;
9.SmartPlayerSetPlayURL,设置播放url;
10.SmartPlayerSwitchPlaybackUrl,快速切换播放url,快速切换时,只换播放source部分,适用于不同数据流之间,快速切换;
11.SmartPlayerSaveImageFlag,设置是否启用快照;
12.SmartPlayerSaveCurImage,播放过程中,根据设置路径和文件名,实时快照;
13.SmartPlayerStart,开始播放;
14.SmartPlayerSetMute,设置播放过程中,实时静音/去掉静音;
15.SmartPlayerStop,停止播放;
16.SmartPlayerUnInitPlayer,销毁播放实例;
17.SmartPlayerGetSDKVersionID,获取当前SDK版本;
18.handleSmartPlayerEvent,Event callback处理。