diff --git a/player/command.c b/player/command.c index 25e3aa1168..09fb75433a 100644 --- a/player/command.c +++ b/player/command.c @@ -2015,6 +2015,16 @@ static int video_refresh_property_helper(struct m_property *prop, int action, return r; } +static int video_simple_refresh_property(void *ctx, struct m_property *prop, + int action, void *arg) +{ + MPContext *mpctx = ctx; + int r = mp_property_generic_option(mpctx, prop, action, arg); + if (action == M_PROPERTY_SET && r == M_PROPERTY_OK) + mp_force_video_refresh(mpctx); + return r; +} + static void append_csp(char **ptr, const char *name, const char *const *names, int value) { @@ -2827,16 +2837,6 @@ static int mp_property_af(void *ctx, struct m_property *prop, return property_filter(prop, action, arg, ctx, STREAM_AUDIO); } -static int property_reinit_vf_helper(void *ctx, struct m_property *prop, - int action, void *arg) -{ - MPContext *mpctx = ctx; - int r = mp_property_generic_option(mpctx, prop, action, arg); - if (action == M_PROPERTY_SET && r == M_PROPERTY_OK) - reinit_video_filters(mpctx); - return r; -} - static int mp_property_alias(void *ctx, struct m_property *prop, int action, void *arg) { @@ -3078,7 +3078,7 @@ static const struct m_property mp_properties[] = { {"vf", mp_property_vf}, {"af", mp_property_af}, - {"video-rotate", property_reinit_vf_helper}, + {"video-rotate", video_simple_refresh_property}, #define PROPERTY_TV_COLOR(name, type) \ {name, mp_property_tv_color, (void *)(intptr_t)type}