mirror of
https://github.com/ggerganov/wave-share.git
synced 2026-02-06 01:16:13 +08:00
Reduce binary size to ~1MB
- Recompiled main.cpp with -s WASM=1 - Recompiled FFTW with O3 flag
This commit is contained in:
@@ -71,5 +71,5 @@ To build this project you need Emscripten compiler. Additionally, you need [FFTW
|
||||
- Ultrasonic sound transmission does not work on most devices. Probably hardware limitations?
|
||||
- In presence of multiple local networks, cannot currently select which one to use. Always the first one is used
|
||||
- There is occasionally sound cracking during transmission. Need to optimize the Tx code
|
||||
- The size of the emscripten generated .js is too big (~4MB). Rewrite in pure JS?
|
||||
- The size of the emscripten generated .js is too big (~1MB). Rewrite in pure JS?
|
||||
- On mobile, using Firefox, the page can remain running in the background even after closing the tab
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
echo "static const char * BUILD_TIMESTAMP=\"`date`\";" > build_timestamp.h
|
||||
|
||||
em++ -Wall -Wextra -O3 -std=c++11 -s USE_SDL=2 ./main.cpp -o wave.js -I ./fftw-3.3.3/api ./lib/libfftw3f.a \
|
||||
em++ -Wall -Wextra -O3 -std=c++11 -s USE_SDL=2 -s WASM=1 ./main.cpp -o wave.js -I ./fftw-3.3.3/api ./lib/libfftw3f.a \
|
||||
-s EXPORTED_FUNCTIONS='["_getText", "_getSampleRate", "_setText", "_getAverageRxTime_ms", "_setParameters",
|
||||
"_getFramesLeftToRecord", "_getFramesToRecord",
|
||||
"_getFramesLeftToAnalyze", "_getFramesToAnalyze",
|
||||
|
||||
Reference in New Issue
Block a user