summaryrefslogtreecommitdiffstats
path: root/libmpcodecs/vf_vo.c
diff options
context:
space:
mode:
authoralex <alex@b3059339-0415-0410-9bf9-f77b7e298cf2>2002-07-24 18:14:21 +0000
committeralex <alex@b3059339-0415-0410-9bf9-f77b7e298cf2>2002-07-24 18:14:21 +0000
commit2de7e088118b83235262483041d556c16410cbce (patch)
tree6fd692aada4fd7c1c4488c86dd1b3f5103123ffe /libmpcodecs/vf_vo.c
parentee5c104bd4f1da26ac689375feaf229b56f98eee (diff)
downloadmpv-2de7e088118b83235262483041d556c16410cbce.tar.bz2
mpv-2de7e088118b83235262483041d556c16410cbce.tar.xz
equalizer reworked
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@6781 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libmpcodecs/vf_vo.c')
-rw-r--r--libmpcodecs/vf_vo.c29
1 files changed, 27 insertions, 2 deletions
diff --git a/libmpcodecs/vf_vo.c b/libmpcodecs/vf_vo.c
index d5311375e6..9189010f6e 100644
--- a/libmpcodecs/vf_vo.c
+++ b/libmpcodecs/vf_vo.c
@@ -1,6 +1,7 @@
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
+#include <stdarg.h>
#include "../config.h"
#include "../mp_msg.h"
@@ -46,13 +47,37 @@ static int config(struct vf_instance_s* vf,
return 1;
}
-static int control(struct vf_instance_s* vf,
- int request, void* data){
+static int control(struct vf_instance_s* vf, int request, void* data, ...)
+{
switch(request){
+#ifdef USE_OSD
case VFCTRL_DRAW_OSD:
if(!vo_config_count) return CONTROL_FALSE; // vo not configured?
video_out->draw_osd();
return CONTROL_TRUE;
+#endif
+ case VFCTRL_SET_EQUALIZER:
+ {
+ va_list ap;
+ int value;
+
+ if(!vo_config_count) return CONTROL_FALSE; // vo not configured?
+ va_start(ap, data);
+ value = va_arg(ap, int);
+ va_end(ap);
+ return((video_out->control(VOCTRL_SET_EQUALIZER, data, (int *)value) == VO_TRUE) ? CONTROL_TRUE : CONTROL_FALSE);
+ }
+ case VFCTRL_GET_EQUALIZER:
+ {
+ va_list ap;
+ int value;
+
+ if(!vo_config_count) return CONTROL_FALSE; // vo not configured?
+ va_start(ap, data);
+ value = va_arg(ap, int);
+ va_end(ap);
+ return((video_out->control(VOCTRL_GET_EQUALIZER, data, (int *)value) == VO_TRUE) ? CONTROL_TRUE : CONTROL_FALSE);
+ }
}
// return video_out->control(request,data);
return CONTROL_UNKNOWN;