Open d34db33f-1007 opened 4 years ago
UPD: https://github.com/MasterNobody/x264 lightweight h264 decoder implementation which builds just in 2Mb
UPD2: compiling custom version of ffmpeg and PyAV makes compiled binary about 8Mb. Makefile flags for ffmpeg:
./configure --enable-pic --disable-debug --enable-shared --disable-decoders --enable-decoder=h264 \
--disable-programs --disable-logging --disable-protocols --disable-avfoundation --disable-appkit \
--disable-coreimage --disable-iconv --disable-securetransport --disable-schannel \
--disable-safe-bitstream-reader --disable-large-tests --disable-doc --disable-postproc \
--disable-network --disable-encoders --disable-muxers --disable-parsers --enable-parser=h264 \
--enable-small --disable-runtime-cpudetect --disable-hwaccels --disable-demuxers --disable-devices
# size in cost of perfomance:
# --enable-small --disable-runtime-cpudetect --disable-hwaccels --disable-safe-bitstream-reader
hello! i've wrote example code of core features from this project, so you can just use it as a wiki. the snapshoting function now relies on PyAV library which costs additional 45MB when code compiled, but i'm in progress of writing my own h264 decoder in python3, which i would be glad to share either.