void vpm_frontend_init(void) { /* clear all core options */ memset(&options,0,sizeof(options)); #if MAMEVER < 6100 /* directly define these */ options.use_emulated_ym3812 = 1; #endif /* MAMEVER */ /* create the rc object */ if (!(rc = rc_create())) { fprintf (stderr, "error on rc creation\n"); exit(1); } if (rc_register(rc, opts)) { fprintf (stderr, "error on registering opts\n"); exit(1); } /* need a decent default for debug width/height */ if (options.debug_width == 0) options.debug_width = 640; if (options.debug_height == 0) options.debug_height = 480; #if MAMEVER >= 6100 options.debug_depth = 8; // Debugger only works with 8 bits? #endif /* MAMEVER */ options.gui_host = 1; //#ifdef MAME_DEBUG // options.mame_debug = 1; //#endif /* MAME_DEBUG */ #if (defined(DEBUG) || defined(_DEBUG)) set_option("log","1",0); #endif /* DEBUG */ }
struct rc_struct *cli_rc_create(void) { struct rc_struct *result; result = rc_create(); if (!result) return NULL; if (rc_register(result, opts)) { rc_destroy(result); return NULL; } return result; }