diff --git a/src/lib/visual.c b/src/lib/visual.c index 4dec619c3..cd63b5c16 100644 --- a/src/lib/visual.c +++ b/src/lib/visual.c @@ -159,12 +159,12 @@ ncvisual_blitset_geom(const notcurses* nc, const ncvisual* n, return -1; } int rows = (*leny + nc->tcache.cellpixy - 1) / nc->tcache.cellpixy; - if(rows > ncplane_dim_y(vopts->n)){ + if(rows > ncplane_dim_y(vopts->n) * nc->tcache.cellpixy){ logerror(nc, "Sprixel too tall %d for plane %d\n", *leny, ncplane_dim_y(vopts->n) * nc->tcache.cellpixy); return -1; } int cols = (*lenx + nc->tcache.cellpixx - 1) / nc->tcache.cellpixx; - if(cols > ncplane_dim_x(vopts->n)){ + if(cols > ncplane_dim_x(vopts->n) * nc->tcache.cellpixx){ logerror(nc, "Sprixel too wide %d for plane %d\n", *lenx, ncplane_dim_x(vopts->n) * nc->tcache.cellpixx); return -1; }