VSTPlugin::set_state (const XMLNode& node, int version)
{
LocaleGuard lg (X_("POSIX"));
+ int ret = -1;
if (node.name() != state_node_name()) {
error << _("Bad node sent to VSTPlugin::set_state") << endmsg;
return 0;
}
+#ifndef NO_PLUGIN_STATE
XMLNode* child;
- int ret = -1;
if ((child = find_named_node (node, X_("chunk"))) != 0) {
ret = 0;
}
+#endif
Plugin::set_state (node, version);
return ret;
{
Plugin::connect_and_run (bufs, in_map, out_map, nframes, offset);
- float *ins[_plugin->numInputs];
- float *outs[_plugin->numOutputs];
+ // VC++ doesn't support this C99 extension. Use alloca instead of dynamic array (rather than std::vector which allocs on the heap)
+ float** ins = (float**)alloca(_plugin->numInputs*sizeof(float*));
+ float** outs = (float**)alloca(_plugin->numInputs*sizeof(float*));
int32_t i;
const uint32_t nbufs = bufs.count().n_audio();
}
/* we already know it can support processReplacing */
- _plugin->processReplacing (_plugin, ins, outs, nframes);
+ _plugin->processReplacing (_plugin, &ins[0], &outs[0], nframes);
return 0;
}