[fallin] undo changes which put background on top

pull/1480/head
nick black 3 years ago
parent c87992c452
commit 7127118d27
No known key found for this signature in database
GPG Key ID: 5F43400C21CBFACC

@ -183,44 +183,30 @@ int fallin_demo(struct notcurses* nc){
x += newx; x += newx;
} }
} }
struct ncplane* n = NULL; ncplane_erase(stdn);
#ifndef DFSG_BUILD #ifndef DFSG_BUILD
if(notcurses_canopen_images(nc)){ if(notcurses_canopen_images(nc)){
char* path = find_data("lamepatents.jpg"); char* path = find_data("lamepatents.jpg");
if(path == NULL){ struct ncvisual* ncv = ncvisual_from_file(path);
goto err; free(path);
} if(ncv == NULL){
struct ncvisual* ncv = ncvisual_from_file(path); goto err;
free(path); }
if(ncv == NULL){ struct ncvisual_options vopts = {
goto err; .n = stdn,
} .scaling = NCSCALE_STRETCH,
struct ncplane_options nopts = { };
.rows = dimy - 2, if(ncvisual_render(nc, ncv, &vopts) == NULL){
.cols = dimx,
.y = 1,
};
n = ncplane_create(stdn, &nopts);
if(n == NULL){
goto err;
}
struct ncvisual_options vopts = {
.scaling = NCSCALE_STRETCH,
//.blitter = NCBLIT_PIXEL,
.n = n,
};
if(ncvisual_render(nc, ncv, &vopts) == NULL){
ncvisual_destroy(ncv);
goto err;
}
assert(ncvisual_decode(ncv) == 1);
ncvisual_destroy(ncv); ncvisual_destroy(ncv);
goto err;
}
assert(ncvisual_decode(ncv) == 1);
ncvisual_destroy(ncv);
} }
#endif #endif
int ret = drop_bricks(nc, arr, arrcount); int ret = drop_bricks(nc, arr, arrcount);
free(arr); free(arr);
free(usemap); free(usemap);
ncplane_destroy(n);
return ret; return ret;
err: err:

Loading…
Cancel
Save