From 10a1ae7b720b7b116c98f78d611c92923559620e Mon Sep 17 00:00:00 2001 From: wm4 Date: Wed, 21 Nov 2012 19:56:25 +0100 Subject: screenshot: add subs even with vf_screenshot Until now, screenshots with the video filter didn't add subs (unclear whether that was an oversight or feature). Fix this and make behavior when taking screenshots with vf_screenshot more consistent with VO screenshots. The change in vf_screenshot is needed, because add_subs() checks this flag to decide whether it's allowed to mutate the image. This commit has another user visible side effect. When taking a screenshot each frame (using the "each-frame" mode of the screenshot command), a normal screenshot command will stop the each-frame mode. --- video/filter/vf_screenshot.c | 1 + 1 file changed, 1 insertion(+) (limited to 'video') diff --git a/video/filter/vf_screenshot.c b/video/filter/vf_screenshot.c index e4ba696f69..bb5ca517a0 100644 --- a/video/filter/vf_screenshot.c +++ b/video/filter/vf_screenshot.c @@ -139,6 +139,7 @@ static int put_image(struct vf_instance *vf, mp_image_t *mpi, double pts) image = *dmpi; else image = *vf->priv->image; + image.flags &= ~MP_IMGFLAG_ALLOCATED; image.w = vf->priv->image->w; image.h = vf->priv->image->h; vf_clone_mpi_attributes(&image, mpi); -- cgit v1.2.3