added javascript interface, added ffmpeg support (much better)