make some things a bit more optimised for web usage

This commit is contained in:
Ash Wolf
2019-12-26 00:19:37 +00:00
parent 015f6c94d4
commit 621d21abe7
8 changed files with 63 additions and 31 deletions

View File

@ -1,6 +1,6 @@
#!/bin/sh
FLAGS="-O3 --profiling -s WASM_OBJECT_FILES=0 -std=c++17"
FLAGS="-O3 --profiling -g -s WASM_OBJECT_FILES=0 -std=c++17"
mkdir -p obj
for i in arm710 emubase etna windermere; do emcc -c $FLAGS -o obj/$i.o ../WindCore/$i.cpp; done

View File

@ -120,15 +120,8 @@ int main(int argc, char **argv) {
printf("SDL_SetVideoMode failed: %s\n", SDL_GetError());
return 1;
}
// window = SDL_CreateWindow(
// "WindEmu",
// SDL_WINDOWPOS_UNDEFINED, SDL_WINDOWPOS_UNDEFINED,
// emu->getDigitiserWidth(), emu->getDigitiserHeight(),
// 0);
// if (window == NULL) {
// printf("SDL_CreateWindow failed: %s\n", SDL_GetError());
// return 1;
// }
EM_ASM("SDL.defaults.copyOnLock = false; SDL.defaults.discardOnLock = true; SDL.defaults.opaqueFrontBuffer = false;");
emscripten_set_main_loop(&emuEventLoop, 64, 1);