More reset tests, tighten up reset logic

This commit is contained in:
Chris Cannam
2023-03-22 13:26:15 +00:00
parent 5f93a90902
commit 6c71159593
4 changed files with 140 additions and 1 deletions

View File

@@ -92,6 +92,17 @@ public:
void reset()
{
while (m_vfQueue.getReadSpace() > 0) {
process_t *entry = m_vfQueue.readOne();
deallocate(entry);
}
for (int i = 0; i < m_parameters.horizontalFilterLag; ++i) {
process_t *entry =
allocate_and_zero<process_t>(m_parameters.binCount);
m_vfQueue.write(&entry, 1);
}
m_hFilters->reset();
}