From c1b3923121f18289fc96b1da0874a373a40d9e63 Mon Sep 17 00:00:00 2001 From: Toni Wilen Date: Tue, 8 Apr 2025 18:49:27 +0300 Subject: [PATCH] Chipset updates (TV overscan), hires/shres HAM/EHB etc. --- custom.cpp | 145 ++++---- drawing.cpp | 650 ++++++++------------------------- genlinetoscr.cpp | 2 +- include/drawing.h | 38 +- linetoscr_aga_fast.cpp | 160 ++++---- linetoscr_aga_genlock_fast.cpp | 160 ++++---- linetoscr_ecs_fast.cpp | 160 ++++---- linetoscr_ecs_genlock_fast.cpp | 160 ++++---- 8 files changed, 552 insertions(+), 923 deletions(-) diff --git a/custom.cpp b/custom.cpp index 49c15651..2a3d96dd 100644 --- a/custom.cpp +++ b/custom.cpp @@ -115,19 +115,19 @@ static uae_u16 pipelined_write_value; static struct rgabuf rga_pipe[RGA_SLOT_TOTAL + 1]; struct denise_rga rga_denise[DENISE_RGA_SLOT_TOTAL]; static struct linestate *current_line_state; -static struct linestate lines[MAX_SCANDOUBLED_LINES][2]; +static struct linestate lines[MAX_SCANDOUBLED_LINES + 1][2]; static int rga_denise_cycle, rga_denise_cycle_start, rga_denise_cycle_count; static int rga_denise_cycle_line = 1; static struct pipeline_reg preg; static struct pipeline_func pfunc[MAX_PIPELINE_REG]; -static uae_u16 prev_strobe; +static uae_u16 prev_strobe, strobe_fast; static uae_u32 custom_state_flags; static int not_safe_mode; static bool dmal_next; static int fast_lines_cnt; static bool lineoptimizations_draw_always; -static uae_u32 scandoubled_bpl_ptr[MAX_SCANDOUBLED_LINES][2][MAX_PLANES]; +static uae_u32 scandoubled_bpl_ptr[MAX_SCANDOUBLED_LINES + 1][2][MAX_PLANES]; static bool scandoubled_bpl_ena[MAX_SCANDOUBLED_LINES + 1]; static evt_t blitter_dma_change_cycle, copper_dma_change_cycle, sprite_dma_change_cycle_on, sprite_dma_change_cycle_off; @@ -393,13 +393,13 @@ static int linear_display_vpos; int current_linear_vpos, current_linear_hpos; static int current_linear_vpos_temp, current_linear_hpos_temp; static int current_linear_temp_change; +static bool display_redraw; static int display_hstart_cyclewait, display_hstart_cyclewait_cnt, display_hstart_cyclewait_end; static int display_hstart_cyclewait_skip, display_hstart_cyclewait_skip2; static bool display_hstart_cyclewait_start; static int agnus_trigger_cck; static int linear_vpos_changes; static enum nln_how nextline_how; -static int lof_changed = 0, lof_changing = 0; static bool prevlofs[3]; static bool vsync_rendered, frame_rendered, frame_shown; static frame_time_t vsynctimeperline; @@ -1593,7 +1593,6 @@ void compute_framesync(void) changed_prefs.chipset_refreshrate = currprefs.chipset_refreshrate = vblank_hz; } stored_chipset_refresh = cr; - lof_changing = 0; vb->inxoffset = -1; vb->inyoffset = -1; updateextblk(); @@ -2456,7 +2455,6 @@ static void VPOSW(uae_u16 v) #if 1 if (lof_store != ((v & 0x8000) ? 1 : 0)) { lof_store = (v & 0x8000) ? 1 : 0; - lof_changing = lof_store ? 1 : -1; } #endif // LOL is always reset when VPOSW is written to. @@ -4899,7 +4897,7 @@ static void vsync_handler_render(void) if (!vsync_rendered) { frame_time_t start, end; start = read_processor_time(); - vsync_handle_redraw(lof_store, lof_changed, bplcon0, bplcon3, isvsync_chipset() >= 0, initial_frame); + vsync_handle_redraw(lof_store, bplcon0, bplcon3, isvsync_chipset() >= 0, initial_frame); initial_frame = false; vsync_rendered = true; end = read_processor_time(); @@ -4967,6 +4965,13 @@ static void vsync_display_render(void) { if (!vsync_display_rendered) { vsyncmintimepre = read_processor_time(); + + if (!custom_disabled) { + draw_denise_vsync_queue(display_redraw); + display_redraw = false; + } + draw_denise_line_queue_flush(); + if (has_draw_denise()) { end_draw_denise(); } @@ -4986,7 +4991,8 @@ static void vsync_check_vsyncmode(void) if (linear_hpos_prev[2] == linear_hpos_prev[0] || linear_hpos_prev[1] == linear_hpos_prev[0]) { int hp = linear_hpos_prev[0] > linear_hpos_prev[2] ? linear_hpos_prev[0] : linear_hpos_prev[2]; int vp = linear_vpos_prev[0] > linear_vpos_prev[2] ? linear_vpos_prev[0] : linear_vpos_prev[2]; - if (abs(hp - current_linear_hpos_temp) > 1 || abs(vp - current_linear_vpos_temp) > 1) { + int ydiff = (prevlofs[0] != prevlofs[1] && prevlofs[0] == prevlofs[2]) ? 2 : 1; + if (abs(hp - current_linear_hpos_temp) >= 2 || abs(vp - current_linear_vpos_temp) >= ydiff) { current_linear_hpos_temp = hp; current_linear_vpos_temp = vp; current_linear_temp_change = 2; @@ -5006,6 +5012,7 @@ static void vsync_check_vsyncmode(void) init_beamcon0(); compute_framesync(); devices_syncchange(); + display_redraw = true; } } } @@ -5076,6 +5083,7 @@ static void check_interlace(void) interlace_seen = is; init_hz(); changed = true; + display_redraw = true; } else if (nis) { interlace_seen = 0; init_hz(); @@ -6416,7 +6424,6 @@ static void hsync_handler(bool vs) } if (vpos == vsync_startline + 1 && !maxvpos_display_vsync_next) { inputdevice_read_msg(true); - draw_denise_line_queue_flush(); vsync_display_render(); vsync_display_rendered = false; if (currprefs.cs_hvcsync == 0) { @@ -6753,7 +6760,6 @@ void custom_reset(bool hardreset, bool keyboardreset) check_harddis(); init_hz_reset(); - lof_changing = 0; audio_reset(); cop_state.strobe_next = COP_stop; @@ -7083,7 +7089,11 @@ writeonly: if (cycs - CYCLE_UNIT == last_rga_cycle) { v = regs.chipset_latch_rw; } else { - v = 0xffff; + if (aga_mode) { + v = regs.chipset_latch_rw >> ((addr & 2) ? 0 : 16); + } else { + v = 0xffff; + } } #if 0 @@ -10421,18 +10431,12 @@ static int getlinetype(void) { int type = 0; - if (get_strobe_reg(0) != 0x3c) { + if (strobe_fast != 0x3c) { type = LINETYPE_BLANK; - } else { - if (vdiwstate == diw_states::DIW_waiting_start || GET_PLANES(bplcon0) == 0 || !dmaen(DMA_BITPLANE)) { - if ((bplcon0 & 1) && (bplcon3 & 0x20)) { - type = LINETYPE_BLANK; - } else { - type = LINETYPE_BORDER; - } - } else if (ddfstop > ddfstrt && ddfstrt >= 0x14 && GET_RES_AGNUS(bplcon0) == GET_RES_DENISE(bplcon0) && dmaen(DMA_BITPLANE)) { - type = LINETYPE_BPL; - } + } else if (vdiwstate == diw_states::DIW_waiting_start || GET_PLANES(bplcon0) == 0 || !dmaen(DMA_BITPLANE)) { + type = LINETYPE_BORDER; + } else if (ddfstop > ddfstrt && ddfstrt >= 0x14 && GET_RES_AGNUS(bplcon0) == GET_RES_DENISE(bplcon0) && dmaen(DMA_BITPLANE)) { + type = LINETYPE_BPL; } return type; } @@ -10519,7 +10523,7 @@ static bool draw_border_fast(struct linestate *l, int ldv) if (l->hbstrt_offset < 0 || l->hbstop_offset < 0) { return false; } - l->color0 = aga_mode ? agnus_colors.color_regs_aga[0] : agnus_colors.color_regs_ecs[0]; + l->color0 = ((bplcon0 & 1) && (bplcon3 & 0x20)) ? 0 : (aga_mode ? agnus_colors.color_regs_aga[0] : agnus_colors.color_regs_ecs[0]); int dvp = calculate_linetype(ldv); draw_denise_border_line_fast_queue(dvp, nextline_how, l); return true; @@ -10595,23 +10599,24 @@ static bool draw_always(void) return false; } - static void resetlinestate(void) { - if (linear_vpos >= MAX_SCANDOUBLED_LINES) { + int lvpos = linear_vpos + 1; + if (lvpos >= MAX_SCANDOUBLED_LINES) { return; } - struct linestate *l = &lines[linear_vpos][lof_display]; + struct linestate *l = &lines[lvpos][lof_display]; l->type = 0; l->cnt = displayresetcnt - 1; } static void storelinestate(void) { - if (linear_vpos >= MAX_SCANDOUBLED_LINES) { + int lvpos = linear_vpos + 1; + if (lvpos >= MAX_SCANDOUBLED_LINES) { return; } - struct linestate *l = &lines[linear_vpos][lof_display]; + struct linestate *l = &lines[lvpos][lof_display]; l->type = getlinetype(); if (!l->type) { @@ -10628,21 +10633,14 @@ static void storelinestate(void) l->ddfstop = ddfstop; l->diwstrt = diwstrt; l->diwstop = diwstop; - l->color0 = aga_mode ? agnus_colors.color_regs_aga[0] : agnus_colors.color_regs_ecs[0]; + l->color0 = ((bplcon0 & 1) && (bplcon3 & 0x20)) ? 0 : (aga_mode ? agnus_colors.color_regs_aga[0] : agnus_colors.color_regs_ecs[0]); l->bplcon3 = bplcon3; l->bplcon4 = bplcon4; l->diwhigh = diwhigh; l->fmode = fmode; - l->ltsidx = -1; if (l->type == LINETYPE_BPL) { -#if 0 - if (!l->linedatastate) { - l->linedatastate = xmalloc(uae_u8, MAX_STORED_BPL_DATA_BYTES + 256 * sizeof(uae_u32)); - } - l->linecolorstate = l->linedatastate; -#endif int stop = !harddis_h && ddfstop > 0xd8 ? 0xd8 : ddfstop; int len = ((stop - ddfstrt) + fetchunit - 1) / fetchunit + 1; len = len * fetchunit / fetchstart; @@ -10650,55 +10648,29 @@ static void storelinestate(void) if (len < MAX_STORED_BPL_DATA) { len <<= fetchmode; l->bpllen = len; -#if 0 - uae_u8 *dpt = l->linedatastate; - int planes = GET_PLANES(bplcon0); - for (int i = 0; i < planes; i++) { - uaecptr apt = bplpt[i]; -#if 0 - if (custom_fastmode_bplextendmask & (1 << i)) { - apt += fetchmode_bytes + getbplmod(i); - } -#endif - if (!valid_address(apt, len)) { - l->type = 0; - return; - } - uae_u8 *pt = get_real_address(apt); - memcpy(dpt, pt, len); - dpt += len; - } - int colors = getcolorcount(planes); - l->colors = colors; - l->linecolorstate = dpt; - if (aga_mode) { - memcpy(dpt, agnus_colors.color_regs_aga, colors * sizeof(uae_u32)); - } else { - memcpy(dpt, agnus_colors.color_regs_ecs, colors * sizeof(uae_u16)); - } -#endif } } } static bool checkprevfieldlinestateequal(void) { - if (linear_vpos >= MAX_SCANDOUBLED_LINES) { + int lvpos = linear_vpos + 1; + if (lvpos >= MAX_SCANDOUBLED_LINES + 1 || linear_display_vpos + 1 >= MAX_SCANDOUBLED_LINES) { return false; } bool ret = false; bool always = draw_always(); - struct linestate *l = &lines[linear_vpos][lof_display]; + struct linestate *l = &lines[lvpos][lof_display]; int type = getlinetype(); if (type && type == l->type && displayresetcnt == l->cnt) { - if (type == LINETYPE_BLANK && l->vb) { + if (type == LINETYPE_BLANK && strobe_fast != 0x3c) { if (1) { ret = true; } - } else if (type == LINETYPE_BORDER && !l->vb) { + } else if (type == LINETYPE_BORDER && strobe_fast == 0x3c && !l->blankedline) { if (1) { - uae_u32 c = aga_mode ? agnus_colors.color_regs_aga[0] : agnus_colors.color_regs_ecs[0]; + uae_u32 c = ((bplcon0 & 1) && (bplcon3 & 0x20)) ? 0 : (aga_mode ? agnus_colors.color_regs_aga[0] : agnus_colors.color_regs_ecs[0]); if (!always && c == l->color0) { ret = true; } else if (always || currprefs.cs_optimizations == DISPLAY_OPTIMIZATIONS_FULL) { @@ -10706,24 +10678,35 @@ static bool checkprevfieldlinestateequal(void) ret = draw_border_fast(l, linear_display_vpos + 1); } } - } else if (type == LINETYPE_BPL && !l->vb) { + } else if (type == LINETYPE_BPL && strobe_fast == 0x3c && !l->blankedline) { if (1) { int r = checkprevfieldlinestateequalbpl(l); if ((r && always) || (r && currprefs.cs_optimizations == DISPLAY_OPTIMIZATIONS_FULL)) { // no match but same parameters: do quick BPL emulation + int planes = GET_PLANES(bplcon0); storelinestate(); r = draw_line_fast(l, linear_display_vpos + 1, bplpt, true); - if (doflickerfix_active() && scandoubled_bpl_ena[linear_vpos + 1]) { - lof_display ^= 1; - struct linestate *l2 = &lines[linear_vpos][lof_display]; - scandoubled_line = 1; - uaecptr bplptx[MAX_PLANES]; - for (int i = 0; i < MAX_PLANES; i++) { - bplptx[i] = scandoubled_bpl_ptr[linear_vpos][lof_display][i]; + if (doflickerfix_active()) { + if (scandoubled_bpl_ena[lvpos]) { + lof_display ^= 1; + struct linestate *l2 = &lines[lvpos][lof_display]; + scandoubled_line = 1; + uaecptr bplptx[MAX_PLANES]; + bool skip = false; + for (int i = 0; i < planes; i++) { + bplptx[i] = scandoubled_bpl_ptr[lvpos][lof_display][i]; + if (bplptx[i] == 0 || bplptx[i] == 0xffffffff) { + skip = true; + } + } + if (skip) { + draw_border_fast(l, linear_display_vpos + 2); + } else { + draw_line_fast(l2, linear_display_vpos + 2, bplptx, false); + } + scandoubled_line = 0; + lof_display ^= 1; } - draw_line_fast(l2, linear_display_vpos + 1, bplptx, false); - scandoubled_line = 0; - lof_display ^= 1; } } ret = r > 0; @@ -11325,6 +11308,7 @@ static void custom_trigger_start(void) } } #endif + strobe_fast = get_strobe_reg(0); int canline = can_fast_custom(); if (canline) { calculate_linetype(linear_display_vpos + 1); @@ -12371,9 +12355,6 @@ static void sync_equalline_handler(void) custom_trigger_start(); - int dvp = calculate_linetype(linear_display_vpos); - denise_set_line(dvp); - check_vsyncs_fast(); if (eventtab[ev_sync].active) { diff --git a/drawing.cpp b/drawing.cpp index adf92ce9..98b5323d 100644 --- a/drawing.cpp +++ b/drawing.cpp @@ -84,6 +84,7 @@ struct denise_rga_queue bool lol, lof; uae_u16 strobe; int strobe_pos; + int erase; struct linestate *ls; }; @@ -110,6 +111,7 @@ static void quick_denise_rga(int linecnt, int startpos, int endpos) } static void denise_handle_quick_strobe(uae_u16 strobe, int offset, int vpos); +static void draw_denise_vsync(int); static void update_overlapped_cycles(int endpos) { @@ -152,6 +154,8 @@ static void read_denise_line_queue(void) } else if (q->type == 4) { denise_handle_quick_strobe(q->strobe, q->strobe_pos, q->vpos); next = true; + } else if (q->type == 5) { + draw_denise_vsync(q->erase); } //evt_t t2 = read_processor_time(); @@ -2049,12 +2053,12 @@ bool vsync_handle_check(void) return changed != 0; } -void vsync_handle_redraw(int long_field, int lof_changed, uae_u16 bplcon0p, uae_u16 bplcon3p, bool drawlines, bool initial) +void vsync_handle_redraw(int long_field, uae_u16 bplcon0p, uae_u16 bplcon3p, bool drawlines, bool initial) { int monid = 0; struct amigadisplay *ad = &adisplays[monid]; last_redraw_point++; - if (lof_changed || interlace_seen <= 0 || (currprefs.gfx_iscanlines && interlace_seen > 0) || last_redraw_point >= 2 || long_field || doublescan < 0) { + if (interlace_seen <= 0 || (currprefs.gfx_iscanlines && interlace_seen > 0) || last_redraw_point >= 2 || long_field || doublescan < 0) { last_redraw_point = 0; if (!initial) { @@ -4945,7 +4949,6 @@ void end_draw_denise(void) } draw_denise_line_queue_flush(); - denise_mark_last_line(); thread_debug_lock = false; @@ -5120,34 +5123,12 @@ static void lts_null(void) } } -static int prevline; -static int prev_last_line; -static int highestline; -static bool prev_last_line_req; - -void denise_mark_last_line(void) -{ - if (prev_last_line != prevline) { - prev_last_line = prevline; - prev_last_line_req = true; - } -} - -// set current line, used in fast mode emulation -void denise_set_line(int gfx_ypos) -{ - if (currprefs.gfx_overscanmode < OVERSCANMODE_ULTRA) { - gfx_ypos -= minfirstline_linear << currprefs.gfx_vresolution; - } - if (gfx_ypos < prevline) { - prevline = gfx_ypos; - } -} - static void get_line(int gfx_ypos, enum nln_how how) { struct vidbuf_description *vidinfo = &adisplays[0].gfxvidinfo; struct vidbuffer *vb = vidinfo->inbuffer; + int eraselines = 0; + int yadjust = currprefs.gfx_overscanmode < OVERSCANMODE_ULTRA ? minfirstline_linear << currprefs.gfx_vresolution : 0; xlinebuffer = NULL; xlinebuffer2 = NULL; @@ -5160,39 +5141,12 @@ static void get_line(int gfx_ypos, enum nln_how how) return; } - if (gfx_ypos < prevline - 1) { + gfx_ypos -= yadjust; - if (!denise_strlong_seen && strlong_emulation) { - strlong_emulation = false; - write_log("STRLONG strobe emulation deactivated.\n"); - select_lts(); - denise_lol_shift_enable = false; - denise_lol_shift_prev = 0; - } - denise_strlong_seen = false; - - // clear remaining lines if mode height is now smaller than previously - struct vidbuf_description *vidinfo = &adisplays[0].gfxvidinfo; - if (prevline != highestline) { - int l = prevline; - while (l < highestline && l < vb->inheight) { - uae_u8 *b = row_map[l]; - memset(b, 0, vb->inwidth * vb->pixbytes); - l++; - } - highestline = prevline; - } - } - if (gfx_ypos > prevline && gfx_ypos >= 0) { - prevline = gfx_ypos; - } - - if (currprefs.gfx_overscanmode < OVERSCANMODE_ULTRA) { - gfx_ypos -= minfirstline_linear << currprefs.gfx_vresolution; + if (how == nln_none) { + return; } - prevline = gfx_ypos >= 0 ? gfx_ypos : 0; - if (gfx_ypos >= 0 && gfx_ypos < vb->inheight) { denise_y_end = gfx_ypos + 1; xlinebuffer = row_map[gfx_ypos]; @@ -5261,6 +5215,32 @@ static void get_line(int gfx_ypos, enum nln_how how) } +static void draw_denise_vsync(int erase) +{ + struct vidbuf_description *vidinfo = &adisplays[0].gfxvidinfo; + struct vidbuffer *vb = vidinfo->inbuffer; + + if (!denise_strlong_seen && strlong_emulation) { + strlong_emulation = false; + write_log("STRLONG strobe emulation deactivated.\n"); + select_lts(); + denise_lol_shift_enable = false; + denise_lol_shift_prev = 0; + } + denise_strlong_seen = false; + + if (erase) { + // clear lines if mode height changed + struct vidbuf_description *vidinfo = &adisplays[0].gfxvidinfo; + int l = 0; + while (l < vb->inheight) { + uae_u8 *b = row_map[l]; + memset(b, 0, vb->inwidth * vb->pixbytes); + l++; + } + } +} + static void denise_draw_update(void) { if (denise_max_planes != denise_planes) { @@ -5311,60 +5291,69 @@ void draw_denise_line(int gfx_ypos, enum nln_how how, uae_u32 linecnt, int start internal_pixel_cnt = 0; internal_pixel_start_cnt = 0; - if (denise_pixtotal_max == -0x7fffffff || ((this_line->linear_vpos >= denise_vblank_extra_vbstop || this_line->linear_vpos < denise_vblank_extra_vbstrt) && currprefs.gfx_overscanmode < OVERSCANMODE_ULTRA)) { + bool blankline = (this_line->linear_vpos >= denise_vblank_extra_vbstop || this_line->linear_vpos < denise_vblank_extra_vbstrt) && currprefs.gfx_overscanmode < OVERSCANMODE_ULTRA; + + if (denise_pixtotal_max == -0x7fffffff || blankline) { // don't draw vertical blanking if not ultra extreme overscan while (denise_cck < denise_total) { - do_denise_cck(denise_linecnt, denise_startpos, denise_cck); - if (aga_mode) { - for (int h = 0; h < 2 ;h++) { - denise_cycle_half = h; - if (h) { - denise_hcounter_next = denise_hcounter_new; - } - checkhorizontal1_aga(denise_hcounter, denise_hcounter_next, h); - flush_null(); + while (denise_cck < denise_total) { + do_denise_cck(denise_linecnt, denise_startpos, denise_cck); + if (lts_changed) { + break; + } + if (aga_mode) { + for (int h = 0; h < 2 ;h++) { + denise_cycle_half = h; + if (h) { + denise_hcounter_next = denise_hcounter_new; + } + if (checkhorizontal1_aga(denise_hcounter, denise_hcounter_next, h)) continue; + flush_null(); #ifdef DEBUGGER - *debug_dma_dhpos_odd = denise_hcounter; + *debug_dma_dhpos_odd = denise_hcounter; #endif - denise_hcounter++; - denise_hcounter &= 511; - denise_hcounter_next++; - denise_hcounter_next &= 511; - } - } else { - for (int h = 0; h < 2 ;h++) { - denise_cycle_half = h; - if (h) { - denise_hcounter_next = denise_hcounter_new; + denise_hcounter++; + denise_hcounter &= 511; + denise_hcounter_next++; + denise_hcounter_next &= 511; } - checkhorizontal1_ecs(denise_hcounter, denise_hcounter_next, h); - flush_null(); + } else { + for (int h = 0; h < 2 ;h++) { + denise_cycle_half = h; + if (h) { + denise_hcounter_next = denise_hcounter_new; + } + if (checkhorizontal1_ecs(denise_hcounter, denise_hcounter_next, h)) continue; + flush_null(); #ifdef DEBUGGER - *debug_dma_dhpos_odd = denise_hcounter; + *debug_dma_dhpos_odd = denise_hcounter; #endif - denise_hcounter++; - denise_hcounter &= 511; - denise_hcounter_next++; - denise_hcounter_next &= 511; + denise_hcounter++; + denise_hcounter &= 511; + denise_hcounter_next++; + denise_hcounter_next &= 511; + } } + denise_hcounter = denise_hcounter_new; + denise_cck++; } - denise_hcounter = denise_hcounter_new; - denise_cck++; + lts_changed = false; } if (buf1 && denise_pixtotal_max > 0) { -#if 0 memset(buf1, 0, ((2 * denise_pixtotal_max) << hresolution) * sizeof(uae_u32)); if (buf2 && buf1 != buf2) { memset(buf2, 0, ((2 * denise_pixtotal_max) << hresolution) * sizeof(uae_u32)); } -#endif if (gbuf) { memset(gbuf, 0, (2 * denise_pixtotal_max) << hresolution); } } + last_bpl_pix = 0; + setlasthamcolor(); + } else { // visible line @@ -5411,8 +5400,12 @@ void draw_denise_line(int gfx_ypos, enum nln_how how, uae_u32 linecnt, int start uae_u32 *p1 = hbstrt_ptr1 - denise_lol_shift_prev; uae_u32 *p2 = hbstrt_ptr2 - denise_lol_shift_prev; for (int i = 0; i < add * 2; i++) { - *p1++ = BLANK_COLOR; - *p2++ = BLANK_COLOR; + if (hbstrt_ptr1) { + *p1++ = BLANK_COLOR; + } + if (hbstrt_ptr2) { + *p2++ = BLANK_COLOR; + } } } if (1 && no_denise_lol && denise_pixtotal_max != -0x7fffffff && hbstrt_ptr1 && !lol_fast && denise_strlong_seen) { @@ -5420,8 +5413,12 @@ void draw_denise_line(int gfx_ypos, enum nln_how how, uae_u32 linecnt, int start uae_u32 *p1 = hbstrt_ptr1 - 2 * add; uae_u32 *p2 = hbstrt_ptr2 - 2 * add; for (int i = 0; i < add * 2; i++) { - *p1++ = BLANK_COLOR; - *p2++ = BLANK_COLOR; + if (hbstrt_ptr1) { + *p1++ = BLANK_COLOR; + } + if (hbstrt_ptr2) { + *p2++ = BLANK_COLOR; + } } } if (currprefs.gfx_overscanmode < OVERSCANMODE_OVERSCAN) { @@ -5503,7 +5500,7 @@ void draw_denise_line(int gfx_ypos, enum nln_how how, uae_u32 linecnt, int start ls->bpl1dat_trigger_offset = bpl1dat_trigger_offset; ls->internal_pixel_cnt = internal_pixel_cnt; ls->internal_pixel_start_cnt = internal_pixel_start_cnt; - ls->vb = denise_vblank_active; + ls->blankedline = this_line->linear_vpos >= denise_vblank_extra_vbstop || this_line->linear_vpos < denise_vblank_extra_vbstrt; } resolution_count[denise_res]++; @@ -5534,6 +5531,7 @@ static void select_lts(void) LINETOSRC_FUNC lts_old = lts; bool samecycle = denise_hcounter == denise_hcounter_prev; + int bm = bplmode_new; // if plane count decreases mid-scanline, old data in higher plane count shifters must be still shifted out. if (denise_planes > denise_max_planes) { denise_max_planes = denise_planes; @@ -5547,10 +5545,10 @@ static void select_lts(void) if (denise_bplfmode == 1 && denise_res > 1 && denise_max_planes > 4) { denise_max_planes = 4; } - if (denise_max_planes > 6 && (bplmode_new == CMODE_EXTRAHB || bplmode_new == CMODE_EXTRAHB_ECS_KILLEHB)) { + if (denise_max_planes > 6 && (bm == CMODE_EXTRAHB || bm == CMODE_EXTRAHB_ECS_KILLEHB)) { denise_max_planes = 6; } - if (denise_max_planes == 7 && bplmode_new == CMODE_HAM) { + if (denise_max_planes == 7 && bm == CMODE_HAM) { denise_max_planes = 6; } denise_odd_even = bplcon1_shift[0] != bplcon1_shift[1]; @@ -5562,11 +5560,11 @@ static void select_lts(void) } hresolution_add = 1 << hresolution; - if (denise_max_planes <= 4 && bplmode_new == CMODE_HAM) { - bplmode_new = CMODE_NORMAL; + if (denise_max_planes <= 4 && bm == CMODE_HAM) { + bm = CMODE_NORMAL; } - if (denise_max_planes <= 5 && (bplmode_new == CMODE_EXTRAHB || bplmode_new == CMODE_EXTRAHB_ECS_KILLEHB)) { - bplmode_new = CMODE_NORMAL; + if (denise_max_planes <= 5 && (bm == CMODE_EXTRAHB || bm == CMODE_EXTRAHB_ECS_KILLEHB)) { + bm = CMODE_NORMAL; } if (aga_mode) { @@ -5578,12 +5576,12 @@ static void select_lts(void) if (need_genlock_data) { int planes = denise_max_planes > 4 ? 1 : 0; int oddeven = denise_max_odd_even ? 1 : 0; - int idx = (oddeven) + (bplmode_new * 2) + (planes * 2 * 5) + (spr * 2 * 5 * 2) + (denise_res * 2 * 5 * 2 * 2) + (hresolution * 2 * 5 * 2 * 2 * 3) + (bpldat_fmode * 2 * 5 * 2 * 2 * 3 * 3); + int idx = (oddeven) + (bm * 2) + (planes * 2 * 5) + (spr * 2 * 5 * 2) + (denise_res * 2 * 5 * 2 * 2) + (hresolution * 2 * 5 * 2 * 2 * 3) + (bpldat_fmode * 2 * 5 * 2 * 2 * 3 * 3); lts = linetoscr_aga_genlock_funcs[idx]; } else { int planes = denise_max_planes > 0 ? (denise_max_planes - 1) / 2 : 0; int oddeven = denise_max_odd_even ? 1 : 0; - int idx = (oddeven) + (bplmode_new * 2) + (planes * 2 * 5) + (spr * 2 * 5 * 4) + (denise_res * 2 * 5 * 4 * 2) + (hresolution * 2 * 5 * 4 * 2 * 3) + (bpldat_fmode * 2 * 5 * 4 * 2 * 3 * 3); + int idx = (oddeven) + (bm * 2) + (planes * 2 * 5) + (spr * 2 * 5 * 4) + (denise_res * 2 * 5 * 4 * 2) + (hresolution * 2 * 5 * 4 * 2 * 3) + (bpldat_fmode * 2 * 5 * 4 * 2 * 3 * 3); lts = linetoscr_aga_funcs[idx]; } @@ -5608,7 +5606,7 @@ static void select_lts(void) } if (need_genlock_data) { int oddeven = denise_max_odd_even; - int idx = (oddeven) + (bplmode_new * 2) + (spr * 2 * 4) + (denise_res * 2 * 4 * 2) + (hresolution * 2 * 4 * 2 * 2); + int idx = (oddeven) + (bm * 2) + (spr * 2 * 4) + (denise_res * 2 * 4 * 2) + (hresolution * 2 * 4 * 2 * 2); lts = strlong_emulation ? linetoscr_ecs_ntsc_genlock_funcs[idx] : linetoscr_ecs_genlock_funcs[idx]; } else { int planes; @@ -5635,7 +5633,7 @@ static void select_lts(void) break; } int oddeven = denise_max_odd_even; - int idx = (oddeven) + (bplmode_new * 2) + (planes * 2 * 4) + (spr * 2 * 4 * 4) + (denise_res * 2 * 4 * 4 * 2) + (hresolution * 2 * 4 * 4 * 2 * 2); + int idx = (oddeven) + (bm * 2) + (planes * 2 * 4) + (spr * 2 * 4 * 4) + (denise_res * 2 * 4 * 4 * 2) + (hresolution * 2 * 4 * 4 * 2 * 2); lts = strlong_emulation ? linetoscr_ecs_ntsc_funcs[idx] : linetoscr_ecs_funcs[idx]; } @@ -6209,370 +6207,6 @@ STATIC_INLINE void pfield_doline32_8(uae_u32 *pixels, int wordcount, int planes, } } -#if 0 -STATIC_INLINE void pfield_doline32_16(uae_u32 *pixels, int wordcount, int planes, uae_u8 *real_bplpt[8]) -{ - while (wordcount-- > 0) { - uae_u32 b0, b1, b2, b3, b4, b5, b6, b7; - - b0 = 0, b1 = 0, b2 = 0, b3 = 0, b4 = 0, b5 = 0, b6 = 0, b7 = 0; - switch (planes) { -#ifdef AGA - case 8: b0 = GETLONG32_16(real_bplpt[7]); real_bplpt[7] += 4; - case 7: b1 = GETLONG32_16(real_bplpt[6]); real_bplpt[6] += 4; -#endif - case 6: b2 = GETLONG32_16(real_bplpt[5]); real_bplpt[5] += 4; - case 5: b3 = GETLONG32_16(real_bplpt[4]); real_bplpt[4] += 4; - case 4: b4 = GETLONG32_16(real_bplpt[3]); real_bplpt[3] += 4; - case 3: b5 = GETLONG32_16(real_bplpt[2]); real_bplpt[2] += 4; - case 2: b6 = GETLONG32_16(real_bplpt[1]); real_bplpt[1] += 4; - case 1: b7 = GETLONG32_16(real_bplpt[0]); real_bplpt[0] += 4; - } - - MERGE32(b0, b1, 0x55555555, 1); - MERGE32(b2, b3, 0x55555555, 1); - MERGE32(b4, b5, 0x55555555, 1); - MERGE32(b6, b7, 0x55555555, 1); - - MERGE32(b0, b2, 0x33333333, 2); - MERGE32(b1, b3, 0x33333333, 2); - MERGE32(b4, b6, 0x33333333, 2); - MERGE32(b5, b7, 0x33333333, 2); - - MERGE32(b0, b4, 0x0f0f0f0f, 4); - MERGE32(b1, b5, 0x0f0f0f0f, 4); - MERGE32(b2, b6, 0x0f0f0f0f, 4); - MERGE32(b3, b7, 0x0f0f0f0f, 4); - - MERGE32(b0, b1, 0x00ff00ff, 8); - MERGE32(b2, b3, 0x00ff00ff, 8); - MERGE32(b4, b5, 0x00ff00ff, 8); - MERGE32(b6, b7, 0x00ff00ff, 8); - - MERGE32(b0, b2, 0x0000ffff, 16); -#if DOLINE_SWAP - pixels[0] = b0; - pixels[4] = b2; -#else - do_put_mem_long(pixels + 0, b0); - do_put_mem_long(pixels + 4, b2); -#endif - MERGE32(b1, b3, 0x0000ffff, 16); -#if DOLINE_SWAP - pixels[2] = b1; - pixels[6] = b3; -#else - do_put_mem_long(pixels + 2, b1); - do_put_mem_long(pixels + 6, b3); -#endif - MERGE32(b4, b6, 0x0000ffff, 16); -#if DOLINE_SWAP - pixels[1] = b4; - pixels[5] = b6; -#else - do_put_mem_long(pixels + 1, b4); - do_put_mem_long(pixels + 5, b6); -#endif - MERGE32(b5, b7, 0x0000ffff, 16); -#if DOLINE_SWAP - pixels[3] = b5; - pixels[7] = b7; -#else - do_put_mem_long(pixels + 3, b5); - do_put_mem_long(pixels + 7, b7); -#endif - pixels += 8; - } -} - -STATIC_INLINE void pfield_doline32_32(uae_u32 *pixels, int wordcount, int planes, uae_u8 *real_bplpt[8]) -{ - while (wordcount-- > 0) { - uae_u32 b0, b1, b2, b3, b4, b5, b6, b7; - - b0 = 0, b1 = 0, b2 = 0, b3 = 0, b4 = 0, b5 = 0, b6 = 0, b7 = 0; - switch (planes) { -#ifdef AGA - case 8: b0 = GETLONG32_32(real_bplpt[7]); real_bplpt[7] += 4; - case 7: b1 = GETLONG32_32(real_bplpt[6]); real_bplpt[6] += 4; -#endif - case 6: b2 = GETLONG32_32(real_bplpt[5]); real_bplpt[5] += 4; - case 5: b3 = GETLONG32_32(real_bplpt[4]); real_bplpt[4] += 4; - case 4: b4 = GETLONG32_32(real_bplpt[3]); real_bplpt[3] += 4; - case 3: b5 = GETLONG32_32(real_bplpt[2]); real_bplpt[2] += 4; - case 2: b6 = GETLONG32_32(real_bplpt[1]); real_bplpt[1] += 4; - case 1: b7 = GETLONG32_32(real_bplpt[0]); real_bplpt[0] += 4; - } - - MERGE32(b0, b1, 0x55555555, 1); - MERGE32(b2, b3, 0x55555555, 1); - MERGE32(b4, b5, 0x55555555, 1); - MERGE32(b6, b7, 0x55555555, 1); - - MERGE32(b0, b2, 0x33333333, 2); - MERGE32(b1, b3, 0x33333333, 2); - MERGE32(b4, b6, 0x33333333, 2); - MERGE32(b5, b7, 0x33333333, 2); - - MERGE32(b0, b4, 0x0f0f0f0f, 4); - MERGE32(b1, b5, 0x0f0f0f0f, 4); - MERGE32(b2, b6, 0x0f0f0f0f, 4); - MERGE32(b3, b7, 0x0f0f0f0f, 4); - - MERGE32(b0, b1, 0x00ff00ff, 8); - MERGE32(b2, b3, 0x00ff00ff, 8); - MERGE32(b4, b5, 0x00ff00ff, 8); - MERGE32(b6, b7, 0x00ff00ff, 8); - - MERGE32(b0, b2, 0x0000ffff, 16); -#if DOLINE_SWAP - pixels[0] = b0; - pixels[4] = b2; -#else - do_put_mem_long(pixels + 0, b0); - do_put_mem_long(pixels + 4, b2); -#endif - MERGE32(b1, b3, 0x0000ffff, 16); -#if DOLINE_SWAP - pixels[2] = b1; - pixels[6] = b3; -#else - do_put_mem_long(pixels + 2, b1); - do_put_mem_long(pixels + 6, b3); -#endif - MERGE32(b4, b6, 0x0000ffff, 16); -#if DOLINE_SWAP - pixels[1] = b4; - pixels[5] = b6; -#else - do_put_mem_long(pixels + 1, b4); - do_put_mem_long(pixels + 5, b6); -#endif - MERGE32(b5, b7, 0x0000ffff, 16); -#if DOLINE_SWAP - pixels[3] = b5; - pixels[7] = b7; -#else - do_put_mem_long(pixels + 3, b5); - do_put_mem_long(pixels + 7, b7); -#endif - pixels += 8; - } -} - - -STATIC_INLINE void pfield_doline32_64(uae_u32 *pixels, int wordcount, int planes, uae_u8 *real_bplpt[8]) -{ - int w = 4; - while (wordcount-- > 0) { - uae_u32 b0, b1, b2, b3, b4, b5, b6, b7; - - b0 = 0, b1 = 0, b2 = 0, b3 = 0, b4 = 0, b5 = 0, b6 = 0, b7 = 0; - switch (planes) { -#ifdef AGA - case 8: real_bplpt[7] += w; b0 = GETLONG32_64(real_bplpt[7]); real_bplpt[7] += 8; - case 7: real_bplpt[6] += w; b1 = GETLONG32_64(real_bplpt[6]); real_bplpt[6] += 8; -#endif - case 6: real_bplpt[5] += w; b2 = GETLONG32_64(real_bplpt[5]); real_bplpt[5] += 8; - case 5: real_bplpt[4] += w; b3 = GETLONG32_64(real_bplpt[4]); real_bplpt[4] += 8; - case 4: real_bplpt[3] += w; b4 = GETLONG32_64(real_bplpt[3]); real_bplpt[3] += 8; - case 3: real_bplpt[2] += w; b5 = GETLONG32_64(real_bplpt[2]); real_bplpt[2] += 8; - case 2: real_bplpt[1] += w; b6 = GETLONG32_64(real_bplpt[1]); real_bplpt[1] += 8; - case 1: real_bplpt[0] += w; b7 = GETLONG32_64(real_bplpt[0]); real_bplpt[0] += 8; - } - w = w > 0 ? -12 : 4; - - MERGE32(b0, b1, 0x55555555, 1); - MERGE32(b2, b3, 0x55555555, 1); - MERGE32(b4, b5, 0x55555555, 1); - MERGE32(b6, b7, 0x55555555, 1); - - MERGE32(b0, b2, 0x33333333, 2); - MERGE32(b1, b3, 0x33333333, 2); - MERGE32(b4, b6, 0x33333333, 2); - MERGE32(b5, b7, 0x33333333, 2); - - MERGE32(b0, b4, 0x0f0f0f0f, 4); - MERGE32(b1, b5, 0x0f0f0f0f, 4); - MERGE32(b2, b6, 0x0f0f0f0f, 4); - MERGE32(b3, b7, 0x0f0f0f0f, 4); - - MERGE32(b0, b1, 0x00ff00ff, 8); - MERGE32(b2, b3, 0x00ff00ff, 8); - MERGE32(b4, b5, 0x00ff00ff, 8); - MERGE32(b6, b7, 0x00ff00ff, 8); - - MERGE32(b0, b2, 0x0000ffff, 16); -#if DOLINE_SWAP - pixels[0] = b0; - pixels[4] = b2; -#else - do_put_mem_long(pixels + 0, b0); - do_put_mem_long(pixels + 4, b2); -#endif - MERGE32(b1, b3, 0x0000ffff, 16); -#if DOLINE_SWAP - pixels[2] = b1; - pixels[6] = b3; -#else - do_put_mem_long(pixels + 2, b1); - do_put_mem_long(pixels + 6, b3); -#endif - MERGE32(b4, b6, 0x0000ffff, 16); -#if DOLINE_SWAP - pixels[1] = b4; - pixels[5] = b6; -#else - do_put_mem_long(pixels + 1, b4); - do_put_mem_long(pixels + 5, b6); -#endif - MERGE32(b5, b7, 0x0000ffff, 16); -#if DOLINE_SWAP - pixels[3] = b5; - pixels[7] = b7; -#else - do_put_mem_long(pixels + 3, b5); - do_put_mem_long(pixels + 7, b7); -#endif - pixels += 8; - } -} - -static void NOINLINE pfield_doline32_n1_16(uae_u32 *data, int count, uae_u8 *real_bplpt[8]) { pfield_doline32_16(data, count, 1, real_bplpt); } -static void NOINLINE pfield_doline32_n2_16(uae_u32 *data, int count, uae_u8 *real_bplpt[8]) { pfield_doline32_16(data, count, 2, real_bplpt); } -static void NOINLINE pfield_doline32_n3_16(uae_u32 *data, int count, uae_u8 *real_bplpt[8]) { pfield_doline32_16(data, count, 3, real_bplpt); } -static void NOINLINE pfield_doline32_n4_16(uae_u32 *data, int count, uae_u8 *real_bplpt[8]) { pfield_doline32_16(data, count, 4, real_bplpt); } -static void NOINLINE pfield_doline32_n5_16(uae_u32 *data, int count, uae_u8 *real_bplpt[8]) { pfield_doline32_16(data, count, 5, real_bplpt); } -static void NOINLINE pfield_doline32_n6_16(uae_u32 *data, int count, uae_u8 *real_bplpt[8]) { pfield_doline32_16(data, count, 6, real_bplpt); } -#ifdef AGA -static void NOINLINE pfield_doline32_n7_16(uae_u32 *data, int count, uae_u8 *real_bplpt[8]) { pfield_doline32_16(data, count, 7, real_bplpt); } -static void NOINLINE pfield_doline32_n8_16(uae_u32 *data, int count, uae_u8 *real_bplpt[8]) { pfield_doline32_16(data, count, 8, real_bplpt); } -#endif -#ifdef AGA -static void NOINLINE pfield_doline32_n1_32(uae_u32 *data, int count, uae_u8 *real_bplpt[8]) { pfield_doline32_32(data, count, 1, real_bplpt); } -static void NOINLINE pfield_doline32_n2_32(uae_u32 *data, int count, uae_u8 *real_bplpt[8]) { pfield_doline32_32(data, count, 2, real_bplpt); } -static void NOINLINE pfield_doline32_n3_32(uae_u32 *data, int count, uae_u8 *real_bplpt[8]) { pfield_doline32_32(data, count, 3, real_bplpt); } -static void NOINLINE pfield_doline32_n4_32(uae_u32 *data, int count, uae_u8 *real_bplpt[8]) { pfield_doline32_32(data, count, 4, real_bplpt); } -static void NOINLINE pfield_doline32_n5_32(uae_u32 *data, int count, uae_u8 *real_bplpt[8]) { pfield_doline32_32(data, count, 5, real_bplpt); } -static void NOINLINE pfield_doline32_n6_32(uae_u32 *data, int count, uae_u8 *real_bplpt[8]) { pfield_doline32_32(data, count, 6, real_bplpt); } -static void NOINLINE pfield_doline32_n7_32(uae_u32 *data, int count, uae_u8 *real_bplpt[8]) { pfield_doline32_32(data, count, 7, real_bplpt); } -static void NOINLINE pfield_doline32_n8_32(uae_u32 *data, int count, uae_u8 *real_bplpt[8]) { pfield_doline32_32(data, count, 8, real_bplpt); } -static void NOINLINE pfield_doline32_n1_64(uae_u32 *data, int count, uae_u8 *real_bplpt[8]) { pfield_doline32_64(data, count, 1, real_bplpt); } -static void NOINLINE pfield_doline32_n2_64(uae_u32 *data, int count, uae_u8 *real_bplpt[8]) { pfield_doline32_64(data, count, 2, real_bplpt); } -static void NOINLINE pfield_doline32_n3_64(uae_u32 *data, int count, uae_u8 *real_bplpt[8]) { pfield_doline32_64(data, count, 3, real_bplpt); } -static void NOINLINE pfield_doline32_n4_64(uae_u32 *data, int count, uae_u8 *real_bplpt[8]) { pfield_doline32_64(data, count, 4, real_bplpt); } -static void NOINLINE pfield_doline32_n5_64(uae_u32 *data, int count, uae_u8 *real_bplpt[8]) { pfield_doline32_64(data, count, 5, real_bplpt); } -static void NOINLINE pfield_doline32_n6_64(uae_u32 *data, int count, uae_u8 *real_bplpt[8]) { pfield_doline32_64(data, count, 6, real_bplpt); } -static void NOINLINE pfield_doline32_n7_64(uae_u32 *data, int count, uae_u8 *real_bplpt[8]) { pfield_doline32_64(data, count, 7, real_bplpt); } -static void NOINLINE pfield_doline32_n8_64(uae_u32 *data, int count, uae_u8 *real_bplpt[8]) { pfield_doline32_64(data, count, 8, real_bplpt); } -#endif - -static void pfield_doline_16(int planecnt, int wordcount, uae_u8 *datap, struct linestate *ls) -{ - uae_u8 **real_bplpt = ls->bplpt; - uae_u32 *data = (uae_u32*)datap; - uae_u8 *dpt = ls->linedatastate; - int len = ls->bpllen; - for (int i = 0; i < planecnt; i++) { - memcpy(dpt, ls->bplpt[i], len); - dpt += len; - } - switch (planecnt) { - default: break; - case 0: memset(data, 0, wordcount * 32); break; - case 1: pfield_doline32_n1_16(data, wordcount, real_bplpt); break; - case 2: pfield_doline32_n2_16(data, wordcount, real_bplpt); break; - case 3: pfield_doline32_n3_16(data, wordcount, real_bplpt); break; - case 4: pfield_doline32_n4_16(data, wordcount, real_bplpt); break; - case 5: pfield_doline32_n5_16(data, wordcount, real_bplpt); break; - case 6: pfield_doline32_n6_16(data, wordcount, real_bplpt); break; -#ifdef AGA - case 7: pfield_doline32_n7_16(data, wordcount, real_bplpt); break; - case 8: pfield_doline32_n8_16(data, wordcount, real_bplpt); break; -#endif - } -} -static void pfield_doline_32(int planecnt, int wordcount, uae_u8 *datap, struct linestate *ls) -{ - uae_u8 **real_bplpt = ls->bplpt; - uae_u32 *data = (uae_u32*)datap; - uae_u8 *dpt = ls->linedatastate; - int len = ls->bpllen; - for (int i = 0; i < planecnt; i++) { - memcpy(dpt, ls->bplpt[i], len); - dpt += len; - } - switch (planecnt) { - default: break; - case 0: memset(data, 0, wordcount * 32); break; - case 1: pfield_doline32_n1_32(data, wordcount, real_bplpt); break; - case 2: pfield_doline32_n2_32(data, wordcount, real_bplpt); break; - case 3: pfield_doline32_n3_32(data, wordcount, real_bplpt); break; - case 4: pfield_doline32_n4_32(data, wordcount, real_bplpt); break; - case 5: pfield_doline32_n5_32(data, wordcount, real_bplpt); break; - case 6: pfield_doline32_n6_32(data, wordcount, real_bplpt); break; -#ifdef AGA - case 7: pfield_doline32_n7_32(data, wordcount, real_bplpt); break; - case 8: pfield_doline32_n8_32(data, wordcount, real_bplpt); break; -#endif - } -} -static void pfield_doline_64(int planecnt, int wordcount, uae_u8 *datap, struct linestate *ls) -{ - uae_u8 **real_bplpt = ls->bplpt; - uae_u32 *data = (uae_u32*)datap; - uae_u8 *dpt = ls->linedatastate; - int len = ls->bpllen; - for (int i = 0; i < planecnt; i++) { - memcpy(dpt, ls->bplpt[i], len); - dpt += len; - } - switch (planecnt) { - default: break; - case 0: memset(data, 0, wordcount * 32); break; - case 1: pfield_doline32_n1_64(data, wordcount, real_bplpt); break; - case 2: pfield_doline32_n2_64(data, wordcount, real_bplpt); break; - case 3: pfield_doline32_n3_64(data, wordcount, real_bplpt); break; - case 4: pfield_doline32_n4_64(data, wordcount, real_bplpt); break; - case 5: pfield_doline32_n5_64(data, wordcount, real_bplpt); break; - case 6: pfield_doline32_n6_64(data, wordcount, real_bplpt); break; -#ifdef AGA - case 7: pfield_doline32_n7_64(data, wordcount, real_bplpt); break; - case 8: pfield_doline32_n8_64(data, wordcount, real_bplpt); break; -#endif - } -} - -static void pfield_doline_not_fast_enough_yet(int planecnt, int wordcount, uae_u8 *data, struct linestate *ls) -{ - wordcount *= 4; - uae_u8 *dpt = ls->linedatastate; - int len = ls->bpllen; - for (int i = 0; i < planecnt; i++) { - memcpy(dpt, ls->bplpt[i], len); - dpt += len; - } - while (wordcount-- > 0) { - uae_u32 v[MAX_PLANES]; - for (int i = 0; i < planecnt; i++) { - v[i] = *ls->bplpt[i]; - ls->bplpt[i]++; - } - for (int i = 0; i < 8; i++) { - uae_u8 out = 0; - for (int j = 0; j < planecnt; j++) { - if (v[j] & 0x80) { - out |= 1 << j; - } - v[j] <<= 1; - } - out &= debug_bpl_mask; - *data++ = out; - } - } -} -#endif - /* See above for comments on inlining. These functions should _not_ be inlined themselves. */ static void NOINLINE pfield_doline32_n1_8(uae_u32 *data, int count, uae_u8 *real_bplpt[8]) { pfield_doline32_8(data, count, 1, real_bplpt); } @@ -6589,14 +6223,6 @@ static void pfield_doline_8(int planecnt, int wordcount, uae_u8 *datap, struct l { uae_u8 **real_bplpt = ls->bplpt; uae_u32 *data = (uae_u32 *)datap; -#if 0 - uae_u8 *dpt = ls->linedatastate; - int len = ls->bpllen; - for (int i = 0; i < planecnt; i++) { - memcpy(dpt, ls->bplpt[i], len); - dpt += len; - } -#endif switch (planecnt) { default: break; case 0: memset(data, 0, wordcount * 32); break; @@ -6653,6 +6279,10 @@ void draw_denise_border_line_fast(int gfx_ypos, enum nln_how how, struct linesta return; } + if (ls->blankedline) { + return; + } + uae_u32 *buf1p = buf1; uae_u32 *buf2p = buf2 != buf1 ? buf2 : NULL; uae_u8 *gbufp = gbuf; @@ -6682,7 +6312,6 @@ void draw_denise_border_line_fast(int gfx_ypos, enum nln_how how, struct linesta buf1 = buf1p; buf2 = buf2p; - int start = draw_startoffset; if (start < hbstop_offset) { int diff = hbstop_offset - start; @@ -6741,7 +6370,7 @@ void draw_denise_border_line_fast(int gfx_ypos, enum nln_how how, struct linesta total = end - start; if (need_genlock_data && gbuf && total) { - int max = gbuf_end - gbufp; + int max = addrdiff(gbuf_end, gbufp); total += 8; if (total > max) { total = max; @@ -6759,7 +6388,7 @@ void draw_denise_bitplane_line_fast(int gfx_ypos, enum nln_how how, struct lines return; } - if ((this_line->linear_vpos >= denise_vblank_extra_vbstop || this_line->linear_vpos < denise_vblank_extra_vbstrt) && currprefs.gfx_overscanmode < OVERSCANMODE_ULTRA) { + if (ls->blankedline) { return; } @@ -6771,36 +6400,34 @@ void draw_denise_bitplane_line_fast(int gfx_ypos, enum nln_how how, struct lines bool ham = (ls->bplcon0 & 0x800) != 0; int fmode = 16 << (((ls->fmode & 3) == 3 ? 2 : (ls->fmode & 3))); - if (ls->ltsidx < 0) { - bool ehb = planecnt == 6 && !ham && !dpf && (!ecs_denise || !(ls->bplcon2 & 0x200)); - int mode = CMODE_NORMAL; - if (ham) { - mode = CMODE_HAM; - ham_lastcolor = 0; - } else if (dpf) { - mode = CMODE_DUALPF; - } else if (ehb) { - mode = CMODE_EXTRAHB; - } - int idx = mode + 5 * res + 5 * 3 * hresolution; - if (buf2p) { - idx += 5 * 3 * 3; - } - ls->ltsidx = idx; + bool ehb = planecnt == 6 && !ham && !dpf && (!ecs_denise || !(ls->bplcon2 & 0x200)); + int mode = CMODE_NORMAL; + if (ham) { + mode = CMODE_HAM; + last_bpl_pix = 0; + setlasthamcolor(); + } else if (dpf) { + mode = CMODE_DUALPF; + } else if (ehb) { + mode = CMODE_EXTRAHB; + } + int ltsidx = mode + 5 * res + 5 * 3 * hresolution; + if (buf2p) { + ltsidx += 5 * 3 * 3; } LINETOSRC_FUNCF ltsf; if (aga_mode) { if (need_genlock_data) { - ltsf = linetoscr_aga_genlock_fast_funcs[ls->ltsidx]; + ltsf = linetoscr_aga_genlock_fast_funcs[ltsidx]; } else { - ltsf = linetoscr_aga_fast_funcs[ls->ltsidx]; + ltsf = linetoscr_aga_fast_funcs[ltsidx]; } } else { if (need_genlock_data) { - ltsf = linetoscr_ecs_genlock_fast_funcs[ls->ltsidx]; + ltsf = linetoscr_ecs_genlock_fast_funcs[ltsidx]; } else { - ltsf = linetoscr_ecs_fast_funcs[ls->ltsidx]; + ltsf = linetoscr_ecs_fast_funcs[ltsidx]; } } @@ -6959,7 +6586,7 @@ void draw_denise_bitplane_line_fast(int gfx_ypos, enum nln_how how, struct lines // clear some more bytes to clear possible lightpen cursor graphics if (need_genlock_data && gbuf) { - int max = gbuf_end - gbuf; + int max = addrdiff(gbuf_end, gbuf); int total = 8; if (total > max) { total = max; @@ -7301,6 +6928,29 @@ void draw_denise_line_queue(int gfx_ypos, nln_how how, uae_u32 linecnt, int star } } +void draw_denise_vsync_queue(int erase) +{ + if (MULTITHREADED_DENISE) { + + if (!waitqueue()) { + return; + } + struct denise_rga_queue *q = &rga_queue[rga_queue_write & DENISE_RGA_SLOT_CHUNKS_MASK]; + q->type = 5; + q->erase = erase; + q->vpos = vpos; + q->linear_vpos = linear_vpos; + + addtowritequeue(); + + } else { + + updatelinedata(); + draw_denise_vsync(erase); + + } +} + void draw_denise_line_queue_flush(void) { if (MULTITHREADED_DENISE) { diff --git a/genlinetoscr.cpp b/genlinetoscr.cpp index 56950f23..317f4349 100644 --- a/genlinetoscr.cpp +++ b/genlinetoscr.cpp @@ -1030,7 +1030,7 @@ static void gen_fastdraw(void) outf("while (cnt < end) {"); outf(" bool bpl = false;"); - outf(" if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) {"); + outf(" if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) {"); outf(" if (cnt >= draw_startoffset) {"); outf(" if (cnt < hbstop_offset) {"); if (doubling <= 0) { diff --git a/include/drawing.h b/include/drawing.h index 70626384..f5277c63 100644 --- a/include/drawing.h +++ b/include/drawing.h @@ -79,7 +79,7 @@ STATIC_INLINE xcolnr getxcolor(int c) } /* functions for reading, writing, copying and comparing struct color_entry */ -STATIC_INLINE int color_reg_get (struct color_entry *ce, int c) +STATIC_INLINE int color_reg_get(struct color_entry *ce, int c) { #ifdef AGA if (aga_mode) @@ -92,8 +92,8 @@ STATIC_INLINE int color_reg_get (struct color_entry *ce, int c) #define MAX_PIXELS_PER_LINE 2304 /* Functions in drawing.c. */ -extern int coord_native_to_amiga_y (int); -extern int coord_native_to_amiga_x (int); +extern int coord_native_to_amiga_y(int); +extern int coord_native_to_amiga_x(int); /* Determine how to draw a scan line. */ enum nln_how { @@ -110,24 +110,24 @@ enum nln_how { nln_upper_black, nln_lower_black, nln_upper_black_always, - nln_lower_black_always + nln_lower_black_always, + nln_none }; -extern void vsync_handle_redraw (int long_field, int lof_changed, uae_u16, uae_u16, bool drawlines, bool initial); -extern bool vsync_handle_check (void); -extern void reset_drawing (void); -extern void drawing_init (void); -extern bool frame_drawn (int monid); +extern void vsync_handle_redraw(int long_field, uae_u16, uae_u16, bool drawlines, bool initial); +extern bool vsync_handle_check(void); +extern void reset_drawing(void); +extern void drawing_init(void); +extern bool frame_drawn(int monid); extern void redraw_frame(void); extern void full_redraw_all(void); -extern int get_custom_limits (int *pw, int *ph, int *pdx, int *pdy, int *prealh); -extern void store_custom_limits (int w, int h, int dx, int dy); -extern void set_custom_limits (int w, int h, int dx, int dy, bool blank); -extern void check_custom_limits (void); -extern void get_custom_topedge (int *x, int *y, bool max); -extern void get_custom_raw_limits (int *pw, int *ph, int *pdx, int *pdy); -void get_custom_mouse_limits (int *pw, int *ph, int *pdx, int *pdy, int dbl); extern int get_custom_limits(int *pw, int *ph, int *pdx, int *pdy, int *prealh, int *hres, int *vres); +extern void store_custom_limits(int w, int h, int dx, int dy); +extern void set_custom_limits(int w, int h, int dx, int dy, bool blank); +extern void check_custom_limits(void); +extern void get_custom_topedge(int *x, int *y, bool max); +extern void get_custom_raw_limits(int *pw, int *ph, int *pdx, int *pdy); +void get_custom_mouse_limits(int *pw, int *ph, int *pdx, int *pdy, int dbl); extern void putpixel(uae_u8 *buf, uae_u8 *genlockbuf, int x, xcolnr c8); extern void allocvidbuffer(int monid, struct vidbuffer *buf, int width, int height, int depth); extern void freevidbuffer(int monid, struct vidbuffer *buf); @@ -169,9 +169,8 @@ struct linestate int bpl1dat_trigger_offset; int internal_pixel_cnt; int internal_pixel_start_cnt; + bool blankedline; int fetchmode_size, fetchstart_mask; - int ltsidx; - bool vb; uae_u16 strobe; int strobe_pos; }; @@ -191,9 +190,8 @@ void denise_reset(bool); bool denise_update_reg_queued(uae_u16 reg, uae_u16 v, uae_u32 cycle); void denise_store_registers(void); void denise_restore_registers(void); -void denise_set_line(int gfx_ypos); -void denise_mark_last_line(void); bool denise_is_vb(void); +void draw_denise_vsync_queue(int); void draw_denise_line_queue_flush(void); void quick_denise_rga_queue(int linecnt, int startpos, int endpos); void denise_handle_quick_strobe_queue(uae_u16 strobe, int strobe_pos, int endpos); diff --git a/linetoscr_aga_fast.cpp b/linetoscr_aga_fast.cpp index 0769aee8..648c35ce 100644 --- a/linetoscr_aga_fast.cpp +++ b/linetoscr_aga_fast.cpp @@ -26,7 +26,7 @@ static void lts_aga_n_ilores_dlores_b1(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -73,7 +73,7 @@ static void lts_aga_dpf_ilores_dlores_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -126,7 +126,7 @@ static void lts_aga_ehb_ilores_dlores_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -178,7 +178,7 @@ static void lts_aga_ham_ilores_dlores_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -224,7 +224,7 @@ static void lts_aga_kehb_ilores_dlores_b1(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -271,7 +271,7 @@ static void lts_aga_n_ihires_dlores_b1(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -318,7 +318,7 @@ static void lts_aga_dpf_ihires_dlores_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -371,7 +371,7 @@ static void lts_aga_ehb_ihires_dlores_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -423,7 +423,7 @@ static void lts_aga_ham_ihires_dlores_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -469,7 +469,7 @@ static void lts_aga_kehb_ihires_dlores_b1(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -536,7 +536,7 @@ static void lts_aga_n_ilores_dhires_b1(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -590,7 +590,7 @@ static void lts_aga_dpf_ilores_dhires_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -656,7 +656,7 @@ static void lts_aga_ehb_ilores_dhires_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -720,7 +720,7 @@ static void lts_aga_ham_ilores_dhires_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -772,7 +772,7 @@ static void lts_aga_kehb_ilores_dhires_b1(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -826,7 +826,7 @@ static void lts_aga_n_ihires_dhires_b1(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -873,7 +873,7 @@ static void lts_aga_dpf_ihires_dhires_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -926,7 +926,7 @@ static void lts_aga_ehb_ihires_dhires_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -978,7 +978,7 @@ static void lts_aga_ham_ihires_dhires_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1024,7 +1024,7 @@ static void lts_aga_kehb_ihires_dhires_b1(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1071,7 +1071,7 @@ static void lts_aga_n_ishres_dhires_b1(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1118,7 +1118,7 @@ static void lts_aga_dpf_ishres_dhires_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1171,7 +1171,7 @@ static void lts_aga_ehb_ishres_dhires_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1223,7 +1223,7 @@ static void lts_aga_ham_ishres_dhires_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1269,7 +1269,7 @@ static void lts_aga_kehb_ishres_dhires_b1(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1316,7 +1316,7 @@ static void lts_aga_n_ilores_dshres_b1(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -1384,7 +1384,7 @@ static void lts_aga_dpf_ilores_dshres_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -1476,7 +1476,7 @@ static void lts_aga_ehb_ilores_dshres_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -1564,7 +1564,7 @@ static void lts_aga_ham_ilores_dshres_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -1628,7 +1628,7 @@ static void lts_aga_kehb_ilores_dshres_b1(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -1696,7 +1696,7 @@ static void lts_aga_n_ihires_dshres_b1(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -1750,7 +1750,7 @@ static void lts_aga_dpf_ihires_dshres_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -1816,7 +1816,7 @@ static void lts_aga_ehb_ihires_dshres_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -1880,7 +1880,7 @@ static void lts_aga_ham_ihires_dshres_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -1932,7 +1932,7 @@ static void lts_aga_kehb_ihires_dshres_b1(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -1986,7 +1986,7 @@ static void lts_aga_n_ishres_dshres_b1(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2033,7 +2033,7 @@ static void lts_aga_dpf_ishres_dshres_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2086,7 +2086,7 @@ static void lts_aga_ehb_ishres_dshres_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2138,7 +2138,7 @@ static void lts_aga_ham_ishres_dshres_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2184,7 +2184,7 @@ static void lts_aga_kehb_ishres_dshres_b1(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2231,7 +2231,7 @@ static void lts_aga_n_ilores_dlores_b2(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2281,7 +2281,7 @@ static void lts_aga_dpf_ilores_dlores_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2337,7 +2337,7 @@ static void lts_aga_ehb_ilores_dlores_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2392,7 +2392,7 @@ static void lts_aga_ham_ilores_dlores_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2441,7 +2441,7 @@ static void lts_aga_kehb_ilores_dlores_b2(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2491,7 +2491,7 @@ static void lts_aga_n_ihires_dlores_b2(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2541,7 +2541,7 @@ static void lts_aga_dpf_ihires_dlores_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2597,7 +2597,7 @@ static void lts_aga_ehb_ihires_dlores_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2652,7 +2652,7 @@ static void lts_aga_ham_ihires_dlores_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2701,7 +2701,7 @@ static void lts_aga_kehb_ihires_dlores_b2(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2771,7 +2771,7 @@ static void lts_aga_n_ilores_dhires_b2(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -2830,7 +2830,7 @@ static void lts_aga_dpf_ilores_dhires_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -2901,7 +2901,7 @@ static void lts_aga_ehb_ilores_dhires_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -2970,7 +2970,7 @@ static void lts_aga_ham_ilores_dhires_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -3027,7 +3027,7 @@ static void lts_aga_kehb_ilores_dhires_b2(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -3086,7 +3086,7 @@ static void lts_aga_n_ihires_dhires_b2(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3136,7 +3136,7 @@ static void lts_aga_dpf_ihires_dhires_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3192,7 +3192,7 @@ static void lts_aga_ehb_ihires_dhires_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3247,7 +3247,7 @@ static void lts_aga_ham_ihires_dhires_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3296,7 +3296,7 @@ static void lts_aga_kehb_ihires_dhires_b2(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3346,7 +3346,7 @@ static void lts_aga_n_ishres_dhires_b2(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3396,7 +3396,7 @@ static void lts_aga_dpf_ishres_dhires_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3452,7 +3452,7 @@ static void lts_aga_ehb_ishres_dhires_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3507,7 +3507,7 @@ static void lts_aga_ham_ishres_dhires_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3556,7 +3556,7 @@ static void lts_aga_kehb_ishres_dhires_b2(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3606,7 +3606,7 @@ static void lts_aga_n_ilores_dshres_b2(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -3683,7 +3683,7 @@ static void lts_aga_dpf_ilores_dshres_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -3784,7 +3784,7 @@ static void lts_aga_ehb_ilores_dshres_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -3881,7 +3881,7 @@ static void lts_aga_ham_ilores_dshres_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -3954,7 +3954,7 @@ static void lts_aga_kehb_ilores_dshres_b2(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -4031,7 +4031,7 @@ static void lts_aga_n_ihires_dshres_b2(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -4090,7 +4090,7 @@ static void lts_aga_dpf_ihires_dshres_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -4161,7 +4161,7 @@ static void lts_aga_ehb_ihires_dshres_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -4230,7 +4230,7 @@ static void lts_aga_ham_ihires_dshres_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -4287,7 +4287,7 @@ static void lts_aga_kehb_ihires_dshres_b2(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -4346,7 +4346,7 @@ static void lts_aga_n_ishres_dshres_b2(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -4396,7 +4396,7 @@ static void lts_aga_dpf_ishres_dshres_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -4452,7 +4452,7 @@ static void lts_aga_ehb_ishres_dshres_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -4507,7 +4507,7 @@ static void lts_aga_ham_ishres_dshres_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -4556,7 +4556,7 @@ static void lts_aga_kehb_ishres_dshres_b2(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; diff --git a/linetoscr_aga_genlock_fast.cpp b/linetoscr_aga_genlock_fast.cpp index 2a79ffd2..f503781e 100644 --- a/linetoscr_aga_genlock_fast.cpp +++ b/linetoscr_aga_genlock_fast.cpp @@ -27,7 +27,7 @@ static void lts_aga_n_ilores_dlores_b1_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -79,7 +79,7 @@ static void lts_aga_dpf_ilores_dlores_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -137,7 +137,7 @@ static void lts_aga_ehb_ilores_dlores_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -194,7 +194,7 @@ static void lts_aga_ham_ilores_dlores_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -245,7 +245,7 @@ static void lts_aga_kehb_ilores_dlores_b1_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -297,7 +297,7 @@ static void lts_aga_n_ihires_dlores_b1_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -349,7 +349,7 @@ static void lts_aga_dpf_ihires_dlores_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -407,7 +407,7 @@ static void lts_aga_ehb_ihires_dlores_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -464,7 +464,7 @@ static void lts_aga_ham_ihires_dlores_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -515,7 +515,7 @@ static void lts_aga_kehb_ihires_dlores_b1_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -587,7 +587,7 @@ static void lts_aga_n_ilores_dhires_b1_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -649,7 +649,7 @@ static void lts_aga_dpf_ilores_dhires_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -723,7 +723,7 @@ static void lts_aga_ehb_ilores_dhires_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -795,7 +795,7 @@ static void lts_aga_ham_ilores_dhires_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -855,7 +855,7 @@ static void lts_aga_kehb_ilores_dhires_b1_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -917,7 +917,7 @@ static void lts_aga_n_ihires_dhires_b1_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -969,7 +969,7 @@ static void lts_aga_dpf_ihires_dhires_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1027,7 +1027,7 @@ static void lts_aga_ehb_ihires_dhires_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1084,7 +1084,7 @@ static void lts_aga_ham_ihires_dhires_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1135,7 +1135,7 @@ static void lts_aga_kehb_ihires_dhires_b1_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1187,7 +1187,7 @@ static void lts_aga_n_ishres_dhires_b1_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1239,7 +1239,7 @@ static void lts_aga_dpf_ishres_dhires_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1297,7 +1297,7 @@ static void lts_aga_ehb_ishres_dhires_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1354,7 +1354,7 @@ static void lts_aga_ham_ishres_dhires_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1405,7 +1405,7 @@ static void lts_aga_kehb_ishres_dhires_b1_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1457,7 +1457,7 @@ static void lts_aga_n_ilores_dshres_b1_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -1539,7 +1539,7 @@ static void lts_aga_dpf_ilores_dshres_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -1645,7 +1645,7 @@ static void lts_aga_ehb_ilores_dshres_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -1747,7 +1747,7 @@ static void lts_aga_ham_ilores_dshres_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -1825,7 +1825,7 @@ static void lts_aga_kehb_ilores_dshres_b1_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -1907,7 +1907,7 @@ static void lts_aga_n_ihires_dshres_b1_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -1969,7 +1969,7 @@ static void lts_aga_dpf_ihires_dshres_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -2043,7 +2043,7 @@ static void lts_aga_ehb_ihires_dshres_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -2115,7 +2115,7 @@ static void lts_aga_ham_ihires_dshres_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -2175,7 +2175,7 @@ static void lts_aga_kehb_ihires_dshres_b1_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -2237,7 +2237,7 @@ static void lts_aga_n_ishres_dshres_b1_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2289,7 +2289,7 @@ static void lts_aga_dpf_ishres_dshres_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2347,7 +2347,7 @@ static void lts_aga_ehb_ishres_dshres_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2404,7 +2404,7 @@ static void lts_aga_ham_ishres_dshres_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2455,7 +2455,7 @@ static void lts_aga_kehb_ishres_dshres_b1_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2507,7 +2507,7 @@ static void lts_aga_n_ilores_dlores_b2_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2562,7 +2562,7 @@ static void lts_aga_dpf_ilores_dlores_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2623,7 +2623,7 @@ static void lts_aga_ehb_ilores_dlores_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2683,7 +2683,7 @@ static void lts_aga_ham_ilores_dlores_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2737,7 +2737,7 @@ static void lts_aga_kehb_ilores_dlores_b2_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2792,7 +2792,7 @@ static void lts_aga_n_ihires_dlores_b2_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2847,7 +2847,7 @@ static void lts_aga_dpf_ihires_dlores_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2908,7 +2908,7 @@ static void lts_aga_ehb_ihires_dlores_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2968,7 +2968,7 @@ static void lts_aga_ham_ihires_dlores_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3022,7 +3022,7 @@ static void lts_aga_kehb_ihires_dlores_b2_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3097,7 +3097,7 @@ static void lts_aga_n_ilores_dhires_b2_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -3164,7 +3164,7 @@ static void lts_aga_dpf_ilores_dhires_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -3243,7 +3243,7 @@ static void lts_aga_ehb_ilores_dhires_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -3320,7 +3320,7 @@ static void lts_aga_ham_ilores_dhires_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -3385,7 +3385,7 @@ static void lts_aga_kehb_ilores_dhires_b2_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -3452,7 +3452,7 @@ static void lts_aga_n_ihires_dhires_b2_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3507,7 +3507,7 @@ static void lts_aga_dpf_ihires_dhires_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3568,7 +3568,7 @@ static void lts_aga_ehb_ihires_dhires_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3628,7 +3628,7 @@ static void lts_aga_ham_ihires_dhires_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3682,7 +3682,7 @@ static void lts_aga_kehb_ihires_dhires_b2_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3737,7 +3737,7 @@ static void lts_aga_n_ishres_dhires_b2_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3792,7 +3792,7 @@ static void lts_aga_dpf_ishres_dhires_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3853,7 +3853,7 @@ static void lts_aga_ehb_ishres_dhires_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3913,7 +3913,7 @@ static void lts_aga_ham_ishres_dhires_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3967,7 +3967,7 @@ static void lts_aga_kehb_ishres_dhires_b2_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -4022,7 +4022,7 @@ static void lts_aga_n_ilores_dshres_b2_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -4113,7 +4113,7 @@ static void lts_aga_dpf_ilores_dshres_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -4228,7 +4228,7 @@ static void lts_aga_ehb_ilores_dshres_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -4339,7 +4339,7 @@ static void lts_aga_ham_ilores_dshres_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -4426,7 +4426,7 @@ static void lts_aga_kehb_ilores_dshres_b2_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -4517,7 +4517,7 @@ static void lts_aga_n_ihires_dshres_b2_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -4584,7 +4584,7 @@ static void lts_aga_dpf_ihires_dshres_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -4663,7 +4663,7 @@ static void lts_aga_ehb_ihires_dshres_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -4740,7 +4740,7 @@ static void lts_aga_ham_ihires_dshres_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -4805,7 +4805,7 @@ static void lts_aga_kehb_ihires_dshres_b2_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -4872,7 +4872,7 @@ static void lts_aga_n_ishres_dshres_b2_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -4927,7 +4927,7 @@ static void lts_aga_dpf_ishres_dshres_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -4988,7 +4988,7 @@ static void lts_aga_ehb_ishres_dshres_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -5048,7 +5048,7 @@ static void lts_aga_ham_ishres_dshres_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -5102,7 +5102,7 @@ static void lts_aga_kehb_ishres_dshres_b2_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; diff --git a/linetoscr_ecs_fast.cpp b/linetoscr_ecs_fast.cpp index 54b3d363..10845e6e 100644 --- a/linetoscr_ecs_fast.cpp +++ b/linetoscr_ecs_fast.cpp @@ -25,7 +25,7 @@ static void lts_ecs_n_ilores_dlores_b1(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -70,7 +70,7 @@ static void lts_ecs_dpf_ilores_dlores_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -118,7 +118,7 @@ static void lts_ecs_ehb_ilores_dlores_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -168,7 +168,7 @@ static void lts_ecs_ham_ilores_dlores_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -213,7 +213,7 @@ static void lts_ecs_kehb_ilores_dlores_b1(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -258,7 +258,7 @@ static void lts_ecs_n_ihires_dlores_b1(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -303,7 +303,7 @@ static void lts_ecs_dpf_ihires_dlores_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -351,7 +351,7 @@ static void lts_ecs_ehb_ihires_dlores_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -401,7 +401,7 @@ static void lts_ecs_ham_ihires_dlores_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -446,7 +446,7 @@ static void lts_ecs_kehb_ihires_dlores_b1(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -511,7 +511,7 @@ static void lts_ecs_n_ilores_dhires_b1(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -561,7 +561,7 @@ static void lts_ecs_dpf_ilores_dhires_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -617,7 +617,7 @@ static void lts_ecs_ehb_ilores_dhires_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -677,7 +677,7 @@ static void lts_ecs_ham_ilores_dhires_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -727,7 +727,7 @@ static void lts_ecs_kehb_ilores_dhires_b1(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -777,7 +777,7 @@ static void lts_ecs_n_ihires_dhires_b1(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -822,7 +822,7 @@ static void lts_ecs_dpf_ihires_dhires_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -870,7 +870,7 @@ static void lts_ecs_ehb_ihires_dhires_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -920,7 +920,7 @@ static void lts_ecs_ham_ihires_dhires_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -965,7 +965,7 @@ static void lts_ecs_kehb_ihires_dhires_b1(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1010,7 +1010,7 @@ static void lts_ecs_n_ishres_dhires_b1(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1053,7 +1053,7 @@ static void lts_ecs_dpf_ishres_dhires_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1096,7 +1096,7 @@ static void lts_ecs_ehb_ishres_dhires_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1139,7 +1139,7 @@ static void lts_ecs_ham_ishres_dhires_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1182,7 +1182,7 @@ static void lts_ecs_kehb_ishres_dhires_b1(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1225,7 +1225,7 @@ static void lts_ecs_n_ilores_dshres_b1(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -1285,7 +1285,7 @@ static void lts_ecs_dpf_ilores_dshres_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -1357,7 +1357,7 @@ static void lts_ecs_ehb_ilores_dshres_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -1437,7 +1437,7 @@ static void lts_ecs_ham_ilores_dshres_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -1497,7 +1497,7 @@ static void lts_ecs_kehb_ilores_dshres_b1(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -1557,7 +1557,7 @@ static void lts_ecs_n_ihires_dshres_b1(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -1607,7 +1607,7 @@ static void lts_ecs_dpf_ihires_dshres_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -1663,7 +1663,7 @@ static void lts_ecs_ehb_ihires_dshres_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -1723,7 +1723,7 @@ static void lts_ecs_ham_ihires_dshres_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -1773,7 +1773,7 @@ static void lts_ecs_kehb_ihires_dshres_b1(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -1823,7 +1823,7 @@ static void lts_ecs_n_ishres_dshres_b1(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1868,7 +1868,7 @@ static void lts_ecs_dpf_ishres_dshres_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1913,7 +1913,7 @@ static void lts_ecs_ehb_ishres_dshres_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1958,7 +1958,7 @@ static void lts_ecs_ham_ishres_dshres_b1(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2003,7 +2003,7 @@ static void lts_ecs_kehb_ishres_dshres_b1(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2048,7 +2048,7 @@ static void lts_ecs_n_ilores_dlores_b2(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2096,7 +2096,7 @@ static void lts_ecs_dpf_ilores_dlores_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2147,7 +2147,7 @@ static void lts_ecs_ehb_ilores_dlores_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2200,7 +2200,7 @@ static void lts_ecs_ham_ilores_dlores_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2248,7 +2248,7 @@ static void lts_ecs_kehb_ilores_dlores_b2(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2296,7 +2296,7 @@ static void lts_ecs_n_ihires_dlores_b2(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2344,7 +2344,7 @@ static void lts_ecs_dpf_ihires_dlores_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2395,7 +2395,7 @@ static void lts_ecs_ehb_ihires_dlores_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2448,7 +2448,7 @@ static void lts_ecs_ham_ihires_dlores_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2496,7 +2496,7 @@ static void lts_ecs_kehb_ihires_dlores_b2(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2564,7 +2564,7 @@ static void lts_ecs_n_ilores_dhires_b2(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -2619,7 +2619,7 @@ static void lts_ecs_dpf_ilores_dhires_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -2680,7 +2680,7 @@ static void lts_ecs_ehb_ilores_dhires_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -2745,7 +2745,7 @@ static void lts_ecs_ham_ilores_dhires_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -2800,7 +2800,7 @@ static void lts_ecs_kehb_ilores_dhires_b2(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -2855,7 +2855,7 @@ static void lts_ecs_n_ihires_dhires_b2(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2903,7 +2903,7 @@ static void lts_ecs_dpf_ihires_dhires_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2954,7 +2954,7 @@ static void lts_ecs_ehb_ihires_dhires_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3007,7 +3007,7 @@ static void lts_ecs_ham_ihires_dhires_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3055,7 +3055,7 @@ static void lts_ecs_kehb_ihires_dhires_b2(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3103,7 +3103,7 @@ static void lts_ecs_n_ishres_dhires_b2(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3149,7 +3149,7 @@ static void lts_ecs_dpf_ishres_dhires_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3195,7 +3195,7 @@ static void lts_ecs_ehb_ishres_dhires_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3241,7 +3241,7 @@ static void lts_ecs_ham_ishres_dhires_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3287,7 +3287,7 @@ static void lts_ecs_kehb_ishres_dhires_b2(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3333,7 +3333,7 @@ static void lts_ecs_n_ilores_dshres_b2(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -3402,7 +3402,7 @@ static void lts_ecs_dpf_ilores_dshres_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -3483,7 +3483,7 @@ static void lts_ecs_ehb_ilores_dshres_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -3572,7 +3572,7 @@ static void lts_ecs_ham_ilores_dshres_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -3641,7 +3641,7 @@ static void lts_ecs_kehb_ilores_dshres_b2(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -3710,7 +3710,7 @@ static void lts_ecs_n_ihires_dshres_b2(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -3765,7 +3765,7 @@ static void lts_ecs_dpf_ihires_dshres_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -3826,7 +3826,7 @@ static void lts_ecs_ehb_ihires_dshres_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -3891,7 +3891,7 @@ static void lts_ecs_ham_ihires_dshres_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -3946,7 +3946,7 @@ static void lts_ecs_kehb_ihires_dshres_b2(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -4001,7 +4001,7 @@ static void lts_ecs_n_ishres_dshres_b2(int draw_start, int draw_end, int draw_st } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -4050,7 +4050,7 @@ static void lts_ecs_dpf_ishres_dshres_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -4099,7 +4099,7 @@ static void lts_ecs_ehb_ishres_dshres_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -4148,7 +4148,7 @@ static void lts_ecs_ham_ishres_dshres_b2(int draw_start, int draw_end, int draw_ } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -4197,7 +4197,7 @@ static void lts_ecs_kehb_ishres_dshres_b2(int draw_start, int draw_end, int draw } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; diff --git a/linetoscr_ecs_genlock_fast.cpp b/linetoscr_ecs_genlock_fast.cpp index cfcfe650..254451bb 100644 --- a/linetoscr_ecs_genlock_fast.cpp +++ b/linetoscr_ecs_genlock_fast.cpp @@ -26,7 +26,7 @@ static void lts_ecs_n_ilores_dlores_b1_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -76,7 +76,7 @@ static void lts_ecs_dpf_ilores_dlores_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -129,7 +129,7 @@ static void lts_ecs_ehb_ilores_dlores_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -184,7 +184,7 @@ static void lts_ecs_ham_ilores_dlores_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -234,7 +234,7 @@ static void lts_ecs_kehb_ilores_dlores_b1_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -284,7 +284,7 @@ static void lts_ecs_n_ihires_dlores_b1_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -334,7 +334,7 @@ static void lts_ecs_dpf_ihires_dlores_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -387,7 +387,7 @@ static void lts_ecs_ehb_ihires_dlores_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -442,7 +442,7 @@ static void lts_ecs_ham_ihires_dlores_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -492,7 +492,7 @@ static void lts_ecs_kehb_ihires_dlores_b1_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -562,7 +562,7 @@ static void lts_ecs_n_ilores_dhires_b1_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -620,7 +620,7 @@ static void lts_ecs_dpf_ilores_dhires_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -684,7 +684,7 @@ static void lts_ecs_ehb_ilores_dhires_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -752,7 +752,7 @@ static void lts_ecs_ham_ilores_dhires_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -810,7 +810,7 @@ static void lts_ecs_kehb_ilores_dhires_b1_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -868,7 +868,7 @@ static void lts_ecs_n_ihires_dhires_b1_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -918,7 +918,7 @@ static void lts_ecs_dpf_ihires_dhires_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -971,7 +971,7 @@ static void lts_ecs_ehb_ihires_dhires_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1026,7 +1026,7 @@ static void lts_ecs_ham_ihires_dhires_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1076,7 +1076,7 @@ static void lts_ecs_kehb_ihires_dhires_b1_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1126,7 +1126,7 @@ static void lts_ecs_n_ishres_dhires_b1_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1174,7 +1174,7 @@ static void lts_ecs_dpf_ishres_dhires_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1222,7 +1222,7 @@ static void lts_ecs_ehb_ishres_dhires_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1270,7 +1270,7 @@ static void lts_ecs_ham_ishres_dhires_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1318,7 +1318,7 @@ static void lts_ecs_kehb_ishres_dhires_b1_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -1366,7 +1366,7 @@ static void lts_ecs_n_ilores_dshres_b1_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -1440,7 +1440,7 @@ static void lts_ecs_dpf_ilores_dshres_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -1526,7 +1526,7 @@ static void lts_ecs_ehb_ilores_dshres_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -1620,7 +1620,7 @@ static void lts_ecs_ham_ilores_dshres_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -1694,7 +1694,7 @@ static void lts_ecs_kehb_ilores_dshres_b1_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -1768,7 +1768,7 @@ static void lts_ecs_n_ihires_dshres_b1_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -1826,7 +1826,7 @@ static void lts_ecs_dpf_ihires_dshres_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -1890,7 +1890,7 @@ static void lts_ecs_ehb_ihires_dshres_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -1958,7 +1958,7 @@ static void lts_ecs_ham_ihires_dshres_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -2016,7 +2016,7 @@ static void lts_ecs_kehb_ihires_dshres_b1_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -2074,7 +2074,7 @@ static void lts_ecs_n_ishres_dshres_b1_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2125,7 +2125,7 @@ static void lts_ecs_dpf_ishres_dshres_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2176,7 +2176,7 @@ static void lts_ecs_ehb_ishres_dshres_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2227,7 +2227,7 @@ static void lts_ecs_ham_ishres_dshres_b1_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2278,7 +2278,7 @@ static void lts_ecs_kehb_ishres_dshres_b1_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2329,7 +2329,7 @@ static void lts_ecs_n_ilores_dlores_b2_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2382,7 +2382,7 @@ static void lts_ecs_dpf_ilores_dlores_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2438,7 +2438,7 @@ static void lts_ecs_ehb_ilores_dlores_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2496,7 +2496,7 @@ static void lts_ecs_ham_ilores_dlores_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2549,7 +2549,7 @@ static void lts_ecs_kehb_ilores_dlores_b2_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2602,7 +2602,7 @@ static void lts_ecs_n_ihires_dlores_b2_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2655,7 +2655,7 @@ static void lts_ecs_dpf_ihires_dlores_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2711,7 +2711,7 @@ static void lts_ecs_ehb_ihires_dlores_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2769,7 +2769,7 @@ static void lts_ecs_ham_ihires_dlores_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2822,7 +2822,7 @@ static void lts_ecs_kehb_ihires_dlores_b2_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -2895,7 +2895,7 @@ static void lts_ecs_n_ilores_dhires_b2_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -2958,7 +2958,7 @@ static void lts_ecs_dpf_ilores_dhires_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -3027,7 +3027,7 @@ static void lts_ecs_ehb_ilores_dhires_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -3100,7 +3100,7 @@ static void lts_ecs_ham_ilores_dhires_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -3163,7 +3163,7 @@ static void lts_ecs_kehb_ilores_dhires_b2_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -3226,7 +3226,7 @@ static void lts_ecs_n_ihires_dhires_b2_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3279,7 +3279,7 @@ static void lts_ecs_dpf_ihires_dhires_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3335,7 +3335,7 @@ static void lts_ecs_ehb_ihires_dhires_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3393,7 +3393,7 @@ static void lts_ecs_ham_ihires_dhires_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3446,7 +3446,7 @@ static void lts_ecs_kehb_ihires_dhires_b2_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3499,7 +3499,7 @@ static void lts_ecs_n_ishres_dhires_b2_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3550,7 +3550,7 @@ static void lts_ecs_dpf_ishres_dhires_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3601,7 +3601,7 @@ static void lts_ecs_ehb_ishres_dhires_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3652,7 +3652,7 @@ static void lts_ecs_ham_ishres_dhires_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3703,7 +3703,7 @@ static void lts_ecs_kehb_ishres_dhires_b2_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -3754,7 +3754,7 @@ static void lts_ecs_n_ilores_dshres_b2_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -3837,7 +3837,7 @@ static void lts_ecs_dpf_ilores_dshres_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -3932,7 +3932,7 @@ static void lts_ecs_ehb_ilores_dshres_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -4035,7 +4035,7 @@ static void lts_ecs_ham_ilores_dshres_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -4118,7 +4118,7 @@ static void lts_ecs_kehb_ilores_dshres_b2_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 4; @@ -4201,7 +4201,7 @@ static void lts_ecs_n_ihires_dshres_b2_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -4264,7 +4264,7 @@ static void lts_ecs_dpf_ihires_dshres_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -4333,7 +4333,7 @@ static void lts_ecs_ehb_ihires_dshres_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -4406,7 +4406,7 @@ static void lts_ecs_ham_ihires_dshres_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -4469,7 +4469,7 @@ static void lts_ecs_kehb_ihires_dshres_b2_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1 += 2; @@ -4532,7 +4532,7 @@ static void lts_ecs_n_ishres_dshres_b2_genlock(int draw_start, int draw_end, int } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -4587,7 +4587,7 @@ static void lts_ecs_dpf_ishres_dshres_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -4642,7 +4642,7 @@ static void lts_ecs_ehb_ishres_dshres_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -4697,7 +4697,7 @@ static void lts_ecs_ham_ishres_dshres_b2_genlock(int draw_start, int draw_end, i } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; @@ -4752,7 +4752,7 @@ static void lts_ecs_kehb_ishres_dshres_b2_genlock(int draw_start, int draw_end, } while (cnt < end) { bool bpl = false; - if (cnt < bpl1dat_trigger_offset || cnt < hstrt_offset || cnt >= hstop_offset) { + if (cnt < bpl1dat_trigger_offset || cnt < hbstop_offset || cnt < hstrt_offset || cnt >= hstop_offset) { if (cnt >= draw_startoffset) { if (cnt < hbstop_offset) { buf1++; -- 2.47.3