This app uses MP3 encoding as an example to demonstrate diffrent approaches to handle cpu intense tasks on webpages, they are:
- pure Javascript (lamejs)
- pure Javascript + Web Worker
- asm.js (mp3-lame-encoder)
- asm.js + Web Worker
- Web Assembly (modified mp3-lame-encoder)
- Web Assembly + Web Worker
Serve the files in public
folder as static files, for example:
npm install http-server -g
http-server public
- open http://localhost:8080
For many reasons I need to modify the encoding libs used in this demo to fit the needs, for example mpe-lame-encoder does not support Web Assembly yet. The included codes are modified but all algorithm implementations are crafted by the original projects.
The Water Ripples component is from React-motion's Demo-7