Tutorial: Create a basic Audio/MIDI plugin Part 2: Coding your plug-in


#1

Hi,
I’m on Mac OS with Xcode 8.2.1. I’m trying to complete this tutorial, but I’m stuck at the point where I have to insert the following code:
void TutorialPluginAudioProcessorEditor::sliderValueChanged (Slider* slider)
{
_ processor.noteOnVel = midiVolume.getValue();_
}

I do insert the code into PluginEditor.cpp (at the end) but get an error message:
Out-of-line definition of ‘sliderValueChange’ does not match any declaration in 'TutorialPluginAudioProcessorEditor
How can I solve this or what am I doing wrong? Any help much appreciated!


#2

Have you added the corresponding definition for sliderValueChanged in the .h file?

You may have a typo in:
void sliderValueChanged (Slider* slider) override;


#3

Thank you Dave, you pointed me in the right direction. Shame on me, but I forgot to add that part of the code… Now the build succeeds, only with one message: Unused variable ‘channelData’, but I guess at this point I don’t need it. Thanks again for the quick reply!