I have updated the Oryol samples page with WebAssembly versions built with 
emscripten+binaryen (as described here, using the spidermonkify.py 
post-link-pass: https://github.com/kripken/emscripten/wiki/WebAssembly

The sample page is here: http://floooh.github.io/oryol/

For the wasm samples you need the latest Firefox Nightly or Chrome Canary, 
and manually enable WebAssembly support via about:config or chrome://flags/.

No code changes were necessary and everything was working out of the box 
(at least once I figured out how compilation and conversion to the 'right' 
wasm format works).

A few nitpicks and questions:

- the standard emscripten shell-html page for wasm causes a 'synchronous 
XMLHttpRequest' warning on the JS console, and it seems to me that the 
loading is indeed synchronous (the spinning loader I use for the asm.js 
version didn't show up), is there a recommended way to properly load the 
wasm module and all other initially needed files asynchronously?

- not related, but I noticed that github-pages doesn't compress the .wasm 
and .mem files, especially for the .wasm file this is bad since the missing 
compressing undoes it's size- and loading-time advantage versus the asm.js 
version. 

Since I can't reconfigure the server-side, I did a dirty trick and renamed 
the files to .wasm.txt and .mem.txt (yeah I know...) which causes them to 
be properly compressed. This probably is a (weak) argument for having 
compression built right into the wasm format instead of relying on the web 
server to compress, compression is absolutely critical for wasm files, but 
sometimes the web server configuration is off-limits.

All minor stuff of course, all in all I'm extremely impressed how well the 
whole thing already works :)

Cheers,
-Floh.

-- 
You received this message because you are subscribed to the Google Groups 
"emscripten-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to