seems working
This commit is contained in:
parent
af7afaf8b2
commit
bea578104f
@ -1,4 +1,4 @@
|
|||||||
#N canvas 0 265 595 358 12;
|
#N canvas 0 265 818 358 12;
|
||||||
#X obj 78 87 adc~, f 6;
|
#X obj 78 87 adc~, f 6;
|
||||||
#X obj 73 241 loadbang;
|
#X obj 73 241 loadbang;
|
||||||
#X msg 73 271 \; pd dsp 1 \;;
|
#X msg 73 271 \; pd dsp 1 \;;
|
||||||
@ -13,10 +13,13 @@
|
|||||||
#X obj 242 263 dbtorms;
|
#X obj 242 263 dbtorms;
|
||||||
#X obj 242 290 s gain;
|
#X obj 242 290 s gain;
|
||||||
#X obj 300 225 s svstparameter0;
|
#X obj 300 225 s svstparameter0;
|
||||||
#X obj 277 75 vsl 50 128 0 1 0 0 empty empty empty 0 -9 0 10 -262144
|
#X obj 277 75 vsl 50 128 0 1 0 0 empty empty empty 0 -9 0 10 #fcfcfc #000000 #000000 0 1;
|
||||||
-1 -1 0 1;
|
|
||||||
#X msg 277 42 set \$1;
|
#X msg 277 42 set \$1;
|
||||||
#X text 355 117 range is 0..1;
|
#X text 355 117 range is 0..1;
|
||||||
|
#X obj 498 10 r rvstplugname;
|
||||||
|
#X symbolatom 498 48 17 0 0 0 - - - 0;
|
||||||
|
#X obj 516 102 r rvstdata;
|
||||||
|
#X symbolatom 516 136 17 0 0 0 - - - 0;
|
||||||
#X connect 0 0 7 0;
|
#X connect 0 0 7 0;
|
||||||
#X connect 0 1 6 0;
|
#X connect 0 1 6 0;
|
||||||
#X connect 1 0 2 0;
|
#X connect 1 0 2 0;
|
||||||
@ -33,3 +36,5 @@
|
|||||||
#X connect 14 0 13 0;
|
#X connect 14 0 13 0;
|
||||||
#X connect 14 0 10 0;
|
#X connect 14 0 10 0;
|
||||||
#X connect 15 0 14 0;
|
#X connect 15 0 14 0;
|
||||||
|
#X connect 17 0 18 0;
|
||||||
|
#X connect 19 0 20 0;
|
||||||
|
@ -17,5 +17,5 @@ ALL: vstschedlib.c
|
|||||||
gcc -Wall -I$(PDDIR)src -I../vst-template vstschedlib.c -static-libgcc \
|
gcc -Wall -I$(PDDIR)src -I../vst-template vstschedlib.c -static-libgcc \
|
||||||
-shared -L$(PDDIR)bin -l:pd.dll -o vstschedlib.dll
|
-shared -L$(PDDIR)bin -l:pd.dll -o vstschedlib.dll
|
||||||
strip vstschedlib.dll
|
strip vstschedlib.dll
|
||||||
cp vstschedlib.dll ../build/pd-scheduler$(arch)/vstschedlib.dll
|
#cp vstschedlib.dll ../build/pd-scheduler$(arch)/vstschedlib.dll
|
||||||
#cp vstschedlib.dll ../build/Release$(arch)/.pd/bin/vstschedlib.dll
|
cp vstschedlib.dll ../build/Release$(arch)/.pd/bin/vstschedlib.dll
|
@ -70,6 +70,8 @@ typedef struct _vstGuiNameReceiver
|
|||||||
|
|
||||||
t_vstGuiNameReceiver *vstGuiNameReceiver;
|
t_vstGuiNameReceiver *vstGuiNameReceiver;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
t_vstParameterReceiver *vstParameterReceivers[MAXPARAMETERS];
|
t_vstParameterReceiver *vstParameterReceivers[MAXPARAMETERS];
|
||||||
|
|
||||||
t_class *vstParameterReceiver_class;
|
t_class *vstParameterReceiver_class;
|
||||||
@ -195,6 +197,19 @@ int setPdvstPlugName(char* instanceName)
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int setPdvstChunk(char* instanceName)
|
||||||
|
{
|
||||||
|
t_symbol *tempSym;
|
||||||
|
tempSym = gensym("rvstdata");
|
||||||
|
if (tempSym->s_thing)
|
||||||
|
{
|
||||||
|
pd_symbol(tempSym->s_thing, gensym(instanceName));
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
int setPdvstFloatParameter(int index, float value)
|
int setPdvstFloatParameter(int index, float value)
|
||||||
{
|
{
|
||||||
@ -262,6 +277,8 @@ void makePdvstGuiNameReceiver()
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
void send_dacs(void)
|
void send_dacs(void)
|
||||||
{
|
{
|
||||||
int i, j, sampleCount, nChannels, blockSize;
|
int i, j, sampleCount, nChannels, blockSize;
|
||||||
@ -391,6 +408,14 @@ int scheduler()
|
|||||||
pdvstData->plugName.updated=0;
|
pdvstData->plugName.updated=0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// lucarda get data chunk from file
|
||||||
|
if (pdvstData->datachunk.direction == PD_RECEIVE && \
|
||||||
|
pdvstData->datachunk.updated)
|
||||||
|
{
|
||||||
|
if (setPdvstChunk((char*)pdvstData->datachunk.value.stringData))
|
||||||
|
pdvstData->datachunk.updated=0;
|
||||||
|
}
|
||||||
|
|
||||||
if (pdvstData->hostTimeInfo.updated)
|
if (pdvstData->hostTimeInfo.updated)
|
||||||
{
|
{
|
||||||
pdvstData->hostTimeInfo.updated=0;
|
pdvstData->hostTimeInfo.updated=0;
|
||||||
|
@ -227,6 +227,7 @@ pdvst::pdvst(audioMasterCallback audioMaster)
|
|||||||
timeFromStartup=GetTickCount();
|
timeFromStartup=GetTickCount();
|
||||||
// JYG }
|
// JYG }
|
||||||
programsAreChunks(true);
|
programsAreChunks(true);
|
||||||
|
sendPlugName(globalPluginName);
|
||||||
}
|
}
|
||||||
|
|
||||||
pdvst::~pdvst()
|
pdvst::~pdvst()
|
||||||
@ -610,6 +611,15 @@ VstInt32 pdvst::getChunk (void** data, bool isPreset)
|
|||||||
|
|
||||||
VstInt32 pdvst::setChunk (void* data, VstInt32 byteSize, bool isPreset)
|
VstInt32 pdvst::setChunk (void* data, VstInt32 byteSize, bool isPreset)
|
||||||
{
|
{
|
||||||
|
|
||||||
|
WaitForSingleObject(pdvstTransferMutex, 10);
|
||||||
|
{
|
||||||
|
pdvstData->datachunk.direction = PD_RECEIVE;
|
||||||
|
pdvstData->datachunk.type = STRING_TYPE;
|
||||||
|
strcpy(pdvstData->datachunk.value.stringData,(char *)data);
|
||||||
|
pdvstData->datachunk.updated = 1;
|
||||||
|
ReleaseMutex(pdvstTransferMutex);
|
||||||
|
}
|
||||||
MessageBox(0,"setchunk","debug",MB_OK);
|
MessageBox(0,"setchunk","debug",MB_OK);
|
||||||
debugLog("setchunk: %s", data);
|
debugLog("setchunk: %s", data);
|
||||||
return 1;
|
return 1;
|
||||||
|
@ -121,6 +121,7 @@ typedef struct _pdvstTransferData
|
|||||||
pdvstMidiMessage midiQueue[MAXMIDIQUEUESIZE];
|
pdvstMidiMessage midiQueue[MAXMIDIQUEUESIZE];
|
||||||
pdvstParameter guiState;
|
pdvstParameter guiState;
|
||||||
pdvstParameter plugName; // transmitted by host
|
pdvstParameter plugName; // transmitted by host
|
||||||
|
pdvstParameter datachunk; // get/set chunk from .fxp file
|
||||||
pdvstParameter guiName; // transmitted by pd : name of gui window to be embedded
|
pdvstParameter guiName; // transmitted by pd : name of gui window to be embedded
|
||||||
// #ifdef VSTMIDIOUTENABLE
|
// #ifdef VSTMIDIOUTENABLE
|
||||||
int midiOutQueueSize;
|
int midiOutQueueSize;
|
||||||
|
Loading…
Reference in New Issue
Block a user