1 Star 2 Fork 5

fylsle/WasmVideoPlayerWebScoket

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
build_decoder_wasm.sh 734 Bytes
一键复制 编辑 原始数据 按行查看 历史
冯宸宇 提交于 2020-07-13 11:03 . 'finished'
rm -rf libffmpeg.wasm libffmpeg.js
export TOTAL_MEMORY=67108864
export EXPORTED_FUNCTIONS="[ \
'_initDecoder', \
'_uninitDecoder', \
'_openDecoder', \
'_closeDecoder', \
'_sendData', \
'_decodeOnePacket', \
'_seekTo', \
'_main',
'_malloc',
'_free'
]"
echo "Running Emscripten..."
emcc decoder.c dist/lib/libavformat.a dist/lib/libavcodec.a dist/lib/libavutil.a dist/lib/libswscale.a \
-O3 \
-I "dist/include" \
-s WASM=1 \
-s TOTAL_MEMORY=${TOTAL_MEMORY} \
-s EXPORTED_FUNCTIONS="${EXPORTED_FUNCTIONS}" \
-s EXTRA_EXPORTED_RUNTIME_METHODS="['addFunction']" \
-s RESERVED_FUNCTION_POINTERS=14 \
-s FORCE_FILESYSTEM=1 \
-o libffmpeg.js
echo "Finished Build"
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
JavaScript
1
https://gitee.com/fylsle/WasmVideoPlayerWebScoket.git
git@gitee.com:fylsle/WasmVideoPlayerWebScoket.git
fylsle
WasmVideoPlayerWebScoket
WasmVideoPlayerWebScoket
master

搜索帮助