1 Star 0 Fork 53

Vincent.Chan / KKPlayer

forked from saint / KKPlayer 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
贡献代码
同步代码
取消
提示: 由于 Git 不支持空文件夾,创建文件夹后会生成空的 .keep 文件
Loading...
README
MIT

KKPlayer一个基于ffmpeg的视频播放器,目前移植到windows,android
希望大家多多交流 QQ群:342276504
windows:vs2008编译通过。
Android:android studio1.5 编译通过。
项目组成
KKPlayerCore 播放器核心代码
KKplayer项目是基于KKPlayerCore写的Windows例子
KKPlayerAndroid项目是基于KKPlayerCore写的android例子
Windows版本:生成的正式文件在release下,调试的在debug下。界面库采用SOUI2
IOS版本正在筹划中.
windows 编译需要定义环境变量
KKWinSdkPath,KKWinDx9Path和KKSoui2Path
dxsdk10(d3d9)下载地址:http://pan.baidu.com/s/1kV0vmVP
soui2下载地址:https://git.oschina.net/Qyerp/soui
例如
KKWinDx9Path=C:\Program Files (x86)\Microsoft DirectX SDK (June 2010)
KKWinSdkPath=C:\Program Files (x86)\Microsoft SDKs\Windows\v7.1A
KKSoui2Path=D:\work\Projects\soui

项目生成顺序:
libmfx(inter QSV编码)->zlibstat->png->skia->sdl->render->kkplayercore->kkui->jsoncpp->kkplayer
rtmpt延迟格式控制请使用以下格式librtmp:rtmp:xxxxxxxxxxxxxxxxxxxxxx

ffmpeg3.0 以上版本Android编译
如果直接按照未修改的配置进行编译,结果编译出来的so文件类似libavcodec.so.55.39.101,版本号位于so之后,Android上似乎无法加载。
因此需要按如下修改:
将configure文件中的如下四行:
SLIBNAME_WITH_MAJOR='$(SLIBNAME).$(LIBMAJOR)'
LIB_INSTALL_EXTRA_CMD='$$(RANLIB)"$(LIBDIR)/$(LIBNAME)"'
SLIB_INSTALL_NAME='$(SLIBNAME_WITH_VERSION)'
SLIB_INSTALL_LINKS='$(SLIBNAME_WITH_MAJOR)$(SLIBNAME)'
替换为:
SLIBNAME_WITH_MAJOR='$(SLIBPREF)$(FULLNAME)-$(LIBMAJOR)$(SLIBSUF)'
LIB_INSTALL_EXTRA_CMD='$$(RANLIB)"$(LIBDIR)/$(LIBNAME)"'
SLIB_INSTALL_NAME='$(SLIBNAME_WITH_MAJOR)'
SLIB_INSTALL_LINKS='$(SLIBNAME)'

sh:
#!/bin/bash
export TMPDIR=/home/ubuntu64/FFmpeg/Tmep
NDK=/home/ubuntu64/FFmpeg/android-ndk-r10
SYSROOT=$NDK/platforms/android-9/arch-arm/
TOOLCHAIN=$NDK/toolchains/arm-linux-androideabi-4.8/prebuilt/linux-x86_64
function build_one
{
./configure <br/> --prefix=/home/ubuntu64/FFmpeg/ff3.1.2Jni <br/> --enable-shared <br/> --disable-static <br/> --disable-doc <br/> --disable-ffserver <br/> --enable-cross-compile <br/> --cross-prefix=$TOOLCHAIN/bin/arm-linux-androideabi- <br/> --target-os=linux <br/> --arch=arm <br/> --disable-encoders <br/> --sysroot=$SYSROOT <br/> --extra-cflags="-Os -fpic $ADDI_CFLAGS" <br/> --extra-ldflags="$ADDI_LDFLAGS" <br/> --enable-protocol=rtmp
$ADDITIONAL_CONFIGURE_FLAG
}
CPU=arm
PREFIX=$(pwd)/android/$CPU
ADDI_CFLAGS="-marm"
build_one

windowVc(Vs2010)编译ffmpeg(https://ffmpeg.org/platform.html#Microsoft-Visual-C_002b_002b-or-Intel-C_002b_002b-Compiler-for-Windows)
./configure的3580行修改为:
if [ -z "$cl_major_ver" ] || [ $cl_major_ver -ge 18 ]; then
cc_default="cl"
else
cc_default="c99wrap cl"
fi
cc_default="c99wrap cl"
例如(启用共享库,关闭所有编码器):
./configure --toolchain=msvc --extra-cflags='-IC:/msinttypes' --prefix='./ffmpegBin' --incdir='./ffmpegBin/incdir' --enable-shared --disable-encoders
更新日志:
2017-5-23
     移除srslibrtmpplugin. 添加librtmpplugin
     支持视频分片(像优酷那种视频分片)
     整合FFmpeg的mediacode解码
     intermedia h264解码
     ffmpge更新到3.3.2
2017-5-30
     windows 添加libkkplayer库。支持无窗口dui渲染,或者以窗口进行渲染
     修改sdl1支持同时创建多个音频渲染器
     修正渲染器一些bug
2017-7-14
     windows libkkplayer库,回调数据做修改,添加新的接口
       d3d9 4k渲染优化,修正qsv 解码265
     android 添加更多的接口

The MIT License (MIT) Copyright (c) 2015 saint Author e-mail: lssaint@163.com Author qq: 784200679 KKPlayer WWW: http://www.70ic.com/KKplayer Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

简介

一个基于ffmpeg的开源播放器 展开 收起
C++
MIT
取消

发行版

暂无发行版

贡献者

全部

近期动态

加载更多
不能加载更多了
C++
1
https://gitee.com/vincentchan/KKPlayer.git
git@gitee.com:vincentchan/KKPlayer.git
vincentchan
KKPlayer
KKPlayer
master

搜索帮助