/[svn]/linuxsampler/trunk/src/hostplugins/vst/PluginVst.h
ViewVC logotype

Annotation of /linuxsampler/trunk/src/hostplugins/vst/PluginVst.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2372 - (hide annotations) (download) (as text)
Sat Sep 22 18:28:38 2012 UTC (11 years, 8 months ago) by schoenebeck
File MIME type: text/x-c++hdr
File size: 3157 byte(s)
* VST: implemented retrieval and switching of programs using the
  sampler's internal MIDI instrument mapping system
* VST: reply to "canDo" plugin features we don't know as "don't know"
* bumped version to 1.0.0.svn19

1 persson 1777 /***************************************************************************
2     * *
3 persson 2347 * Copyright (C) 2008 - 2012 Andreas Persson *
4 persson 1777 * *
5     * This program is free software; you can redistribute it and/or modify *
6     * it under the terms of the GNU General Public License as published by *
7     * the Free Software Foundation; either version 2 of the License, or *
8     * (at your option) any later version. *
9     * *
10     * This program 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. See the *
13     * 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 program; if not, write to the Free Software *
17     * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, *
18     * MA 02110-1301 USA *
19     ***************************************************************************/
20    
21     #ifndef LS_PLUGINVST_H
22     #define LS_PLUGINVST_H
23    
24     #include "../../drivers/Plugin.h"
25    
26     #include <audioeffectx.h>
27     #include <aeffeditor.h>
28    
29    
30     namespace {
31    
32     class LinuxSamplerEditor : public AEffEditor {
33     public:
34     LinuxSamplerEditor(AudioEffect* effect);
35 persson 1895 ~LinuxSamplerEditor();
36 persson 1777 bool open(void* ptr);
37     void close();
38     bool getRect(ERect** rect);
39     private:
40     #ifdef WIN32
41     HANDLE ProcessHandle;
42     LPTSTR Command;
43 persson 2347 #else
44     pid_t pid;
45 persson 1777 #endif
46 persson 2347 static String FindFantasia();
47 persson 1777 };
48    
49    
50     class LinuxSamplerVst : public AudioEffectX, LinuxSampler::Plugin {
51     public:
52     LinuxSamplerVst(audioMasterCallback audioMaster);
53     ~LinuxSamplerVst();
54    
55     void processReplacing(float** inputs, float** outputs,
56     VstInt32 sampleframes);
57     VstInt32 processEvents(VstEvents* events);
58    
59     void resume();
60     void setProgram(VstInt32 program);
61     void setProgramName(char* name);
62     void getProgramName(char* name);
63     bool getProgramNameIndexed(VstInt32 category, VstInt32 index, char* text);
64    
65     void setSampleRate(float sampleRate);
66     void setBlockSize(VstInt32 blockSize);
67    
68     bool getOutputProperties(VstInt32 index, VstPinProperties* properties);
69    
70     bool getEffectName(char* name);
71     bool getVendorString(char* text);
72     bool getProductString(char* text);
73     VstInt32 getVendorVersion();
74     VstInt32 canDo(char* text);
75     VstInt32 getChunk(void** data, bool isPreset);
76     VstInt32 setChunk(void* data, VstInt32 byteSize, bool isPreset);
77    
78     private:
79     char* StateBuf;
80     String SavedChunk;
81     };
82     }
83    
84     #endif

  ViewVC Help
Powered by ViewVC