File | Date | Author | Commit |
---|---|---|---|
Document | 2021-08-08 |
![]() |
[68d8df] Chore:调整目录结构 |
OC | 2022-01-24 |
![]() |
[51be75] Add oc project |
Swift | 2022-01-24 |
![]() |
[5130b7] Remove test case |
.gitignore | 2021-12-02 |
![]() |
[b76953] ignore IJKMediaFramework |
CHANGELOG.md | 2021-11-18 |
![]() |
[1926ef] close try look with fix #6 |
LICENSE | 2019-07-20 |
![]() |
[594d9b] Add 1.0.0 新建项目 |
README.md | 2022-01-24 |
![]() |
[b27540] Update README |
README_EN.md | 2022-01-24 |
![]() |
[b27540] Update README |
🎸 - 好消息,音视频播放器翻天覆地大改版她来了!!!
English | 简体中文
动态切换内核,支持边下边播的播放器方案
视频支持格式:mp4、m3u8、wav、avi
音频支持格式:midi、mp3、
![]() |
![]() |
---|---|
// MARK: - KJPlayerFreeDelegate
extension DetailsViewController: KJPlayerFreeDelegate {
/// 获取免费试看时间
/// - Parameter player: 播放器内核
/// - Returns: 试看时间,返回零不限制
func kj_freeLookTime(with player: KJBasePlayer) -> TimeInterval {
return 50
}
/// 试看结束响应
/// - Parameters:
/// - player: 播放器内核
/// - currentTime: 当前播放时间
func kj_freeLookTime(with player: KJBasePlayer, currentTime: TimeInterval) {
}
}
self.player.kj_closeFreeLookTimeLimit()
pod 'KJPlayer/FreeTime' # vip尝试观看功能
// MARK: - KJPlayerSkipDelegate
extension DetailsViewController: KJPlayerSkipDelegate {
/// 跳过片头
/// - Parameter player: 内核
/// - Returns: 需要跳过的时间
func kj_skipOpeningTime(with player: KJBasePlayer) -> TimeInterval {
return 18
}
/// 跳过片头响应
/// - Parameters:
/// - player: 内核
/// - openingTime: 跳过播放时间
func kj_skipOpeningTime(with player: KJBasePlayer, openingTime: TimeInterval) {
self.backview.hintTextLayer.kj_displayHintText("跳过片头,自动播放",
time: 5,
position: KJPlayerHintPositionBottom)
}
}
pod 'KJPlayer/SkipTime' # vip跳过片头片尾功能
// MARK: - KJPlayerRecordDelegate
extension DetailsViewController: KJPlayerRecordDelegate {
/// 获取是否需要记录响应
/// - Parameter player: 播放器内核
/// - Returns: 是否需要记忆播放
func kj_recordTime(with player: KJBasePlayer) -> Bool {
return true
}
/// 获取到上次播放时间响应
/// - Parameters:
/// - player: 播放器内核
/// - lastTime: 上次播放时间
func kj_recordTime(with player: KJBasePlayer, lastTime: TimeInterval) {
}
}
self.player.kj_saveRecordLastTime()
pod 'KJPlayer/RecordTime' # vip自动记忆播放功能
备注提示:该功能大于跳过片头功能,简单讲就是该功能实现之后下次会直接从上次播放位置开始继续观看
pod 'KJPlayer/MIDI'
pod 'KJPlayer/IJKPlayer'
pod 'KJPlayer/AVPlayer/AVCore'
pod 'KJPlayer/CustomView'
pod 'KJPlayer/Database'
AVPlayer内核扩展功能
pod 'KJPlayer/AVPlayer/AVDownloader'
记忆播放:pod 'KJPlayer/RecordTime'
pod 'KJPlayer/FreeTime'
pod 'KJPlayer/SkipTime'
pod 'KJPlayer/Cache'
视频截屏板块:pod 'KJPlayer/Screenshots'
切换内核:pod 'KJPlayer/DynamicSource
大致流程就差不多这样子,Demo也写的很详细,可以自己去看看🎷
救救孩子吧,谢谢各位老板。
🥺