mirror of
https://github.com/dankamongmen/notcurses
synced 2025-03-10 09:39:03 -04:00
lookin' good atl
This commit is contained in:
parent
738c590bfd
commit
2aadd096c0
@ -240,7 +240,7 @@ handle_input(struct notcurses* nc, struct panelreel* pr, int efd,
|
|||||||
static struct panelreel*
|
static struct panelreel*
|
||||||
panelreel_demo_core(struct notcurses* nc, int efd, tabletctx** tctxs){
|
panelreel_demo_core(struct notcurses* nc, int efd, tabletctx** tctxs){
|
||||||
bool done = false;
|
bool done = false;
|
||||||
int x = 4, y = 4;
|
int x = 8, y = 8;
|
||||||
panelreel_options popts = {
|
panelreel_options popts = {
|
||||||
.infinitescroll = true,
|
.infinitescroll = true,
|
||||||
.circular = true,
|
.circular = true,
|
||||||
@ -251,8 +251,8 @@ panelreel_demo_core(struct notcurses* nc, int efd, tabletctx** tctxs){
|
|||||||
.focusedattr = CELL_TRIVIAL_INITIALIZER,
|
.focusedattr = CELL_TRIVIAL_INITIALIZER,
|
||||||
.toff = y,
|
.toff = y,
|
||||||
.loff = x,
|
.loff = x,
|
||||||
.roff = 0,
|
.roff = x,
|
||||||
.boff = 0,
|
.boff = y,
|
||||||
};
|
};
|
||||||
cell_set_fg(&popts.focusedattr, 58, 150, 221);
|
cell_set_fg(&popts.focusedattr, 58, 150, 221);
|
||||||
cell_set_bg(&popts.focusedattr, 97, 214, 214);
|
cell_set_bg(&popts.focusedattr, 97, 214, 214);
|
||||||
|
@ -7,10 +7,25 @@ view_video_demo(struct notcurses* nc){
|
|||||||
int dimy, dimx;
|
int dimy, dimx;
|
||||||
ncplane_dim_yx(ncp, &dimy, &dimx);
|
ncplane_dim_yx(ncp, &dimy, &dimx);
|
||||||
int averr;
|
int averr;
|
||||||
struct ncvisual* ncv = ncplane_visual_open(ncp, "../tests/atliens.mkv", &averr);
|
struct ncvisual* ncv;
|
||||||
if(ncvisual_stream(nc, ncv, &averr)){
|
ncv = ncplane_visual_open(ncp, "../tests/bob.mkv", &averr);
|
||||||
|
if(!ncv){
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
if(ncvisual_stream(nc, ncv, &averr)){
|
||||||
|
ncvisual_destroy(ncv);
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
ncvisual_destroy(ncv);
|
||||||
|
ncv = ncplane_visual_open(ncp, "../tests/atliens.mkv", &averr);
|
||||||
|
if(!ncv){
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
if(ncvisual_stream(nc, ncv, &averr)){
|
||||||
|
ncvisual_destroy(ncv);
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
ncvisual_destroy(ncv);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
BIN
tests/bob.mkv
Normal file
BIN
tests/bob.mkv
Normal file
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user