--- uae/src/main.c 2018/04/24 16:50:03 1.1.1.10 +++ uae/src/main.c 2018/04/24 16:58:19 1.1.1.13 @@ -16,12 +16,12 @@ #include "threaddep/penguin.h" #include "uae.h" #include "gensound.h" +#include "audio.h" #include "sounddep/sound.h" #include "events.h" #include "memory.h" #include "custom.h" #include "serial.h" -#include "readcpu.h" #include "newcpu.h" #include "disk.h" #include "debug.h" @@ -48,6 +48,8 @@ int no_gui = 0; int joystickpresent = 0; int cloanto_rom = 0; +struct gui_info gui_data; + char warning_buffer[256]; char optionsfile[256]; @@ -147,6 +149,7 @@ void default_prefs (struct uae_prefs *p) p->immediate_blits = 0; p->blits_32bit_enabled = 0; + p->collision_level = 0; strcpy (p->df[0], "df0.adf"); strcpy (p->df[1], "df1.adf"); @@ -161,7 +164,7 @@ void default_prefs (struct uae_prefs *p) strcpy (p->path_floppy, "./"); strcpy (p->path_hardfile, "./"); - p->m68k_speed = 4; + p->m68k_speed = 0; p->cpu_level = 2; p->cpu_compatible = 0; p->address_space_24 = 0; @@ -173,6 +176,8 @@ void default_prefs (struct uae_prefs *p) p->bogomem_size = 0x00000000; p->gfxmem_size = 0x00000000; + p->nr_floppies = 4; + p->mountinfo = alloc_mountinfo (); } @@ -242,11 +247,14 @@ static void fix_options (void) currprefs.fastmem_size = 0; err = 1; } +#if 0 if (currprefs.m68k_speed < -1 || currprefs.m68k_speed > 20) { fprintf (stderr, "Bad value for -w parameter: must be -1, 0, or within 1..20.\n"); currprefs.m68k_speed = 4; err = 1; } +#endif + if (currprefs.produce_sound < 0 || currprefs.produce_sound > 3) { fprintf (stderr, "Bad value for -S parameter: enable value must be within 0..3\n"); currprefs.produce_sound = 0; @@ -272,6 +280,12 @@ static void fix_options (void) } #endif + if (currprefs.nr_floppies < 1 || currprefs.nr_floppies > 4) { + fprintf (stderr, "Invalid number of floppies. Using 4.\n"); + currprefs.nr_floppies = 4; + err = 1; + } + if (err) fprintf (stderr, "Please use \"uae -h\" to get usage information.\n"); } @@ -460,6 +474,7 @@ void real_main (int argc, char **argv) rtarea_init (); hardfile_install (); scsidev_install (); + ahi_install (); parse_cmdline_and_init_file (argc, argv); @@ -480,7 +495,7 @@ void real_main (int argc, char **argv) exit (0); } } - if (sound_available && currprefs.produce_sound > 1 && ! init_sound ()) { + if (sound_available && currprefs.produce_sound > 1 && ! init_audio ()) { fprintf (stderr, "Sound driver unavailable: Sound output disabled\n"); currprefs.produce_sound = 0; }