summaryrefslogtreecommitdiffstats
path: root/video
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2012-11-21 19:56:25 +0100
committerwm4 <wm4@nowhere>2012-11-21 19:58:51 +0100
commit10a1ae7b720b7b116c98f78d611c92923559620e (patch)
tree99c5a5bcef4a83689ed652f94cff342117db58d9 /video
parent4b91861b6710e9f82618b58841e08986e965eb43 (diff)
downloadmpv-10a1ae7b720b7b116c98f78d611c92923559620e.tar.bz2
mpv-10a1ae7b720b7b116c98f78d611c92923559620e.tar.xz
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.
Diffstat (limited to 'video')
-rw-r--r--video/filter/vf_screenshot.c1
1 files changed, 1 insertions, 0 deletions
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);