vo_tct: add resize capability

No performance penalty added by getting the terminal size every frame.
This commit is contained in:
Cloud11665 2021-08-17 19:49:23 +02:00 committed by Philip Langdale
parent 91b6757875
commit f3a2275c24
1 changed files with 7 additions and 0 deletions

View File

@ -273,6 +273,13 @@ static void draw_image(struct vo *vo, mp_image_t *mpi)
static void flip_page(struct vo *vo)
{
struct priv *p = vo->priv;
int width, height;
get_win_size(vo, &width, &height);
if (vo->dwidth != width || vo->dheight != height)
reconfig(vo, vo->params);
if (p->opts->algo == ALGO_PLAIN) {
write_plain(
vo->dwidth, vo->dheight, p->swidth, p->sheight,