video: rename VDCTRL_RESET_ASPECT to VDCTRL_REINIT_VO

Same thing, and VDCTRL_REINIT_VO implies more generic use.
This commit is contained in:
wm4 2013-05-18 11:32:53 +02:00
parent f921a675ae
commit c970f5c328
5 changed files with 6 additions and 6 deletions

View File

@ -1205,7 +1205,7 @@ static int mp_property_aspect(m_option_t *prop, int action, void *arg,
if (f < 0.1)
f = (float)mpctx->sh_video->disp_w / mpctx->sh_video->disp_h;
mpctx->opts.movie_aspect = f;
video_reset_aspect(mpctx->sh_video);
video_reinit_vo(mpctx->sh_video);
return M_PROPERTY_OK;
}
case M_PROPERTY_GET:

View File

@ -162,9 +162,9 @@ void resync_video_stream(sh_video_t *sh_video)
sh_video->prev_sorted_pts = MP_NOPTS_VALUE;
}
void video_reset_aspect(struct sh_video *sh_video)
void video_reinit_vo(struct sh_video *sh_video)
{
sh_video->vd_driver->control(sh_video, VDCTRL_RESET_ASPECT, NULL);
sh_video->vd_driver->control(sh_video, VDCTRL_REINIT_VO, NULL);
}
int get_current_video_decoder_lag(sh_video_t *sh_video)

View File

@ -41,7 +41,7 @@ struct mp_csp_details;
void get_detected_video_colorspace(struct sh_video *sh, struct mp_csp_details *csp);
void set_video_colorspace(struct sh_video *sh);
void resync_video_stream(sh_video_t *sh_video);
void video_reset_aspect(struct sh_video *sh_video);
void video_reinit_vo(struct sh_video *sh_video);
int get_current_video_decoder_lag(sh_video_t *sh_video);
extern int divx_quality;

View File

@ -42,7 +42,7 @@ extern const vd_functions_t *const mpcodecs_vd_drivers[];
#define VDCTRL_RESYNC_STREAM 8 // reset decode state after seeking
#define VDCTRL_QUERY_UNSEEN_FRAMES 9 // current decoder lag
#define VDCTRL_RESET_ASPECT 10 // reinit filter/VO chain for new aspect ratio
#define VDCTRL_REINIT_VO 10 // reinit filter/VO chain
int mpcodecs_config_vo(sh_video_t *sh, int w, int h, unsigned int outfmt);

View File

@ -772,7 +772,7 @@ static int control(sh_video_t *sh, int cmd, void *arg)
delay += avctx->thread_count - 1;
*(int *)arg = delay;
return CONTROL_TRUE;
case VDCTRL_RESET_ASPECT:
case VDCTRL_REINIT_VO:
if (ctx->vo_initialized)
ctx->vo_initialized = false;
init_vo(sh, ctx->pic);