From 2507a1712b602c8efb316584ab761d0ec24f09dc Mon Sep 17 00:00:00 2001 From: nick black Date: Tue, 2 Feb 2021 00:33:50 -0500 Subject: [PATCH] paint(): need blittedquads != 0 to stack blitters #1068 --- src/lib/render.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/lib/render.c b/src/lib/render.c index b53d577430..55a8b02f42 100644 --- a/src/lib/render.c +++ b/src/lib/render.c @@ -312,8 +312,11 @@ paint(const ncplane* p, struct crender* rvec, int dstleny, int dstlenx, // Evaluate the background first, in case we have HIGHCONTRAST fg text. if(cell_bg_alpha(targc) > CELL_ALPHA_OPAQUE){ const nccell* vis = &p->fb[nfbcellidx(p, y, x)]; -//fprintf(stderr, "y/x: %d/%d crenderbq: 0x%x visbq: 0x%x\n", y, x, crender->s.blittedquads, cell_blittedquadrants(vis)); - if(!((~crender->s.blittedquads) & cell_blittedquadrants(vis))){ + // to be on the blitter stacking path, we need + // 1) crender->s.blittedquads to be non-zero + // 2) cell_blittedquadrants(vis) to be non-zero + // 3) somewhere crender is 0, blittedquads is 1 + if(!crender->s.blittedquads || !((~crender->s.blittedquads) & cell_blittedquadrants(vis))){ if(cell_bg_default_p(vis)){ vis = &p->basecell; }