1 /* 2 Copyright 2008-2011 David Robillard <http://drobilla.net> 3 Copyright 1999-2000 Paul Kellett (Maxim Digital Audio) 4 5 This is free software: you can redistribute it and/or modify it 6 under the terms of the GNU General Public License as published by 7 the Free Software Foundation, either version 3 of the License, 8 or (at your option) any later version. 9 10 This software is distributed in the hope that it will be useful, 11 but WITHOUT ANY WARRANTY; without even the implied warranty of 12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 13 See the GNU General Public License for more details. 14 15 You should have received a copy of the GNU General Public License 16 along with this software. If not, see <http://www.gnu.org/licenses/>. 17 */ 18 19 #ifndef __mdaTestTone_H 20 #define __mdaTestTone_H 21 22 #include "audioeffectx.h" 23 24 #include <cstdint> 25 26 class mdaTestTone : public AudioEffectX 27 { 28 public: 29 mdaTestTone(audioMasterCallback audioMaster); 30 ~mdaTestTone(); 31 32 virtual void process(float **inputs, float **outputs, int32_t sampleFrames); 33 virtual void processReplacing(float **inputs, float **outputs, int32_t sampleFrames); 34 virtual void setProgramName(char *name); 35 virtual void getProgramName(char *name); 36 virtual bool getProgramNameIndexed (int32_t category, int32_t index, char* name); 37 virtual void setParameter(int32_t index, float value); 38 virtual float getParameter(int32_t index); 39 virtual void getParameterLabel(int32_t index, char *label); 40 virtual void getParameterDisplay(int32_t index, char *text); 41 virtual void getParameterName(int32_t index, char *text); 42 virtual void iso2string(float b, char *text); 43 virtual void suspend(); 44 void midi2string(float n, char *text); 45 46 virtual bool getEffectName(char *name); 47 virtual bool getVendorString(char *text); 48 virtual bool getProductString(char *text); getVendorVersion()49 virtual int32_t getVendorVersion() { return 1000; } 50 51 protected: 52 int updateTx, updateRx; 53 void update(); 54 55 float fParam0, fParam1, fParam2; 56 float fParam3, fParam4, fParam5; 57 float fParam6, fParam7; 58 59 float thru, left, right, len; 60 float zz0, zz1, zz2, zz3, zz4, zz5, phi, dphi; 61 float sw, swd, swx, fscale, cal, calx; 62 int32_t swt; 63 int mode; 64 65 char programName[32], disp1[16], disp2[16]; 66 }; 67 68 #endif 69