# Please help! DSP ProcessorChain SideChain

**URL:** <https://forum.juce.com/t/please-help-dsp-processorchain-sidechain/50844>\
**Category:** General JUCE discussion\
**Created:** [April 2, 2022, 7:22am UTC](https://forum.juce.com/t/please-help-dsp-processorchain-sidechain/50844 "2022-04-02T07:22:58Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![jose117bedo](https://avatars.discourse-cdn.com/v4/letter/j/96bed5/32.png) [@jose117bedo](https://forum.juce.com/u/jose117bedo)\
**Post date:** [April 2, 2022, 7:22am UTC](https://forum.juce.com/t/please-help-dsp-processorchain-sidechain/50844/1 "2022-04-02T07:22:58Z")

</div>

Hello everyone, I hope you are well!  
I am making an audio plugin which has a Buffer of the stereo inputs and outputs and another one that only receives a mono input as a SideChain (All this through a BussBuffer); however, I also use the Juce DSP library to perform a processing in a chain through a “ProcessorChain” of filters to the stereo buffer.  
When I introduce the stereo buffer to the ProcessorChain, it is not affected at all by the chain processes (Various filters).  
Does anyone know what I could be doing wrong or what would be missing?

Thanks!!

Attached is my AudioProcessor :

```auto
void SpaceitorAudioProcessor::processBlock (juce::AudioBuffer<float>& buffer, juce::MidiBuffer& midiMessages)
{
    juce::ScopedNoDenormals noDenormals;
    auto totalNumInputChannels = getTotalNumInputChannels();
    auto totalNumOutputChannels = getTotalNumOutputChannels();

    auto mainInputOutput = getBusBuffer(buffer, true, 0); // [5]
    auto sideChainInput = getBusBuffer(buffer, true, 1);
    const float* inL;
    const float* inR;
    const float* inSide;
     //DERECHO ES 1

    for (auto i = totalNumInputChannels; i < totalNumOutputChannels; ++i)
        buffer.clear (i, 0, buffer.getNumSamples());

        for (int sample = 0; sample < buffer.getNumSamples(); ++sample)
        {
            inR = mainInputOutput.getReadPointer(1);
            inL = mainInputOutput.getReadPointer(0);
            

            inSide = sideChainInput.getReadPointer(0);

            float* OutL = mainInputOutput.getWritePointer(0);
            float* OutR = mainInputOutput.getWritePointer(1);

           OutL[sample] = (inL[sample]) ;

           OutR[sample] = inR[sample] ;

           //inSide[sample] +

          vfft.pushNextSampleIntoFifo(OutL[sample]);
           
        }

        juce::dsp::AudioBlock<float> ioBuffer(mainInputOutput);

        auto leftBlock = ioBuffer.getSingleChannelBlock(0);
        auto rigthBlock = ioBuffer.getSingleChannelBlock(1);

        
        juce::dsp::ProcessContextReplacing<float> context(leftBlock);
        filter.process(context);

       juce::dsp::ProcessContextReplacing<float> contextr(rigthBlock);
        filter.process(contextr);

}

```

---

<div class="post-metadata">

**Author:** ![t0m](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/t0m/32/16413_2.png) [@t0m](https://forum.juce.com/u/t0m)\
**Post date:** [April 4, 2022, 9:08am UTC](https://forum.juce.com/t/please-help-dsp-processorchain-sidechain/50844/2 "2022-04-04T09:08:50Z")

</div>

It’s not clear from your code sample how you are hoping to use the sidechain. Could you make a simpler example? What does `filter` look like?

Are you receiving the audio data you expect from the sidechain?
