From 9accfe04265785b68ebfc50e0fb4dd3ebb62d4c2 Mon Sep 17 00:00:00 2001 From: wm4 Date: Wed, 18 Jun 2014 20:04:59 +0200 Subject: video/out: fix redrawing with no video frame for some VOs With the change to merge osd drawing into video frame drawing, some bogus logic got in: they skipped drawing the OSD if no video frame is available. This broke --no-video --force-window mode. --- video/out/vo_xv.c | 15 ++------------- 1 file changed, 2 insertions(+), 13 deletions(-) (limited to 'video/out/vo_xv.c') diff --git a/video/out/vo_xv.c b/video/out/vo_xv.c index 3e139b68b2..2150eb7fce 100644 --- a/video/out/vo_xv.c +++ b/video/out/vo_xv.c @@ -655,7 +655,7 @@ static mp_image_t *get_screenshot(struct vo *vo) return mp_image_new_ref(ctx->original_image); } -// Note: redraw_frame() can call this with NULL. +// Note: REDRAW_FRAME can call this with NULL. static void draw_image(struct vo *vo, mp_image_t *mpi) { struct xvctx *ctx = vo->priv; @@ -678,17 +678,6 @@ static void draw_image(struct vo *vo, mp_image_t *mpi) } } -static int redraw_frame(struct vo *vo) -{ - struct xvctx *ctx = vo->priv; - - if (!ctx->original_image) - return false; - - draw_image(vo, ctx->original_image); - return true; -} - static int query_format(struct vo *vo, uint32_t format) { struct xvctx *ctx = vo->priv; @@ -855,7 +844,7 @@ static int control(struct vo *vo, uint32_t request, void *data) return true; } case VOCTRL_REDRAW_FRAME: - redraw_frame(vo); + draw_image(vo, ctx->original_image); return true; case VOCTRL_SCREENSHOT: { struct voctrl_screenshot_args *args = data; -- cgit v1.2.3