diff options
author | wm4 <wm4@nowhere> | 2014-06-18 20:04:59 +0200 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2014-06-18 20:04:59 +0200 |
commit | 9accfe04265785b68ebfc50e0fb4dd3ebb62d4c2 (patch) | |
tree | 51b48de261874cd48e4e29b0a459eebb9b718cae /video/out/vo_xv.c | |
parent | 86e5f15592d2c732c03735f4aa7d6361ee0f20dd (diff) | |
download | mpv-9accfe04265785b68ebfc50e0fb4dd3ebb62d4c2.tar.bz2 mpv-9accfe04265785b68ebfc50e0fb4dd3ebb62d4c2.tar.xz |
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.
Diffstat (limited to 'video/out/vo_xv.c')
-rw-r--r-- | video/out/vo_xv.c | 15 |
1 files changed, 2 insertions, 13 deletions
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; |