From 3a01606dc05b2cedb9792a6f8adefeba6e434ab0 Mon Sep 17 00:00:00 2001 From: Uoti Urpala Date: Sat, 7 Apr 2012 16:26:56 +0300 Subject: libao2: change control() types to enum, remove unused ones Change the audio driver control() command argument from "int" to "enum aocontrol". Remove unused control types (SET_DEVICE, GET_DEVICE, QUERY_FORMAT, SET_PLUGIN_DRIVER, SET_PLUGIN_LIST). The QUERY_FORMAT one looks like there's a possibility such functionality could be useful in the future, but as ao_oss was the only driver to have an actual implementation of it, the current code wasn't worth keeping. --- libao2/ao_oss.c | 16 ---------------- 1 file changed, 16 deletions(-) (limited to 'libao2/ao_oss.c') diff --git a/libao2/ao_oss.c b/libao2/ao_oss.c index 82a0dd51e5..9290a73380 100644 --- a/libao2/ao_oss.c +++ b/libao2/ao_oss.c @@ -179,22 +179,6 @@ static int volume_oss4(ao_control_vol_t *vol, int cmd) { // to set/get/query special features/parameters static int control(int cmd,void *arg){ switch(cmd){ - case AOCONTROL_SET_DEVICE: - dsp=(char*)arg; - return CONTROL_OK; - case AOCONTROL_GET_DEVICE: - *(char**)arg=dsp; - return CONTROL_OK; -#ifdef SNDCTL_DSP_GETFMTS - case AOCONTROL_QUERY_FORMAT: - { - int format; - if (!ioctl(audio_fd, SNDCTL_DSP_GETFMTS, &format)) - if ((unsigned int)format & (unsigned long)arg) - return CONTROL_TRUE; - return CONTROL_FALSE; - } -#endif case AOCONTROL_GET_VOLUME: case AOCONTROL_SET_VOLUME: { -- cgit v1.2.3