sdl2/generated/lib_sdl_audio library

Functions

sdlAudioInit(String? driverName) int
Use this function to initialize a particular audio driver.
sdlAudioQuit() → void
Use this function to shut down audio if you initialized it with SDL_AudioInit().
sdlAudioStreamAvailable(Pointer<SdlAudioStream> stream) int
Get the number of converted/resampled bytes available.
sdlAudioStreamClear(Pointer<SdlAudioStream> stream) → void
Clear any pending data in the stream without converting it
sdlAudioStreamFlush(Pointer<SdlAudioStream> stream) int
Tell the stream that you're done sending data, and anything being buffered should be converted/resampled and made available immediately.
sdlAudioStreamGet(Pointer<SdlAudioStream> stream, Pointer<NativeType> buf, int len) int
Get converted/resampled data from the stream
sdlAudioStreamPut(Pointer<SdlAudioStream> stream, Pointer<NativeType> buf, int len) int
Add data to be converted/resampled to the stream.
sdlBuildAudioCvt(Pointer<SdlAudioCvt> cvt, int srcFormat, int srcChannels, int srcRate, int dstFormat, int dstChannels, int dstRate) int
Initialize an SDL_AudioCVT structure for conversion.
sdlClearQueuedAudio(int dev) → void
Drop any queued audio data waiting to be sent to the hardware.
sdlCloseAudio() → void
This function is a legacy means of closing the audio device.
sdlCloseAudioDevice(int dev) → void
Use this function to shut down audio processing and close the audio device.
sdlConvertAudio(Pointer<SdlAudioCvt> cvt) int
Convert audio data to a desired audio format.
sdlDequeueAudio(int dev, Pointer<NativeType> data, int len) int
Dequeue more audio on non-callback devices.
sdlFreeAudioStream(Pointer<SdlAudioStream> stream) → void
Free an audio stream
sdlFreeWav(Pointer<Uint8> audioBuf) → void
Free data previously allocated with SDL_LoadWAV() or SDL_LoadWAV_RW().
sdlGetAudioDeviceName(int index, int iscapture) String?
Get the human-readable name of a specific audio device.
sdlGetAudioDeviceSpec(int index, int iscapture, Pointer<SdlAudioSpec> spec) int
Get the preferred audio format of a specific audio device.
sdlGetAudioDeviceStatus(int dev) int
Use this function to get the current audio state of an audio device.
sdlGetAudioDriver(int index) String?
Use this function to get the name of a built in audio driver.
sdlGetAudioStatus() int
This function is a legacy means of querying the audio device.
sdlGetCurrentAudioDriver() String?
Get the name of the current audio driver.
sdlGetDefaultAudioInfo(Pointer<Pointer<Int8>> name, Pointer<SdlAudioSpec> spec, int iscapture) int
Get the name and preferred format of the default audio device.
sdlGetNumAudioDevices(int iscapture) int
Get the number of built-in audio devices.
sdlGetNumAudioDrivers() int
Use this function to get the number of built-in audio drivers.
sdlGetQueuedAudioSize(int dev) int
Get the number of bytes of still-queued audio.
sdlLoadWavRw(Pointer<SdlRWops> src, int freesrc, Pointer<SdlAudioSpec> spec, Pointer<Pointer<Uint8>> audioBuf, Pointer<Uint32> audioLen) Pointer<SdlAudioSpec>
Load the audio data of a WAVE file into memory.
sdlLockAudio() → void
This function is a legacy means of locking the audio device.
sdlLockAudioDevice(int dev) → void
Use this function to lock out the audio callback function for a specified device.
sdlMixAudio(Pointer<Uint8> dst, Pointer<Uint8> src, int len, int volume) → void
This function is a legacy means of mixing audio.
sdlMixAudioFormat(Pointer<Uint8> dst, Pointer<Uint8> src, int format, int len, int volume) → void
Mix audio data in a specified format.
sdlNewAudioStream(int srcFormat, int srcChannels, int srcRate, int dstFormat, int dstChannels, int dstRate) Pointer<SdlAudioStream>
Create a new audio stream.
sdlOpenAudio(Pointer<SdlAudioSpec> desired, Pointer<SdlAudioSpec> obtained) int
This function is a legacy means of opening the audio device.
sdlOpenAudioDevice(String? device, int iscapture, Pointer<SdlAudioSpec> desired, Pointer<SdlAudioSpec> obtained, int allowedChanges) int
Open a specific audio device.
sdlPauseAudio(int pauseOn) → void
This function is a legacy means of pausing the audio device.
sdlPauseAudioDevice(int dev, int pauseOn) → void
Use this function to pause and unpause audio playback on a specified device.
sdlQueueAudio(int dev, Pointer<NativeType> data, int len) int
Queue more audio on non-callback devices.
sdlUnlockAudio() → void
This function is a legacy means of unlocking the audio device.
sdlUnlockAudioDevice(int dev) → void
Use this function to unlock the audio callback function for a specified device.