From 958053ff56109a38e9f8e0a0aa8786a5f47adb7c Mon Sep 17 00:00:00 2001 From: wm4 Date: Sun, 29 Apr 2018 16:07:21 +0200 Subject: vo_lavc: explicitly skip redraw and repeated frames The user won't want to have those in the video (I think). The core can sporadically issue redraws, which is what you want for actual playback, but not in encode mode. vo_lavc can explicitly detect those and skip them. It only requires switching to a more advanced internal VO API. The comments in vo.h are because vo_lavc draws to one of the images in order to render OSD. This is OK, but might come as a surprise to whoever calls draw_frame, so document it. (Current callers are OK with it.) --- video/out/vo.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'video/out/vo.h') diff --git a/video/out/vo.h b/video/out/vo.h index 851dd16159..17cb692356 100644 --- a/video/out/vo.h +++ b/video/out/vo.h @@ -354,6 +354,9 @@ struct vo_driver { /* Render the given frame. Note that this is also called when repeating * or redrawing frames. + * + * frame is freed by the caller, but the callee can still modify the + * contained data and references. */ void (*draw_frame)(struct vo *vo, struct vo_frame *frame); -- cgit v1.2.3