From: Toni Wilen Date: Thu, 28 Dec 2006 22:49:23 +0000 (+0200) Subject: imported winuaesrc1340b8b.zip X-Git-Tag: 2100~255 X-Git-Url: https://git.unchartedbackwaters.co.uk/w/?a=commitdiff_plain;h=851440e017838a350561d0692b9e32e7a9280309;p=francis%2Fwinuae.git imported winuaesrc1340b8b.zip --- diff --git a/custom.c b/custom.c index 31028182..f803d6cf 100755 --- a/custom.c +++ b/custom.c @@ -2634,12 +2634,20 @@ static void INTREQ_f(uae_u32 data) rethink_cias (); } +static void INTREQ_d (uae_u16 v, int d) +{ + if (!currprefs.cpu_compatible || v == 0) + INTREQ_f(v); + else + event2_newevent2(d, v, INTREQ_f); +} + void INTREQ (uae_u16 v) { if (!currprefs.cpu_compatible) INTREQ_f(v); else - event2_newevent2(6, v, INTREQ_f); + INTREQ_d(v, 6); } static void ADKCON (int hpos, uae_u16 v) @@ -4122,7 +4130,7 @@ static void vsync_handler (void) handle_events (); - INTREQ (0x8020); + INTREQ_d (0x8000 | 0x0020, 2); if (bplcon0 & 4) lof ^= 0x8000; @@ -4383,20 +4391,11 @@ static void hsync_handler (void) next_lineno = lineno; reset_decisions (); } -#if 1 + #ifdef FILESYS if (uae_int_requested) { INTREQ (0x8000 | 0x0008); } -#endif -#if 0 - { - extern volatile int bsd_int_requested; - if (bsd_int_requested) { - INTREQ (0x8000 | 0x2000); - } - } -#endif #endif /* See if there's a chance of a copper wait ending this line. */ @@ -4643,8 +4642,8 @@ void customreset (void) uae_u32 vv; audio_update_adkmasks (); - INTENA (0); - INTREQ (0); + INTENA_f (0); + INTREQ_f (0); #if 0 DMACON (0, 0); #endif diff --git a/od-win32/sounddep/sound.c b/od-win32/sounddep/sound.c index 437249a4..ee57b6c1 100755 --- a/od-win32/sounddep/sound.c +++ b/od-win32/sounddep/sound.c @@ -510,7 +510,9 @@ void restart_sound_buffer(void) hr = IDirectSoundBuffer_GetCurrentPosition (lpDSBsecondary, &playpos, &safed); if (FAILED(hr)) return; - writepos = playpos + snd_writeoffset; + writepos = playpos + snd_writeoffset - 2 * sndbufsize; + if (writepos < 0) + writepos += dsoundbuf; cf (writepos); } @@ -608,6 +610,7 @@ static void finish_sound_buffer_ds (void) diff = dsoundbuf - playpos + writepos; if (diff < safedist || diff > snd_totalmaxoffset_uf) { +#if 0 hr = IDirectSoundBuffer_Lock (lpDSBsecondary, writepos, sndbufsize, &b1, &s1, &b2, &s2, 0); if (SUCCEEDED(hr)) { memset (b1, 0, s1); @@ -615,11 +618,15 @@ static void finish_sound_buffer_ds (void) memset (b2, 0, s2); IDirectSoundBuffer_Unlock (lpDSBsecondary, b1, s1, b2, s2); } +#endif gui_data.sndbuf_status = -1; statuscnt = SND_STATUSCNT; + if (diff > snd_totalmaxoffset_uf) + writepos += dsoundbuf - diff; writepos += sndbufsize; cf(writepos); - continue; + diff = safedist; + break; } if (diff > snd_totalmaxoffset_of) { @@ -627,7 +634,7 @@ static void finish_sound_buffer_ds (void) statuscnt = SND_STATUSCNT; restart_sound_buffer(); diff = snd_writeoffset; - write_log("SOUND: overflow (%d %d)\n", diff, snd_totalmaxoffset_of); + write_log("SOUND: underflow (%d %d)\n", diff, snd_totalmaxoffset_of); break; } diff --git a/od-win32/win32.c b/od-win32/win32.c index 8e6cd132..b019679c 100755 --- a/od-win32/win32.c +++ b/od-win32/win32.c @@ -893,8 +893,8 @@ static LRESULT CALLBACK AmigaWindowProc (HWND hWnd, UINT message, WPARAM wParam, case WM_WINDOWPOSCHANGED: GetWindowRect (hWnd, &amigawin_rect); if (!isfullscreen()) { - currprefs.gfx_size_win.x = amigawin_rect.left; - currprefs.gfx_size_win.y = amigawin_rect.top; + changed_prefs.gfx_size_win.x = amigawin_rect.left; + changed_prefs.gfx_size_win.y = amigawin_rect.top; } break; @@ -1188,8 +1188,8 @@ static LRESULT CALLBACK MainWindowProc (HWND hWnd, UINT message, WPARAM wParam, RegSetValueEx(hWinUAEKey, "xPos", 0, REG_DWORD, (LPBYTE)&left, sizeof(LONG)); RegSetValueEx(hWinUAEKey, "yPos", 0, REG_DWORD, (LPBYTE)&top, sizeof(LONG)); } - currprefs.gfx_size_win.x = left; - currprefs.gfx_size_win.y = top; + changed_prefs.gfx_size_win.x = left; + changed_prefs.gfx_size_win.y = top; } return 0; } diff --git a/od-win32/win32.h b/od-win32/win32.h index 2a0fd924..d200f446 100755 --- a/od-win32/win32.h +++ b/od-win32/win32.h @@ -17,7 +17,7 @@ #define WINUAEBETA 8 #define WINUAEPUBLICBETA 1 -#define WINUAEDATE MAKEBD(2006, 12, 28) +#define WINUAEDATE MAKEBD(2006, 12, 29) #define IHF_WINDOWHIDDEN 6 #define NORMAL_WINDOW_STYLE (WS_VISIBLE | WS_BORDER | WS_CAPTION | WS_MINIMIZEBOX | WS_SYSMENU) diff --git a/od-win32/win32gfx.c b/od-win32/win32gfx.c index 1a3647f1..be87b936 100755 --- a/od-win32/win32gfx.c +++ b/od-win32/win32gfx.c @@ -1113,8 +1113,10 @@ int check_prefs_changed_gfx (void) c |= currprefs.gfx_size_fs.height != changed_prefs.gfx_size_fs.height ? (2|8) : 0; c |= currprefs.gfx_size_win.width != changed_prefs.gfx_size_win.width ? (2|8) : 0; c |= currprefs.gfx_size_win.height != changed_prefs.gfx_size_win.height ? (2|8) : 0; +#if 0 c |= currprefs.gfx_size_win.x != changed_prefs.gfx_size_win.x ? 16 : 0; c |= currprefs.gfx_size_win.y != changed_prefs.gfx_size_win.y ? 16 : 0; +#endif c |= currprefs.color_mode != changed_prefs.color_mode ? (2|8) : 0; c |= currprefs.gfx_afullscreen != changed_prefs.gfx_afullscreen ? (2|8) : 0; c |= currprefs.gfx_pfullscreen != changed_prefs.gfx_pfullscreen ? (2|8) : 0; diff --git a/od-win32/winuaechangelog.txt b/od-win32/winuaechangelog.txt index f1c63fd6..391a8e8e 100755 --- a/od-win32/winuaechangelog.txt +++ b/od-win32/winuaechangelog.txt @@ -1,4 +1,8 @@ +Beta 9: + +- interrupt timing tweak (Gravity Force in ce-mode) + Beta 8: (RC3, really final?) - random sound automatic restart delay fixed