don't cast between long and pointers for win64
[pcsx_rearmed.git] / frontend / main.c
index 51cb7bf..d846d3c 100644 (file)
@@ -43,8 +43,8 @@ static void check_memcards(void);
 #endif
 
 // don't include debug.h - it breaks ARM build (R1 redefined)
-void StartDebugger();
-void StopDebugger();
+static void StartDebugger() {}
+static void StopDebugger() {}
 
 int ready_to_go, g_emu_want_quit, g_emu_resetting;
 unsigned long gpuDisp;
@@ -122,9 +122,11 @@ void emu_set_default_config(void)
 {
        // try to set sane config on which most games work
        Config.Xa = Config.Cdda = Config.Sio =
-       Config.SpuIrq = Config.RCntFix = Config.VSyncWA = 0;
+       Config.icache_emulation = Config.SpuIrq = Config.RCntFix = Config.VSyncWA = 0;
        Config.PsxAuto = 1;
 
+       pl_rearmed_cbs.thread_rendering = 0;
+
        pl_rearmed_cbs.gpu_neon.allow_interlace = 2; // auto
        pl_rearmed_cbs.gpu_neon.enhancement_enable =
        pl_rearmed_cbs.gpu_neon.enhancement_no_main = 0;
@@ -146,7 +148,6 @@ void emu_set_default_config(void)
        pl_rearmed_cbs.gpu_peopsgl.iTexGarbageCollection = 1;
 
        spu_config.iUseReverb = 1;
-       spu_config.idiablofix = 0;
        spu_config.iUseInterpolation = 1;
        spu_config.iXAPitch = 0;
        spu_config.iVolume = 768;
@@ -155,7 +156,9 @@ void emu_set_default_config(void)
 #if defined(HAVE_PRE_ARMV7) && !defined(_3DS) /* XXX GPH hack */
        spu_config.iUseReverb = 0;
        spu_config.iUseInterpolation = 0;
+#ifndef HAVE_LIBRETRO
        spu_config.iTempo = 1;
+#endif
 #endif
        new_dynarec_hacks = 0;
        cycle_multiplier = 200;
@@ -715,7 +718,7 @@ void SysRunGui() {
         printf("SysRunGui\n");
 }
 
-static void dummy_lace()
+static void CALLBACK dummy_lace()
 {
 }
 
@@ -995,7 +998,7 @@ void *SysLoadLibrary(const char *lib) {
                tmp++;
                for (i = 0; i < ARRAY_SIZE(builtin_plugins); i++)
                        if (strcmp(tmp, builtin_plugins[i]) == 0)
-                               return (void *)(long)(PLUGIN_DL_BASE + builtin_plugin_ids[i]);
+                               return (void *)(uintptr_t)(PLUGIN_DL_BASE + builtin_plugin_ids[i]);
        }
 
 #if !defined(_WIN32) && !defined(NO_DYLIB)
@@ -1010,7 +1013,7 @@ void *SysLoadLibrary(const char *lib) {
 }
 
 void *SysLoadSym(void *lib, const char *sym) {
-       unsigned int plugid = (unsigned int)(long)lib;
+       unsigned int plugid = (unsigned int)(uintptr_t)lib;
 
        if (PLUGIN_DL_BASE <= plugid && plugid < PLUGIN_DL_BASE + ARRAY_SIZE(builtin_plugins))
                return plugin_link(plugid - PLUGIN_DL_BASE, sym);
@@ -1033,7 +1036,7 @@ const char *SysLibError() {
 }
 
 void SysCloseLibrary(void *lib) {
-       unsigned int plugid = (unsigned int)(long)lib;
+       unsigned int plugid = (unsigned int)(uintptr_t)lib;
 
        if (PLUGIN_DL_BASE <= plugid && plugid < PLUGIN_DL_BASE + ARRAY_SIZE(builtin_plugins))
                return;