From 5e9f7916674c4640707727eac80c659290492bad Mon Sep 17 00:00:00 2001 From: wm4 Date: Fri, 23 Jan 2015 22:06:12 +0100 Subject: video: separate screenshot modes Use different VOCTRLs for "window" and normal screenshot modes. The normal one will probably be removed, and replaced by generic code in vo.c, and this commit is preparation for this. (Doing it the other way around would be slightly simpler, but I haven't decided yet about the second one, and touching every VO is needed anyway in order to remove the unneeded crap. E.g. has_osd has been unused for a long time.) --- video/out/vo_xv.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'video/out/vo_xv.c') diff --git a/video/out/vo_xv.c b/video/out/vo_xv.c index 202ba13735..e506fc9359 100644 --- a/video/out/vo_xv.c +++ b/video/out/vo_xv.c @@ -839,12 +839,10 @@ static int control(struct vo *vo, uint32_t request, void *data) case VOCTRL_REDRAW_FRAME: draw_image(vo, ctx->original_image); return true; - case VOCTRL_SCREENSHOT: { - struct voctrl_screenshot_args *args = data; - args->out_image = get_screenshot(vo); + case VOCTRL_SCREENSHOT: + *(struct mp_image **)data = get_screenshot(vo); return true; } - } int events = 0; int r = vo_x11_control(vo, &events, request, data); if (events & (VO_EVENT_EXPOSE | VO_EVENT_RESIZE)) -- cgit v1.2.3