From: Toni Wilen Date: Fri, 13 Jun 2025 14:58:22 +0000 (+0300) Subject: HB start/end position used by (for example) genlock now gets correct values. X-Git-Url: https://git.unchartedbackwaters.co.uk/w/?a=commitdiff_plain;h=280cbf8430c833d82683bc8569f497c4c0aa01a6;p=francis%2Fwinuae.git HB start/end position used by (for example) genlock now gets correct values. --- diff --git a/drawing.cpp b/drawing.cpp index 9feca7f7..c6f8ca0d 100644 --- a/drawing.cpp +++ b/drawing.cpp @@ -418,6 +418,7 @@ static bool denise_strlong_unalign, strlong_emulation; static int denise_phbstrt, denise_phbstop, denise_phbstrt_lores, denise_phbstop_lores; static int linear_denise_vbstrt, linear_denise_vbstop; static int linear_denise_hbstrt, linear_denise_hbstop; +static int linear_denise_frame_hbstrt, linear_denise_frame_hbstop; static int denise_visible_lines, denise_visible_lines_counted; static uae_u16 hbstrt_denise_reg, hbstop_denise_reg; static uae_u16 fmode_denise, denise_bplfmode, denise_sprfmode; @@ -2382,11 +2383,8 @@ void get_mode_blanking_limits(int *phbstop, int *phbstrt, int *pvbstop, int *pvb { *pvbstop = linear_denise_vbstrt; *pvbstrt = linear_denise_vbstop; - int stop = linear_denise_hbstop; - int strt = linear_denise_hbstrt; - int len = (current_linear_hpos << 3) - (stop - strt); - *phbstop = stop; - *phbstrt = stop + len; + *phbstop = linear_denise_frame_hbstop; + *phbstrt = linear_denise_frame_hbstrt; } static void setup_brdblank(void) @@ -5742,6 +5740,11 @@ static void draw_denise_line(int gfx_ypos, enum nln_how how, uae_u32 linecnt, in ls->lol = lol; } + if (linear_denise_hbstrt >= 0 && linear_denise_hbstop >= 0 && !denise_vblank_active) { + linear_denise_frame_hbstrt = linear_denise_hbstrt & ~15; + linear_denise_frame_hbstop = linear_denise_hbstop & ~15; + } + if (refresh_indicator_buffer && buf1t) { static const int refresh_indicator_colors[] = { 0x777, 0x0f0, 0x00f, 0xff0, 0xf0f }; const int indicator_width = 16;