summaryrefslogtreecommitdiffstats
path: root/libmpcodecs
diff options
context:
space:
mode:
authorUoti Urpala <uau@symbol.nonexistent.invalid>2008-04-02 18:51:38 +0300
committerUoti Urpala <uau@symbol.nonexistent.invalid>2008-04-23 13:41:03 +0300
commitdbe080ec9f05cd216f4217c81409a37d3f4db969 (patch)
tree48861e98ea8a195781e314b7b96923509c35b0f1 /libmpcodecs
parent530df550e4af63fce126001c5509d931d9ee65f9 (diff)
downloadmpv-dbe080ec9f05cd216f4217c81409a37d3f4db969.tar.bz2
mpv-dbe080ec9f05cd216f4217c81409a37d3f4db969.tar.xz
Change VOCTRL_[GET|SET]_EQUALIZER argument passing
These were the only voctrl types with more than one argument. The second argument was passed using variable arguments. Change them to use a single argument (address of a struct containing both old arguments). This makes forwarding the arguments to other functions easier and allows simplifying code.
Diffstat (limited to 'libmpcodecs')
-rw-r--r--libmpcodecs/vf_vo.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/libmpcodecs/vf_vo.c b/libmpcodecs/vf_vo.c
index f0daa59e62..877826e3bc 100644
--- a/libmpcodecs/vf_vo.c
+++ b/libmpcodecs/vf_vo.c
@@ -103,13 +103,15 @@ static int control(struct vf_instance_s* vf, int request, void* data)
{
vf_equalizer_t *eq=data;
if(!vo_config_count) return CONTROL_FALSE; // vo not configured?
- return((video_out->control(VOCTRL_SET_EQUALIZER, eq->item, eq->value) == VO_TRUE) ? CONTROL_TRUE : CONTROL_FALSE);
+ struct voctrl_set_equalizer_args param = {eq->item, eq->value};
+ return video_out->control(VOCTRL_SET_EQUALIZER, &param) == VO_TRUE;
}
case VFCTRL_GET_EQUALIZER:
{
vf_equalizer_t *eq=data;
if(!vo_config_count) return CONTROL_FALSE; // vo not configured?
- return((video_out->control(VOCTRL_GET_EQUALIZER, eq->item, &eq->value) == VO_TRUE) ? CONTROL_TRUE : CONTROL_FALSE);
+ struct voctrl_get_equalizer_args param = {eq->item, &eq->value};
+ return video_out->control(VOCTRL_GET_EQUALIZER, &param) == VO_TRUE;
}
#ifdef USE_ASS
case VFCTRL_INIT_EOSD: