diff options
Diffstat (limited to 'video/out/vo_tct.c')
-rw-r--r-- | video/out/vo_tct.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/video/out/vo_tct.c b/video/out/vo_tct.c index af7c7ffd48..8859095fa3 100644 --- a/video/out/vo_tct.c +++ b/video/out/vo_tct.c @@ -242,13 +242,14 @@ static int reconfig(struct vo *vo, struct mp_image_params *params) return 0; } -static void draw_image(struct vo *vo, mp_image_t *mpi) +static void draw_frame(struct vo *vo, struct vo_frame *frame) { struct priv *p = vo->priv; - struct mp_image src = *mpi; + struct mp_image *src = frame->current; + if (!src) + return; // XXX: pan, crop etc. - mp_sws_scale(p->sws, p->frame, &src); - talloc_free(mpi); + mp_sws_scale(p->sws, p->frame, src); } static void flip_page(struct vo *vo) @@ -326,7 +327,7 @@ const struct vo_driver video_out_tct = { .query_format = query_format, .reconfig = reconfig, .control = control, - .draw_image = draw_image, + .draw_frame = draw_frame, .flip_page = flip_page, .uninit = uninit, .priv_size = sizeof(struct priv), |