From ad0348cf0a7459c0581deaf3ed7d8b73a12cc73f Mon Sep 17 00:00:00 2001 From: Uoti Urpala Date: Mon, 5 Dec 2011 05:24:18 +0200 Subject: 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). --- libmpcodecs/vf_expand.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'libmpcodecs/vf_expand.c') diff --git a/libmpcodecs/vf_expand.c b/libmpcodecs/vf_expand.c index 95580b9f26..a640108e0e 100644 --- a/libmpcodecs/vf_expand.c +++ b/libmpcodecs/vf_expand.c @@ -452,10 +452,6 @@ static int control(struct vf_instance *vf, int request, void* data){ case VFCTRL_DRAW_OSD: if(vf->priv->osd_enabled) return CONTROL_TRUE; break; - case VFCTRL_REDRAW_OSD: - if (vf->priv->osd_enabled) - return false; - break; } #endif return vf_next_control(vf,request,data); @@ -481,6 +477,8 @@ static int vf_open(vf_instance_t *vf, char *args){ vf->priv->osd_enabled, vf->priv->aspect, vf->priv->round); + if (vf->priv->osd_enabled) + vf->default_caps = VFCAP_OSD_FILTER; return 1; } -- cgit v1.2.3