[phpBB Debug] PHP Warning: in file [ROOT]/viewtopic.php on line 1091: Undefined array key 0 [phpBB Debug] PHP Warning: in file [ROOT]/viewtopic.php on line 1091: Trying to access array offset on value of type null [phpBB Debug] PHP Warning: in file [ROOT]/viewtopic.php on line 1098: Undefined array key 0 [phpBB Debug] PHP Warning: in file [ROOT]/viewtopic.php on line 1098: Trying to access array offset on value of type null [phpBB Debug] PHP Warning: in file [ROOT]/viewtopic.php on line 1098: Undefined array key 0 [phpBB Debug] PHP Warning: in file [ROOT]/viewtopic.php on line 1098: Trying to access array offset on value of type null JS-VBA-M: World's First Working Webgl based JS GBA emulator! - VisualBoyAdvance-M
VisualBoyAdvance-M
The continuing development of the legendary VBA gameboy advance emulator.
Non VBA-M Related on-topic discussion goes here, anything posted related to the emulator in this board will either be deleted or the content moved at staff discretion.
Hey guys just thought I'd share a project I'm working on. I am porting VBA-M to Javascript using the Emscripten C/C++ to javascript compiler and a modified version of the VBA-M SDL code.
Â
Runs natively in browser with no plugins required!
Â
Development Progress Picture (I am using Pokemon Ruby as the testcase):
Fix the command line arguments parsing code. Done.
Â
Get it to load a game and run it. Done.
Â
Get it to display the FPS meter. Done.
Â
Get it to display the game. Done.
Â
Get it to run at at least 48% speed (the cross-compiler promises the program will run at most 4x slower than native when the optimization options are configured correctly, so as my computer runs VBA-M at 87% speed, the JS version should run at 48% speed at it's slowest). WIP (still fiddling with compiler optimization options (getting 38% speed on my laptop)).
Â
Streamline the build system and fix the cmake files to work correctly with emscripten. Todo.
Nice, although Emscripten does not really mean ported. It means you "compiled" it to JavaScript really. I had been working on my own JS GBA emulator, although I've been AFK on IodineGBA (and github in general) for about a month.
Problem with emscripten is that there are certain conventions that work on the LLVM level that do not work well on the JS level. Low level heap/stack ops often do not play well when compiled via emscripten to js. Not to mention there are many programming conventions fast in C/C++ that are slow in JS that could be substituted with other conventions in JS.
Last edited by grantgalitz on Fri Oct 05, 2012 3:29 am, edited 1 time in total.
Nice, although Emscripten does not really mean ported. It means you "compiled" it to JavaScript really. I had been working on my own JS GBA emulator, although I've been AFK on IodineGBA (and github in general) for about a month.
Problem with emscripten is that there are certain conventions that work on the LLVM level that do not work well on the JS level. Low level heap/stack ops often do not play well when compiled via emscripten to js. Not to mention there are many programming conventions fast in C/C++ that are slow in JS that could be substituted with other conventions in JS.
While that is very true, Emscripten when set up correctly will automatically convert those things to the correct faster versions in javascript... I get almost a 20% speedup by compiling with some of the options...
I'm getting 20% of the actual device speed with just the default optimisations... im thinking of trying -02 with some other custom optimisations...
Last edited by ILOVEPIE on Fri Oct 05, 2012 11:04 am, edited 1 time in total.