# HG changeset patch # User cannam # Date 1190645088 0 # Node ID 94a42248ec331217d30218500a6a201235758b83 # Parent c8b48bc6db3d8e57599a0e138a8b48b7da600e08 * don't allow block/step sizes to be undefined diff -r c8b48bc6db3d -r 94a42248ec33 host/vamp-simple-host.cpp --- a/host/vamp-simple-host.cpp Wed Sep 19 14:04:12 2007 +0000 +++ b/host/vamp-simple-host.cpp Mon Sep 24 14:44:48 2007 +0000 @@ -198,6 +198,15 @@ int blockSize = plugin->getPreferredBlockSize(); int stepSize = plugin->getPreferredStepSize(); + if (blockSize == 0) blockSize = 1024; + if (stepSize == 0) { + if (plugin->getInputDomain() == Vamp::Plugin::FrequencyDomain) { + stepSize = blockSize/2; + } else { + stepSize = blockSize; + } + } + int channels = sfinfo.channels; float *filebuf = new float[blockSize * channels];