OSS: output devices enumeration
Simple test program:
#include #include <vlc/vlc.h> #include
using namespace std;
int main() { libvlc_instance_t* libvlc = libvlc_new(0,0); libvlc_audio_output_t *first = libvlc_audio_output_list_get(libvlc); for( libvlc_audio_output_t aout = first; aout; aout = aout->p_next) { char const ss_nm = aout->psz_name;
const int dev_cnt = libvlc_audio_output_device_count(libvlc, ss_nm);
cout << ss_nm << " offers devices: " << dev_cnt << endl;
}
libvlc_audio_output_list_release(first);
}
output: alsa offers devices: 2 oss offers devices: 0 aout_file offers devices: 0 adummy offers devices: 0 amem offers devices: 0
I have oss4 running, and it works. Also vlc works with oss4. The problem is phonon. I want to use phonon-vlc, but applications don't play sound, because no working device was found (kcmshell4 kcm_phonon does not give me any devices). I tracked it down to device_count giving "0" for oss.