AudioSampleBuffer - Ultimate Topic

There are two sliders, which allow me to change time and pitch, of the currently playing audio file. Yes, I would name it a realtime effect processor.

ok, keep in mind that applying effects to an audio file and applying them to a fixed size buffer brought to you by an underlying device manager are different things, even if the dsp part of it is the same.

why not start with simpler things ?

@all, thanks for your help!

quote="robiwan"
Or expressed in semi-pseudo code (assuming stereo):

[code]void AudioClass::audioDeviceIOCallback(const float** inputChannelData, int totalNumInputChannels, float** outputChannelData, int totalNumOutputChannels, int numSamples)
{
AudioSampleBuffer inbuf(inputChannelData, 2, numSamples);
AudioSampleBuffer outbuf(outputChannelData, 2, numSamples);

processAudioData(inbuf, outbuf);
}

void AudioClass::processAudioData(const AudioSampleBuffer& in, AudioSampleBuffer& out)
{
// Tweak data to your hearts content
}
[/code][/quote]
I really wouldlike to know, how to give over the result of processAudioData to outputChannelData, so that the soundcard can play this?

If it is

then I found it, but I can´t get along how to use it (with this syntax).

Why are you trying to use the AudioDevice directly? Like kraken said, just create an AudioSource object that performs the processing that you need. Go and read all the help for all the classes in the audio_source folder, get your head around how they work, and use them instead. This is exactly the kind of thing they’re designed for, and the whole point is that you don’t need to go near the AudioIODevice class…

Ok thanks.
I was thinking, the only location to manipulate/process my data is there (audioDeviceIOCallback), like robiwan wrote on previous page here.

I ´m going to read them. Do you mean juce\src\juce_appframework\audio\audio_sources ?

Thanks again for helping me out. I´m just beginning to internalize/excercise JUCE.

He probably assumed you had a good reason for wanting to use the low-level IO. But for most normal uses, you’re better off writing an audio source to do the work.