|
|
@ -811,13 +811,13 @@ int sixel_destroy(const notcurses* nc, const ncpile* p, FILE* out, sprixel* s){
|
|
|
|
int startx = s->movedfromx;
|
|
|
|
int startx = s->movedfromx;
|
|
|
|
for(int yy = starty ; yy < starty + s->dimy && yy < p->dimy ; ++yy){
|
|
|
|
for(int yy = starty ; yy < starty + s->dimy && yy < p->dimy ; ++yy){
|
|
|
|
for(int xx = startx ; xx < startx + s->dimx && xx < p->dimx ; ++xx){
|
|
|
|
for(int xx = startx ; xx < startx + s->dimx && xx < p->dimx ; ++xx){
|
|
|
|
int ridx = (yy - nc->margin_t) * p->dimx + (xx - nc->margin_l);
|
|
|
|
int ridx = yy * p->dimx + xx;
|
|
|
|
struct crender *r = &p->crender[ridx];
|
|
|
|
struct crender *r = &p->crender[ridx];
|
|
|
|
if(!r->sprixel){
|
|
|
|
if(!r->sprixel){
|
|
|
|
if(s->n){
|
|
|
|
if(s->n){
|
|
|
|
//fprintf(stderr, "CHECKING %d/%d\n", yy - s->movedfromy, xx - s->movedfromx);
|
|
|
|
//fprintf(stderr, "CHECKING %d/%d\n", yy - s->movedfromy, xx - s->movedfromx);
|
|
|
|
sprixcell_e state = sprixel_state(s, yy - s->movedfromy + s->n->absy - nc->margin_t,
|
|
|
|
sprixcell_e state = sprixel_state(s, yy - s->movedfromy + s->n->absy,
|
|
|
|
xx - s->movedfromx + s->n->absx - nc->margin_l);
|
|
|
|
xx - s->movedfromx + s->n->absx);
|
|
|
|
if(state == SPRIXCELL_OPAQUE_SIXEL || state == SPRIXCELL_MIXED_SIXEL){
|
|
|
|
if(state == SPRIXCELL_OPAQUE_SIXEL || state == SPRIXCELL_MIXED_SIXEL){
|
|
|
|
r->s.damaged = 1;
|
|
|
|
r->s.damaged = 1;
|
|
|
|
}else if(s->invalidated == SPRIXEL_MOVED){
|
|
|
|
}else if(s->invalidated == SPRIXEL_MOVED){
|
|
|
|