@ -73,8 +73,7 @@ int normal_demo(struct notcurses* nc){
}
free(rgba);
rgba = NULL;
// FIXME ncvisual_from_plane is failing
/*ncv = ncvisual_from_plane(n, 0, 0, -1, -1);
ncv = ncvisual_from_plane(n, 0, 0, -1, -1);
if(!ncv){
goto err;
@ -86,7 +85,7 @@ int normal_demo(struct notcurses* nc){
DEMO_RENDER(nc);
}*/
ncvisual_destroy(ncv);
ncplane_destroy(n);
return 0;
@ -113,6 +113,12 @@ auto ncvisual_from_plane(const ncplane* n, int begy, int begx, int leny, int len
int dimy, dimx;
ncplane_dim_yx(n, &dimy, &dimx);
if(lenx == -1){
lenx = n->lenx - begx;
if(leny == -1){
leny = n->leny - begy;
auto* ncv = ncvisual_from_rgba(n->nc, rgba, leny, lenx * 4, lenx);
if(ncv == nullptr){