trap_put_byte(ctx, amigamemptr + PSSO_ModeInfo_first_union, 98);
trap_put_byte(ctx, amigamemptr + PSSO_ModeInfo_second_union, 14);
+ int freq = currprefs.gfx_apmode[GF_RTG].gfx_refreshrate;
trap_put_long(ctx, amigamemptr + PSSO_ModeInfo_PixelClock,
- width * height * (currprefs.gfx_apmode[1].gfx_refreshrate ? abs (currprefs.gfx_apmode[1].gfx_refreshrate) : default_freq));
+ width * height * (freq ? abs(freq) : default_freq));
}
struct modeids {
static int _cdecl resolution_compare (const void *a, const void *b)
{
- struct PicassoResolution *ma = (struct PicassoResolution *)a;
- struct PicassoResolution *mb = (struct PicassoResolution *)b;
+ struct PicassoResolution *ma = (struct PicassoResolution*)a;
+ struct PicassoResolution *mb = (struct PicassoResolution*)b;
if (ma->res.width < mb->res.width)
return -1;
if (ma->res.width > mb->res.width)
struct picasso96_state_struct *state = &picasso96_state[mon->monitor_id];
updatewinfsmode(mon->monitor_id, &currprefs);
+
#ifdef PICASSO96
+
+ if (currprefs.win32_rtgvblankrate == 0) {
+ currprefs.gfx_apmode[1].gfx_refreshrate = currprefs.gfx_apmode[0].gfx_refreshrate;
+ if (currprefs.gfx_apmode[0].gfx_interlaced) {
+ currprefs.gfx_apmode[1].gfx_refreshrate *= 2;
+ }
+ } else if (currprefs.win32_rtgvblankrate < 0) {
+ currprefs.gfx_apmode[1].gfx_refreshrate = 0;
+ } else {
+ currprefs.gfx_apmode[1].gfx_refreshrate = currprefs.win32_rtgvblankrate;
+ }
+
if (mon->screen_is_picasso) {
float mx = 1.0;
float my = 1.0;
mon->currentmode.current_width = (int)(state->Width * currprefs.rtg_horiz_zoom_mult * mx);
mon->currentmode.current_height = (int)(state->Height * currprefs.rtg_vert_zoom_mult * my);
currprefs.gfx_apmode[1].gfx_interlaced = false;
- if (currprefs.win32_rtgvblankrate == 0) {
- currprefs.gfx_apmode[1].gfx_refreshrate = currprefs.gfx_apmode[0].gfx_refreshrate;
- if (currprefs.gfx_apmode[0].gfx_interlaced) {
- currprefs.gfx_apmode[1].gfx_refreshrate *= 2;
- }
- } else if (currprefs.win32_rtgvblankrate < 0) {
- currprefs.gfx_apmode[1].gfx_refreshrate = 0;
- } else {
- currprefs.gfx_apmode[1].gfx_refreshrate = currprefs.win32_rtgvblankrate;
- }
} else {
#endif
mon->currentmode.current_width = currprefs.gfx_monitor[mon->monitor_id].gfx_size.width;