class
#include <nCine/Audio/AudioStreamPlayer.h>
AudioStreamPlayer Audio stream player.
Base classes
- class IAudioPlayer
- Audio player interface.
Public static functions
- static auto sType() -> ObjectType
Constructors, destructors, conversion operators
- AudioStreamPlayer()
- Default constructor.
- AudioStreamPlayer(StringView filename) explicit
- A constructor creating a player from a file.
- ~AudioStreamPlayer() override
- AudioStreamPlayer(AudioStreamPlayer&&) defaulted
- Default move constructor.
Public functions
- auto operator=(AudioStreamPlayer&&) -> AudioStreamPlayer& defaulted
- Default move assignment operator.
- auto loadFromFile(const char* filename) -> bool
- auto bufferId() const -> unsigned int override
- Returns the OpenAL id of the currently playing buffer.
- auto bytesPerSample() const -> int override
- Returns the number of bytes per sample.
- auto numChannels() const -> int override
- Returns the number of audio channels of the currently playing buffer.
- auto frequency() const -> int override
- Returns the samples frequency of the currently playing buffer.
- auto numSamples() const -> unsigned long int override
- Returns the number of samples.
- auto duration() const -> float override
- Returns the duration in seconds.
- auto bufferSize() const -> unsigned long override
- Returns the size of the currently playing buffer in bytes.
- auto numStreamSamples() const -> unsigned long int
- auto streamBufferSize() const -> int
- void play() override
- Starts playing.
- void pause() override
- Pauses playing.
- void stop() override
- Stops playing and rewind.
- void setLooping(bool value) override
- Sets player looping property.
- void updateState() override
- Updates the player state and the stream buffer queue.