This documentation is automatically generated from the openFrameworks source code using doxygen and refers to the most recent release, version 0.12.0.
ofSoundStream.h
Go to the documentation of this file.
19OF_DEPRECATED_MSG("Use an ofSoundStreamSettings object instead of directly passing the parameters",
29OF_DEPRECATED_MSG("Use an ofSoundStreamSettings object instead of directly passing the parameters",
30 void ofSoundStreamSetup(int nOutputChannels, int nInputChannels, int sampleRate, int bufferSize, int nBuffers));
41OF_DEPRECATED_MSG("Use an ofSoundStreamSettings object instead of directly passing the parameters",
42 void ofSoundStreamSetup(int nOutputChannels, int nInputChannels, ofBaseApp * appPtr, int sampleRate, int bufferSize, int nBuffers));
93 std::vector<ofSoundDevice> getDeviceList(ofSoundDevice::Api api = ofSoundDevice::Api::DEFAULT) const;
96 std::vector<ofSoundDevice> getMatchingDevices(const std::string& name, unsigned int inChannels = UINT_MAX, unsigned int outChannels = UINT_MAX, ofSoundDevice::Api api = ofSoundDevice::Api::DEFAULT) const;
99 OF_DEPRECATED_MSG("Use an ofSoundStreamSettings object instead of directly passing the parameters",
103 OF_DEPRECATED_MSG("Use an ofSoundStreamSettings object instead of directly passing the parameters",
118 OF_DEPRECATED_MSG("Use an ofSoundStreamSettings object instead of directly passing the parameters",
119 bool setup(ofBaseApp * app, int outChannels, int inChannels, int sampleRate, int bufferSize, int nBuffers));
130 OF_DEPRECATED_MSG("Use an ofSoundStreamSettings object instead of directly passing the parameters",
183 OF_DEPRECATED_MSG("Use printDeviceList instead", std::vector<ofSoundDevice> listDevices() const);
Definition ofBaseApp.h:14
Represents information about a sound device on the system.
Definition ofSoundBaseTypes.h:57
void printDeviceList() const
Prints a list of available audio devices to the console.
Definition ofSoundStream.cpp:197
uint64_t getTickCount() const
Queries the number of "ticks" passed since the stream started.
Definition ofSoundStream.cpp:319
OF_DEPRECATED_MSG("Use an ofSoundStreamSettings object instead of directly passing the parameters", bool setup(ofBaseApp *app, int outChannels, int inChannels, int sampleRate, int bufferSize, int nBuffers))
std::shared_ptr< ofBaseSoundStream > soundStream
Definition ofSoundStream.h:186
OF_DEPRECATED_MSG("Use an ofSoundStreamSettings object instead of directly passing the parameters", void setDeviceID(int deviceID))
sets the device represented by the stream, see ofSoundStream::getDeviceList().
void close()
stops the stream and cleans up its resources.
Definition ofSoundStream.cpp:312
int getNumInputChannels() const
Queries the stream's number of input channels.
Definition ofSoundStream.cpp:327
OF_DEPRECATED_MSG("Use an ofSoundStreamSettings object instead of directly passing the parameters", void setDevice(const ofSoundDevice &device))
sets the device represented by the stream, see ofSoundStream::getDeviceList().
OF_DEPRECATED_MSG("Use printDeviceList instead", std::vector< ofSoundDevice > listDevices() const)
Retrieves a list of available audio devices and prints device descriptions to the console.
void start()
Starts a stream (note that setup() will start the stream on its own).
Definition ofSoundStream.cpp:298
int getBufferSize() const
Queries the stream's buffer size.
Definition ofSoundStream.cpp:351
int getNumOutputChannels() const
Queries the stream's number of output channels.
Definition ofSoundStream.cpp:335
std::shared_ptr< ofBaseSoundStream > getSoundStream()
Definition ofSoundStream.cpp:176
bool setup(const ofSoundStreamSettings &settings)
Definition ofSoundStream.cpp:218
void setSoundStream(std::shared_ptr< ofBaseSoundStream > soundStreamPtr)
Definition ofSoundStream.cpp:171
int getSampleRate() const
Queries the stream's sample rate.
Definition ofSoundStream.cpp:343
std::vector< ofSoundDevice > getMatchingDevices(const std::string &name, unsigned int inChannels=UINT_MAX, unsigned int outChannels=UINT_MAX, ofSoundDevice::Api api=ofSoundDevice::Api::DEFAULT) const
Get all devices which match the arguments (name can be a partial match)
Definition ofSoundStream.cpp:359
void setInput(ofBaseSoundInput *soundInput)
Sets the object which will have audioIn() called when the device receives audio.
Definition ofSoundStream.cpp:274
void setOutput(ofBaseSoundOutput *soundOutput)
Sets the object which will have audioOut() called when the device requests audio.
Definition ofSoundStream.cpp:286
std::vector< ofSoundDevice > getDeviceList(ofSoundDevice::Api api=ofSoundDevice::Api::DEFAULT) const
Retrieves a list of available audio devices.
Definition ofSoundStream.cpp:181
OF_DEPRECATED_MSG("Use an ofSoundStreamSettings object instead of directly passing the parameters", bool setup(int outChannels, int inChannels, int sampleRate, int bufferSize, int nBuffers))
Definition ofSoundBaseTypes.h:99
void ofSoundStreamStop()
Stops the sound stream (audioIn() / audioOut() will stop being called)
Definition ofSoundStream.cpp:142
std::vector< ofSoundDevice > ofSoundStreamListDevices()
Prints a list of all available audio devices.
Definition ofSoundStream.cpp:157
void ofSoundStreamSetup(ofSoundStreamSettings &settings)
Definition ofSoundStream.cpp:137
void ofSoundStreamClose()
Stops the sound stream and also cleans up the stream's resources.
Definition ofSoundStream.cpp:152
void ofSoundStreamStart()
Starts the sound stream (audioIn() / audioOut() will start being called)
Definition ofSoundStream.cpp:147