void InputDeviceAdapter::initializeAdapter(const Misc::ConfigurationFileSection& configFileSection) { /* Allocate adapter state arrays: */ typedef std::vector<std::string> StringList; StringList inputDeviceNames=configFileSection.retrieveValue<StringList>("./inputDeviceNames"); numInputDevices=inputDeviceNames.size(); inputDevices=new InputDevice*[numInputDevices]; for(int i=0;i<numInputDevices;++i) inputDevices[i]=0; /* Initialize input devices: */ for(int i=0;i<numInputDevices;++i) { /* Go to device's section: */ Misc::ConfigurationFileSection deviceSection=configFileSection.getSection(inputDeviceNames[i].c_str()); /* Initialize input device: */ createInputDevice(i,deviceSection); } }
QAbstractAudioInput* QAudioDeviceFactory::createDefaultInputDevice(QAudioFormat const &format) { return createInputDevice(defaultInputDevice(), format); }