From: Toni Wilen Date: Sat, 24 Nov 2012 13:19:26 +0000 (+0200) Subject: 2500b27 X-Git-Tag: 2500~2 X-Git-Url: https://git.unchartedbackwaters.co.uk/w/?a=commitdiff_plain;h=c097a3a3e6ff2e8455ea984f3d5a4e946746c97c;p=francis%2Fwinuae.git 2500b27 --- diff --git a/blkdev.cpp b/blkdev.cpp index c2f61a15..9ceccee0 100644 --- a/blkdev.cpp +++ b/blkdev.cpp @@ -515,7 +515,7 @@ static void check_changes (int unitnum) int pollmode = 0; imagechangetime[unitnum] = 3 * 50; struct device_info di; - device_func[unitnum]->info (unitnum, &di, 0); + device_func[unitnum]->info (unitnum, &di, 0, -1); if (wasopen[unitnum] >= 0) wasopen[unitnum] = di.open ? 1 : 0; if (wasopen[unitnum]) { @@ -564,7 +564,7 @@ static void check_changes (int unitnum) } if (currprefs.scsi && wasopen[unitnum]) { struct device_info di; - device_func[unitnum]->info (unitnum, &di, 0); + device_func[unitnum]->info (unitnum, &di, 0, -1); int pollmode; if (gotsem) { freesem (unitnum); @@ -773,8 +773,14 @@ int sys_command_cd_read (int unitnum, uae_u8 *data, int block, int size) if (!getsem (unitnum)) return 0; if (device_func[unitnum]->read == NULL) { - uae_u8 cmd[12] = { 0xbe, 0, block >> 24, block >> 16, block >> 8, block >> 0, size >> 16, size >> 8, size >> 0, 0x10, 0, 0 }; - v = do_scsi (unitnum, cmd, sizeof cmd, data, size * 2048); + uae_u8 cmd1[12] = { 0x28, 0, block >> 24, block >> 16, block >> 8, block >> 0, 0, size >> 8, size >> 0, 0, 0, 0 }; + v = do_scsi (unitnum, cmd1, sizeof cmd1, data, size * 2048); +#if 0 + if (!v) { + uae_u8 cmd2[12] = { 0xbe, 0, block >> 24, block >> 16, block >> 8, block >> 0, size >> 16, size >> 8, size >> 0, 0x10, 0, 0 }; + v = do_scsi (unitnum, cmd2, sizeof cmd2, data, size * 2048); + } +#endif } else { v = device_func[unitnum]->read (unitnum, data, block, size); } @@ -862,7 +868,7 @@ int sys_command_ismedia (int unitnum, int quick) return 0; if (!getsem (unitnum)) return 0; - if (device_func[unitnum] == NULL) { + if (device_func[unitnum]->ismedia == NULL) { uae_u8 cmd[6] = { 0, 0, 0, 0, 0, 0 }; v = do_scsi (unitnum, cmd, sizeof cmd); } else { @@ -872,18 +878,24 @@ int sys_command_ismedia (int unitnum, int quick) return v; } -struct device_info *sys_command_info (int unitnum, struct device_info *di, int quick) +struct device_info *sys_command_info_session (int unitnum, struct device_info *di, int quick, int session) { if (failunit (unitnum)) return NULL; if (!getsem (unitnum)) return 0; - struct device_info *di2 = device_func[unitnum]->info (unitnum, di, quick); + if (device_func[unitnum]->info == NULL) + return 0; + struct device_info *di2 = device_func[unitnum]->info (unitnum, di, quick, -1); if (di2 && delayed[unitnum]) di2->media_inserted = 0; freesem (unitnum); return di2; } +struct device_info *sys_command_info (int unitnum, struct device_info *di, int quick) +{ + return sys_command_info_session (unitnum, di, quick, -1); +} #define MODE_SELECT_6 0x15 #define MODE_SENSE_6 0x1a diff --git a/blkdev_cdimage.cpp b/blkdev_cdimage.cpp index bb9f096f..5ab22361 100644 --- a/blkdev_cdimage.cpp +++ b/blkdev_cdimage.cpp @@ -841,6 +841,7 @@ static int command_toc (int unitnum, struct cd_toc_head *th) th->last_track = cdu->tracks; th->points = cdu->tracks + 3; th->tracks = cdu->tracks; + th->firstaddress = 0; th->lastaddress = cdu->toc[cdu->tracks].address; toc->adr = 1; @@ -1561,7 +1562,7 @@ static int ismedia (int unitnum, int quick) return cdu->tracks > 0 ? 1 : 0; } -static struct device_info *info_device (int unitnum, struct device_info *di, int quick) +static struct device_info *info_device (int unitnum, struct device_info *di, int quick, int session) { struct cdunit *cdu = &cdunits[unitnum]; memset (di, 0, sizeof (struct device_info)); diff --git a/include/blkdev.h b/include/blkdev.h index 9c28cd6c..52f13e4e 100644 --- a/include/blkdev.h +++ b/include/blkdev.h @@ -44,6 +44,7 @@ struct cd_toc_head { int first_track, first_track_offset; int last_track, last_track_offset; + int firstaddress; // LSN int lastaddress; // LSN int tracks; int points; @@ -102,7 +103,7 @@ typedef int (*open_bus_func)(int flags); typedef void (*close_bus_func)(void); typedef int (*open_device_func)(int, const TCHAR*, int); typedef void (*close_device_func)(int); -typedef struct device_info* (*info_device_func)(int, struct device_info*, int); +typedef struct device_info* (*info_device_func)(int, struct device_info*, int, int); typedef uae_u8* (*execscsicmd_out_func)(int, uae_u8*, int); typedef uae_u8* (*execscsicmd_in_func)(int, uae_u8*, int, int*); typedef int (*execscsicmd_direct_func)(int, struct amigascsi*); @@ -172,6 +173,7 @@ extern int sys_command_write (int unitnum, uae_u8 *data, int block, int size); extern int sys_command_scsi_direct_native (int unitnum, struct amigascsi *as); extern int sys_command_scsi_direct (int unitnum, uaecptr request); extern int sys_command_ismedia (int unitnum, int quick); +extern struct device_info *sys_command_info_session (int unitnum, struct device_info *di, int, int); extern void scsi_atapi_fixup_pre (uae_u8 *scsi_cmd, int *len, uae_u8 **data, int *datalen, int *parm); extern void scsi_atapi_fixup_post (uae_u8 *scsi_cmd, int len, uae_u8 *olddata, uae_u8 *data, int *datalen, int parm); diff --git a/inputdevice.cpp b/inputdevice.cpp index d7cf61c9..6a94a5bf 100644 --- a/inputdevice.cpp +++ b/inputdevice.cpp @@ -5131,6 +5131,9 @@ void inputdevice_devicechange (struct uae_prefs *prefs) inputdevice_copyconfig (&changed_prefs, &currprefs); if (acc) inputdevice_acquire (TRUE); +#ifdef RETROPLATFORM + rp_enumdevices (); +#endif config_changed = 1; } diff --git a/isofs.cpp b/isofs.cpp index 7478ee06..0d0c625a 100644 --- a/isofs.cpp +++ b/isofs.cpp @@ -2,7 +2,7 @@ /* * UAE - The Un*x Amiga Emulator * -* Linux isofs/UAE filesystem wrapperr +* Linux isofs/UAE filesystem wrapper * * Copyright 2012 Toni Wilen * @@ -419,7 +419,6 @@ static int iso_ltime(char *p) return make_date(year - 1970, month, day, hour, minute, second, 0); } - static int isofs_read_level3_size(struct inode *inode) { unsigned long bufsize = ISOFS_BUFFER_SIZE(inode); @@ -1501,10 +1500,17 @@ static TCHAR *get_joliet_filename(struct iso_directory_record * de, struct inode utf8 = ISOFS_SB(inode->i_sb)->s_utf8; //nls = ISOFS_SB(inode->i_sb)->s_nls_iocharset; - len = de->name_len[0] / 2; if (utf8) { - ; + /* probably never used */ + len = de->name_len[0]; + uae_char *o = xmalloc (uae_char, len + 1); + for (int i = 0; i < len; i++) + o[i] = de->name[i]; + o[len] = 0; + out = utf8u (o); + xfree (o); } else { + len = de->name_len[0] / 2; out = xmalloc (TCHAR, len + 1); for (int i = 0; i < len; i++) out[i] = isonum_722 (de->name + i * 2); @@ -1696,6 +1702,12 @@ static int isofs_fill_super(struct super_block *s, void *data, int silent, uae_u sbi->s_high_sierra = 0; /* default is iso9660 */ vol_desc_start = 0; +#if 0 + struct device_info di; + if (sys_command_info (s->unitnum, &di, true)) { + vol_desc_start = di.toc.firstaddress; + } +#endif for (iso_blknum = vol_desc_start+16; iso_blknum < vol_desc_start+100; iso_blknum++) { struct hs_volume_descriptor *hdp; diff --git a/od-win32/blkdev_win32_ioctl.cpp b/od-win32/blkdev_win32_ioctl.cpp index f2cb26e8..8effa6dc 100644 --- a/od-win32/blkdev_win32_ioctl.cpp +++ b/od-win32/blkdev_win32_ioctl.cpp @@ -1128,6 +1128,7 @@ static int ioctl_command_toc2 (int unitnum, struct cd_toc_head *tocout, bool hid th->last_track = toc->LastTrack; th->tracks = th->last_track - th->first_track + 1; th->points = th->tracks + 3; + th->firstaddress = 0; th->lastaddress = msf2lsn ((toc->TrackData[toc->LastTrack].Address[1] << 16) | (toc->TrackData[toc->LastTrack].Address[2] << 8) | (toc->TrackData[toc->LastTrack].Address[3] << 0)); @@ -1454,7 +1455,7 @@ static int ioctl_ismedia (int unitnum, int quick) return ismedia (ciw, unitnum); } -static struct device_info *info_device (int unitnum, struct device_info *di, int quick) +static struct device_info *info_device (int unitnum, struct device_info *di, int quick, int session) { struct dev_info_ioctl *ciw = unitcheck (unitnum); if (!ciw) diff --git a/od-win32/blkdev_win32_spti.cpp b/od-win32/blkdev_win32_spti.cpp index c5f42797..074819d2 100644 --- a/od-win32/blkdev_win32_spti.cpp +++ b/od-win32/blkdev_win32_spti.cpp @@ -137,7 +137,7 @@ static int doscsi (struct dev_info_spti *di, int unitnum, SCSI_PASS_THROUGH_DIRE if (log_scsi) scsi_log_after (swb->spt.DataIn == SCSI_IOCTL_DATA_IN ? (uae_u8*)swb->spt.DataBuffer : NULL, swb->spt.DataTransferLength, swb->SenseBuf, swb->spt.SenseInfoLength); - if (swb->spt.SenseInfoLength > 0 && (swb->SenseBuf[0] == 0 || swb->SenseBuf[0] == 1)) + if (swb->spt.SenseInfoLength > 0 && (swb->SenseBuf[2] == 0 || swb->SenseBuf[2] == 1)) swb->spt.SenseInfoLength = 0; /* 0 and 1 = success, not error.. */ if (swb->spt.SenseInfoLength > 0) return 0; @@ -640,7 +640,7 @@ static int adddrive (const TCHAR *drvpath, int bus, int pathid, int targetid, in return 1; } -static struct device_info *info_device (int unitnum, struct device_info *di, int quick) +static struct device_info *info_device (int unitnum, struct device_info *di, int quick, int session) { struct dev_info_spti *dispti = unitcheck (unitnum); if (!dispti) diff --git a/od-win32/cloanto/RetroPlatformIPC.h b/od-win32/cloanto/RetroPlatformIPC.h index 0fd25571..b33d1410 100644 --- a/od-win32/cloanto/RetroPlatformIPC.h +++ b/od-win32/cloanto/RetroPlatformIPC.h @@ -24,6 +24,9 @@ #define RPIPC_HostWndClass "RetroPlatformHost%s" #define RPIPC_GuestWndClass "RetroPlatformGuest%d" +// Legacy Compatibility (pre-3.0) +#define RP_NO_LEGACY // We don't need legacy #defines + // **************************************************************************** // Guest-to-Host Messages @@ -109,7 +112,8 @@ #define RP_FEATURE_INPUTDEVICE_TABLET 0x00400000 // supports emulation of pen tablet #define RP_FEATURE_TURBO_FLOPPY 0x00800000 // turbo floppy functionality is available (see RP_IPC_TO_GUEST_TURBO message) #define RP_FEATURE_TURBO_TAPE 0x01000000 // turbo tape functionality is available (see RP_IPC_TO_GUEST_TURBO message) - +#define RP_FEATURE_MEMORY_BASIC 0x02000000 // Memory I/O basic features: Read, Write +#define RP_FEATURE_MEMORY_ADVANCED 0x04000000 // Memory I/O advanced features: Watch, Find, Alert, Freeze, Lock, Unlock, Off (must set both flags if full set is supported!) typedef struct RPScreenMode { @@ -190,7 +194,7 @@ typedef struct RPScreenMode // // Full-window Examples // -// Example 1: No RP_SCREENMODE_SCALING_SUBPIXEL, no RP_SCREENMODE_SCALING_STRETCH: maximum integer scaling (can have black bars on up to four sides) +// Example 1: No RP_SCREENMODE_SCALING_SUBPIXEL, no RP_SCREENMODE_SCALING_STRETCH: maximum integer scaling (can have black bars on up to four sides), e.g. 1X, 2X, 3X, etc. // // Example 2: RP_SCREENMODE_SCALING_SUBPIXEL, no RP_SCREENMODE_SCALING_STRETCH: maximum "soft" scaling keeping ratio (can have black bars on two sides) // @@ -309,7 +313,8 @@ typedef struct RPDeviceContent #define RP_HOSTINPUT_ARCADE_LEFT 6 // [LEGACY] Left part of arcade dual joystick input device ("player 1") #define RP_HOSTINPUT_ARCADE_RIGHT 7 // [LEGACY] Right part of arcade dual joystick input device ("player 2") #define RP_HOSTINPUT_KEYBOARD 8 // Keyboard Layout (e.g. "KeyboardJoystick Left=0x4B Right=0x4D Up=0x48 Down=0x50 Fire=0x4C Autofire=0x38 Fire2=0x52 Rewind=0xB5 Play=0x37 FastForward=0x4A Green=0x47 Yellow=0x49 Red=0x4F Blue=0x51" set in szContent); introduced in RP API 3.3 to replace other keyboard layout modes -#define RP_HOSTINPUT_COUNT 9 // total number of device types +#define RP_HOSTINPUT_END 9 // "End of device enumeration" (dummy device used to terminate an input device set that began with the first input device) +#define RP_HOSTINPUT_COUNT 10 // total number of device types // Host Input Device Flags #define RP_HOSTINPUTFLAGS_MOUSE_RAW 0x00000000 // Individual raw mouse device with no acceleration (multi-mouse warning: RAW and SMART devices cannot be used simultaneously) @@ -390,8 +395,9 @@ typedef struct RPDeviceContent #define RP_HOSTVERSION_BUILD(ver) ((ver) & 0x3FF) #define RP_MAKE_HOSTVERSION(major,minor,build) ((LPARAM) (((LPARAM)((major) & 0xFFF)<<20) | ((LPARAM)((minor) & 0x3FF)<<10) | ((LPARAM)((build) & 0x3FF)))) -#if 0 + // Legacy Compatibility (pre-3.0) +#ifndef RP_NO_LEGACY #define RP_IPC_TO_HOST_DEVICECONTENT_LEGACY (WM_APP + 16) #define RP_IPC_TO_GUEST_DEVICECONTENT_LEGACY (WM_APP + 205) #define RPLATFORM_API_VER RETROPLATFORM_API_VER @@ -479,6 +485,7 @@ typedef struct RPDeviceContent_Legacy #define RPIPCHM_GUESTAPIVERSION RP_IPC_TO_GUEST_GUESTAPIVERSION #define RPIPCHM_DEVICECONTENT RP_IPC_TO_GUEST_DEVICECONTENT #define RP_FEATURE_TURBO RP_FEATURE_TURBO_CPU -// End of Legacy Compatibility #endif +// End of Legacy Compatibility + #endif // __CLOANTO_RETROPLATFORMIPC_H__ diff --git a/od-win32/rp.cpp b/od-win32/rp.cpp index da4a566f..6a5347d3 100644 --- a/od-win32/rp.cpp +++ b/od-win32/rp.cpp @@ -557,32 +557,36 @@ static void get_screenmode (struct RPScreenMode *sm, struct uae_prefs *p) hres = p->gfx_resolution; vres = p->gfx_vresolution; - hmult = p->gfx_filter_horiz_zoom_mult > 0 ? 1000 * 256 / p->gfx_filter_horiz_zoom_mult : 256; - vmult = p->gfx_filter_vert_zoom_mult > 0 ? 1000 * 256 / p->gfx_filter_vert_zoom_mult : 256; sm->hGuestWindow = guestwindow; m = RP_SCREENMODE_SCALE_1X; cf = 0; + half = false; + rtg = WIN32GFX_IsPicassoScreen () != 0; - if (WIN32GFX_IsPicassoScreen ()) { + if (rtg) { + + hmult = p->rtg_horiz_zoom_mult; + vmult = p->rtg_vert_zoom_mult; - rtg = true; full = p->gfx_apmode[1].gfx_fullscreen; sm->lClipTop = -1; sm->lClipLeft = -1; sm->lClipWidth = -1;//picasso96_state.Width; sm->lClipHeight = -1;//picasso96_state.Height; - if (p->rtg_horiz_zoom_mult < 333 || p->rtg_vert_zoom_mult < 333) + if (hmult < 333 || vmult < 333) m |= RP_SCREENMODE_SCALE_4X; - else if (p->rtg_horiz_zoom_mult < 500 || p->rtg_vert_zoom_mult < 500) + else if (hmult < 500 || vmult < 500) m |= RP_SCREENMODE_SCALE_3X; - else if (p->rtg_horiz_zoom_mult < 1000 || p->rtg_vert_zoom_mult < 1000) + else if (hmult < 1000 || vmult < 1000) m |= RP_SCREENMODE_SCALE_2X; } else { - rtg = false; + hmult = p->gfx_filter_horiz_zoom_mult > 0 ? 1000 * 256 / p->gfx_filter_horiz_zoom_mult : 256; + vmult = p->gfx_filter_vert_zoom_mult > 0 ? 1000 * 256 / p->gfx_filter_vert_zoom_mult : 256; + full = p->gfx_apmode[0].gfx_fullscreen; totalhdbl = hres; @@ -606,13 +610,6 @@ static void get_screenmode (struct RPScreenMode *sm, struct uae_prefs *p) m = half ? RP_SCREENMODE_SCALE_3X : RP_SCREENMODE_SCALE_4X; } - if (log_rp & 2) - write_log (_T("GET_RPSM: hres=%d (%d) vres=%d (%d) full=%d xcpos=%d ycpos=%d w=%d h=%d vm=%d hm=%d half=%d\n"), - totalhdbl, hres, totalvdbl, vres, full, - p->gfx_xcenter_pos, p->gfx_ycenter_pos, - p->gfx_size_win.width, p->gfx_size_win.height, - hmult, vmult, half); - sm->lClipLeft = p->gfx_xcenter_pos < 0 ? -1 : p->gfx_xcenter_pos; sm->lClipTop = p->gfx_ycenter_pos < 0 ? -1 : p->gfx_ycenter_pos; sm->lClipWidth = p->gfx_xcenter_size <= 0 ? -1 : p->gfx_xcenter_size; @@ -647,10 +644,17 @@ static void get_screenmode (struct RPScreenMode *sm, struct uae_prefs *p) } sm->dwClipFlags = cf; - if (log_rp & 2) + if (log_rp & 2) { + write_log (_T("%sGET_RPSM: hres=%d (%d) vres=%d (%d) full=%d xcpos=%d ycpos=%d w=%d h=%d vm=%d hm=%d half=%d\n"), + rtg ? _T("RTG ") : _T(""), + totalhdbl, hres, totalvdbl, vres, full, + p->gfx_xcenter_pos, p->gfx_ycenter_pos, + p->gfx_size_win.width, p->gfx_size_win.height, + hmult, vmult, half); write_log (_T("GET_RPSM: %08X %dx%d %dx%d hres=%d (%d) vres=%d (%d) disp=%d fs=%d\n"), sm->dwScreenMode, sm->lClipLeft, sm->lClipTop, sm->lClipWidth, sm->lClipHeight, totalhdbl, hres, totalvdbl, vres, p->gfx_apmode[APMODE_NATIVE].gfx_display, full); + } } static void set_screenmode (struct RPScreenMode *sm, struct uae_prefs *p) @@ -787,19 +791,25 @@ static void set_screenmode (struct RPScreenMode *sm, struct uae_prefs *p) if (WIN32GFX_IsPicassoScreen ()) { int m = 1; - p->win32_rtgscaleifsmall = fs == 2 || (smm >= RP_SCREENMODE_SCALE_2X && smm <= RP_SCREENMODE_SCALE_4X); - p->rtg_horiz_zoom_mult = p->rtg_vert_zoom_mult = 1000; - if (smm == RP_SCREENMODE_SCALE_2X) { - m = 2; - } else if (smm == RP_SCREENMODE_SCALE_3X) { - m = 3; - } else if (smm == RP_SCREENMODE_SCALE_4X) { - m = 4; + if (fs == 2) { + p->win32_rtgscaleifsmall = true; + } else { + p->win32_rtgscaleifsmall = false; + if (smm == RP_SCREENMODE_SCALE_2X) { + m = 2; + } else if (smm == RP_SCREENMODE_SCALE_3X) { + m = 3; + } else if (smm == RP_SCREENMODE_SCALE_4X) { + m = 4; + } } p->rtg_horiz_zoom_mult = p->rtg_vert_zoom_mult = 1000 / m; p->gfx_size_win.width = picasso_vidinfo.width * m; p->gfx_size_win.height = picasso_vidinfo.height * m; + hmult = m; + vmult = m; + } else { if (stretch) { hmult = vmult = 0; @@ -872,19 +882,24 @@ static void set_screenmode (struct RPScreenMode *sm, struct uae_prefs *p) } } - if (log_rp & 2) + if (log_rp & 2) { write_log(_T("%dx%d %dx%d %dx%d %08x HM=%.1f VM=%.1f\n"), sm->lClipLeft, sm->lClipTop, sm->lClipWidth, sm->lClipHeight, sm->lTargetWidth, sm->lTargetHeight, sm->dwClipFlags, hmult, vmult); - - if (log_rp & 2) - write_log (_T("WW=%d WH=%d FW=%d FH=%d HM=%d VM=%d XP=%d YP=%d XS=%d YS=%d AS=%d AR=%d,%d\n"), - p->gfx_size_win.width, p->gfx_size_win.height, - p->gfx_size_fs.width, p->gfx_size_fs.height, - p->gfx_filter_horiz_zoom_mult, p->gfx_filter_vert_zoom_mult, - p->gfx_xcenter_pos, p->gfx_ycenter_pos, - p->gfx_xcenter_size, p->gfx_ycenter_size, - p->gfx_filter_autoscale, p->gfx_filter_aspect, p->gfx_filter_keep_aspect); - + if (WIN32GFX_IsPicassoScreen ()) { + write_log (_T("RTG WW=%d WH=%d FW=%d FH=%d HM=%d VM=%d\n"), + p->gfx_size_win.width, p->gfx_size_win.height, + p->gfx_size_fs.width, p->gfx_size_fs.height, + p->rtg_horiz_zoom_mult, p->rtg_vert_zoom_mult); + } else { + write_log (_T("WW=%d WH=%d FW=%d FH=%d HM=%d VM=%d XP=%d YP=%d XS=%d YS=%d AS=%d AR=%d,%d\n"), + p->gfx_size_win.width, p->gfx_size_win.height, + p->gfx_size_fs.width, p->gfx_size_fs.height, + p->gfx_filter_horiz_zoom_mult, p->gfx_filter_vert_zoom_mult, + p->gfx_xcenter_pos, p->gfx_ycenter_pos, + p->gfx_xcenter_size, p->gfx_ycenter_size, + p->gfx_filter_autoscale, p->gfx_filter_aspect, p->gfx_filter_keep_aspect); + } + } updatewinfsmode (p); hwndset = 0; @@ -1164,7 +1179,7 @@ static void sendenum (void) desc.dwInputDeviceFeatures = RP_FEATURE_INPUTDEVICE_JOYSTICK; if (cnt == 0) desc.dwInputDeviceFeatures |= RP_FEATURE_INPUTDEVICE_JOYPAD; - if (log_rp & 1) + if (log_rp & 2) write_log(_T("Enum%d: '%s' '%s'\n"), cnt, desc.szHostInputName, desc.szHostInputID); RPSendMessagex (RP_IPC_TO_HOST_INPUTDEVICE, 0, 0, &desc, sizeof desc, &guestinfo, NULL); cnt++; @@ -1181,11 +1196,25 @@ static void sendenum (void) RPSendMessagex (RP_IPC_TO_HOST_INPUTDEVICE, 0, 0, &desc, sizeof desc, &guestinfo, NULL); cnt = 0; while ((cnt = rp_input_enum (&desc, cnt)) >= 0) { - if (log_rp & 1) + if (log_rp & 2) write_log(_T("Enum%d: '%s' '%s' (%x/%x)\n"), cnt, desc.szHostInputName, desc.szHostInputID, desc.dwHostInputVendorID, desc.dwHostInputProductID); RPSendMessagex (RP_IPC_TO_HOST_INPUTDEVICE, 0, 0, &desc, sizeof desc, &guestinfo, NULL); } + memset (&desc, 0, sizeof desc); + desc.dwHostInputType = RP_HOSTINPUT_END; + RPSendMessagex (RP_IPC_TO_HOST_INPUTDEVICE, 0, 0, &desc, sizeof desc, &guestinfo, NULL); +} + +void rp_enumdevices (void) +{ + if (!cando ()) + return; + sendenum (); + rp_input_change (0); + rp_input_change (1); + rp_input_change (2); + rp_input_change (3); } static void sendfeatures (void) @@ -1208,6 +1237,7 @@ static void sendfeatures (void) feat |= RP_FEATURE_INPUTDEVICE_JOYPAD; feat |= RP_FEATURE_INPUTDEVICE_ANALOGSTICK; feat |= RP_FEATURE_INPUTDEVICE_LIGHTPEN; + write_log (_T("RP_IPC_TO_HOST_FEATURES=%x %d\n"), feat, WIN32GFX_IsPicassoScreen()); RPSendMessagex (RP_IPC_TO_HOST_FEATURES, feat, 0, NULL, 0, &guestinfo, NULL); } diff --git a/od-win32/rp.h b/od-win32/rp.h index fe356a75..a148ce3b 100644 --- a/od-win32/rp.h +++ b/od-win32/rp.h @@ -40,3 +40,5 @@ extern void rp_cd_activity (int, int); void rp_floppy_device_enable (int num, bool enabled); void rp_hd_device_enable (int num, bool enabled); void rp_cd_device_enable (int num, bool enabled); +void rp_enumdevices (void); + diff --git a/od-win32/win32.cpp b/od-win32/win32.cpp index 1e9aae6c..1df47baf 100644 --- a/od-win32/win32.cpp +++ b/od-win32/win32.cpp @@ -592,7 +592,7 @@ void updatemouseclip (void) { if (showcursor) { ClipCursor (&amigawin_rect); - //write_log (_T("CLIP %dx%d %dx%d\n"), amigawin_rect.left, amigawin_rect.top, amigawin_rect.right, amigawin_rect.bottom); + write_log (_T("CLIP %dx%d %dx%d\n"), amigawin_rect.left, amigawin_rect.top, amigawin_rect.right, amigawin_rect.bottom); } } @@ -666,6 +666,7 @@ static void setmouseactive2 (int active, bool allowpause) if (!showcursor) { ShowCursor (FALSE); SetCapture (hAmigaWnd); + GetWindowRect (hAmigaWnd, &amigawin_rect); updatemouseclip (); } showcursor = 1; diff --git a/od-win32/win32.h b/od-win32/win32.h index fdae29d3..4d4e264e 100644 --- a/od-win32/win32.h +++ b/od-win32/win32.h @@ -19,9 +19,9 @@ #define LANG_DLL 1 //#define WINUAEBETA _T("") -#define WINUAEBETA _T("26") -#define WINUAEDATE MAKEBD(2012, 11, 18) -#define WINUAEEXTRA _T(" RC2") +#define WINUAEBETA _T("27") +#define WINUAEDATE MAKEBD(2012, 11, 24) +#define WINUAEEXTRA _T(" RC3") //#define WINUAEEXTRA _T("AmiKit Preview") #define WINUAEREV _T("") diff --git a/od-win32/win32gfx.cpp b/od-win32/win32gfx.cpp index 3e51f371..654012ad 100644 --- a/od-win32/win32gfx.cpp +++ b/od-win32/win32gfx.cpp @@ -1613,6 +1613,9 @@ int check_prefs_changed_gfx (void) c |= currprefs.gfx_filter_gamma != changed_prefs.gfx_filter_gamma ? (1|8) : 0; //c |= currprefs.gfx_filter_ != changed_prefs.gfx_filter_ ? (1|8) : 0; + c |= currprefs.rtg_horiz_zoom_mult != changed_prefs.rtg_horiz_zoom_mult ? (1|8) : 0; + c |= currprefs.rtg_vert_zoom_mult != changed_prefs.rtg_vert_zoom_mult ? (1|8) : 0; + c |= currprefs.gfx_luminance != changed_prefs.gfx_luminance ? (1 | 256) : 0; c |= currprefs.gfx_contrast != changed_prefs.gfx_contrast ? (1 | 256) : 0; c |= currprefs.gfx_gamma != changed_prefs.gfx_gamma ? (1 | 256) : 0; @@ -1688,6 +1691,9 @@ int check_prefs_changed_gfx (void) currprefs.gfx_filter_autoscale = changed_prefs.gfx_filter_autoscale; //currprefs.gfx_filter_ = changed_prefs.gfx_filter_; + currprefs.rtg_horiz_zoom_mult = changed_prefs.rtg_horiz_zoom_mult; + currprefs.rtg_vert_zoom_mult = changed_prefs.rtg_vert_zoom_mult; + currprefs.gfx_luminance = changed_prefs.gfx_luminance; currprefs.gfx_contrast = changed_prefs.gfx_contrast; currprefs.gfx_gamma = changed_prefs.gfx_gamma; @@ -3779,11 +3785,12 @@ static BOOL doInit (void) updatemodes (); } - if (currentmode->current_width > GetSystemMetrics(SM_CXVIRTUALSCREEN) || - currentmode->current_height > GetSystemMetrics(SM_CYVIRTUALSCREEN)) { + if (!rp_isactive () && (currentmode->current_width > GetSystemMetrics(SM_CXVIRTUALSCREEN) || + currentmode->current_height > GetSystemMetrics(SM_CYVIRTUALSCREEN))) { if (!console_logging) fs_warning = IDS_UNSUPPORTEDSCREENMODE_3; } + if (fs_warning >= 0 && isfullscreen () <= 0) { TCHAR szMessage[MAX_DPATH], szMessage2[MAX_DPATH]; WIN32GUI_LoadUIString(IDS_UNSUPPORTEDSCREENMODE, szMessage, MAX_DPATH); diff --git a/od-win32/winuae_msvc10/winuae_msvc.vcxproj b/od-win32/winuae_msvc10/winuae_msvc.vcxproj index 3e5ef64a..cab4274c 100644 --- a/od-win32/winuae_msvc10/winuae_msvc.vcxproj +++ b/od-win32/winuae_msvc10/winuae_msvc.vcxproj @@ -327,6 +327,8 @@ MachineX86 + + ../resources/winuae.exe.manifest diff --git a/od-win32/winuaechangelog.txt b/od-win32/winuaechangelog.txt index 6c9ecd5f..a98ae691 100644 --- a/od-win32/winuaechangelog.txt +++ b/od-win32/winuaechangelog.txt @@ -1,6 +1,13 @@ - restore only single input target to default. +Beta 27 RC3: + +- Modulated volume value wasn't range checked, caused noise if volume word was not between 0 to 63. (Platou title music) +- Fixed SPTI mode CDFS crash. +- CDFS didn't correctly remove hidden trailing ;1's in some Joliet CD filenames. +- SPTI standard CD access: Use READ (10), not READ CD when requesting standard 2048 byte user sectors, not all BD/DVD drives support READ CD when reading DVDs. + Beta 26 RC2: - RTG aspect ratio setting was loaded to wrong variable from config file (filter panel aspect ratio, not RTG)