Changes

Jump to navigation Jump to search
Line 838: Line 838:  
It includes the header files  
 
It includes the header files  
 
  #include "DistrhoPlugin.hpp"
 
  #include "DistrhoPlugin.hpp"
 +
 +
we define a class:
 +
class SimpleGainPlugin : public Plugin {
 +
public:
 +
    SimpleGainPlugin() : Plugin(1, 0, 0) { // 1 parameter, 0 programs, 0 states
 +
        gain = 1.0f; // Default gain (no change)
 +
    }
 +
 +
 +
 +
At the bottom of the code we instantiate (generate, create, make alive...) the object and return it to the calling function.
 +
 +
Plugin* createPlugin() {
 +
    return new SimpleGainPlugin();
 +
}
    
=====makefile=====
 
=====makefile=====
1,112

edits

Navigation menu