mirror of
https://github.com/raysan5/raylib.git
synced 2025-10-26 12:27:01 +00:00
ADDED: Audio stream processors support -WIP- #2212
This feature is still under consideration/testing and it doesn't work properly, at least the Delay Effect processor.
This commit is contained in:
@@ -428,10 +428,12 @@ typedef struct Wave {
|
||||
// Opaque structs declaration
|
||||
// NOTE: Actual structs are defined internally in raudio module
|
||||
typedef struct rAudioBuffer rAudioBuffer;
|
||||
typedef struct rAudioProcessor rAudioProcessor;
|
||||
|
||||
// AudioStream, custom audio stream
|
||||
typedef struct AudioStream {
|
||||
rAudioBuffer *buffer; // Pointer to internal data used by the audio system
|
||||
rAudioProcessor *processor; // Pointer to internal data processor, useful for audio effects
|
||||
|
||||
unsigned int sampleRate; // Frequency (samples per second)
|
||||
unsigned int sampleSize; // Bit depth (bits per sample): 8, 16, 32 (24 not supported)
|
||||
@@ -1543,6 +1545,9 @@ RLAPI void SetAudioStreamPan(AudioStream stream, float pan); // Set pan
|
||||
RLAPI void SetAudioStreamBufferSizeDefault(int size); // Default size for new audio streams
|
||||
RLAPI void SetAudioStreamCallback(AudioStream stream, AudioCallback callback); // Audio thread callback to request new data
|
||||
|
||||
RLAPI void AttachAudioStreamProcessor(AudioStream stream, AudioCallback processor);
|
||||
RLAPI void DetachAudioStreamProcessor(AudioStream stream, AudioCallback processor);
|
||||
|
||||
#if defined(__cplusplus)
|
||||
}
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user