summaryrefslogtreecommitdiffstats
path: root/libvo/video_out.h
diff options
context:
space:
mode:
authorUoti Urpala <uau@mplayer2.org>2011-12-05 05:24:18 +0200
committerUoti Urpala <uau@mplayer2.org>2011-12-06 05:03:39 +0200
commitad0348cf0a7459c0581deaf3ed7d8b73a12cc73f (patch)
tree206975ec6720a6d3605cc1b9d4c1a603898b3458 /libvo/video_out.h
parentc9553ce82fdb80811196f40b9c1eaaa3b2351e01 (diff)
downloadmpv-ad0348cf0a7459c0581deaf3ed7d8b73a12cc73f.tar.bz2
mpv-ad0348cf0a7459c0581deaf3ed7d8b73a12cc73f.tar.xz
core, vo: modify OSD redraw architecture, support EOSD
Previously the core sent VFCTRL_REDRAW_OSD to change OSD contents over the current frame. Change this to VFCTRL_REDRAW_FRAME followed by normal EOSD and OSD drawing calls, then vo_flip_page(). The new version supports changing EOSD contents for libass-rendered subtitles and simplifies the redraw support code needed per VO. vo_xv doesn't support EOSD changes because it relies on vf_ass to render EOSD contents earlier in the filter chain. vo_xv logic is additionally simplified because the previous commit removed the need to track the status of current and next images separately (now each frame is guaranteed to become "visible" soon after we receive it as "next", with no VO code running in the interval between).
Diffstat (limited to 'libvo/video_out.h')
-rw-r--r--libvo/video_out.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/libvo/video_out.h b/libvo/video_out.h
index a710f7de4a..032a32b1cc 100644
--- a/libvo/video_out.h
+++ b/libvo/video_out.h
@@ -65,7 +65,7 @@ enum mp_voctrl {
VOCTRL_NEWFRAME,
VOCTRL_SKIPFRAME,
- VOCTRL_REDRAW_OSD,
+ VOCTRL_REDRAW_FRAME,
VOCTRL_ONTOP,
VOCTRL_ROOTWIN,
@@ -263,6 +263,7 @@ struct vo {
struct mp_image *waiting_mpi;
double next_pts; // pts value of the next frame if any
double next_pts2; // optional pts of frame after that
+ bool redrawing; // between redrawing frame and flipping it
double flip_queue_offset; // queue flip events at most this much in advance
@@ -306,6 +307,7 @@ void list_video_out(void);
int vo_control(struct vo *vo, uint32_t request, void *data);
int vo_draw_image(struct vo *vo, struct mp_image *mpi, double pts);
+int vo_redraw_frame(struct vo *vo);
int vo_get_buffered_frame(struct vo *vo, bool eof);
void vo_skip_frame(struct vo *vo);
int vo_draw_frame(struct vo *vo, uint8_t *src[]);