Commit adfa13de authored by jpbl's avatar jpbl
Browse files

we list devices now

parent 8d429f02
......@@ -38,6 +38,7 @@ AudioLayer::AudioLayer ()
, _stream(NULL)
{
portaudio::System::initialize();
listDevices();
}
// Destructor
......@@ -57,6 +58,18 @@ AudioLayer::closeStream (void)
}
}
void
AudioLayer::listDevices()
{
ost::MutexLock guard(_mutex);
portaudio::System::DeviceIterator pos = portaudio::System::instance().devicesBegin();
while(pos != portaudio::System::instance().devicesEnd()) {
_debug("AudioLayer: Device (%d) %s\n", pos->index(), pos->name());
pos++;
}
}
void
AudioLayer::openDevice (int index)
{
......
......@@ -44,6 +44,7 @@ public:
AudioLayer();
~AudioLayer (void);
void listDevices();
void openDevice (int);
void startStream (void);
void stopStream (void);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment