Mercurial > hg > qm-vamp-plugins
diff plugins/DWT.cpp @ 214:23b2a2f93c5a
Merge from branch MSVC
author | Chris Cannam <c.cannam@qmul.ac.uk> |
---|---|
date | Fri, 27 Apr 2018 15:48:50 +0100 |
parents | 4697db8b91f8 |
children |
line wrap: on
line diff
--- a/plugins/DWT.cpp Fri Sep 30 19:04:06 2016 +0100 +++ b/plugins/DWT.cpp Fri Apr 27 15:48:50 2018 +0100 @@ -93,6 +93,11 @@ { if (channels < getMinChannelCount() || channels > getMaxChannelCount()) return false; + + if (m_inputSampleRate > 1000000) { // somewhat arbitrarily + std::cerr << "DWT::initialise: ERROR: Maximum sample rate exceeded" << std::endl; + return false; + } if ((1U << m_scales) > blockSize) { std::cerr << "DWT::initialise: ERROR: Block size must be at least 2^scales (specified block size " << blockSize << " < " << (1 << m_scales) << ")" << std::endl;