emscripten resources loaded; crashes on some gl function