# HG changeset patch # User Chris Cannam # Date 1476304461 -3600 # Node ID 03ed2e0a6c8f00c84897ed252b9eb66f6fd4f577 # Parent bf2e6f939f9f3bf59b84aee5046eace1c8df0185 More testing diff -r bf2e6f939f9f -r 03ed2e0a6c8f vamp-client/client.cpp --- a/vamp-client/client.cpp Wed Oct 12 19:02:31 2016 +0100 +++ b/vamp-client/client.cpp Wed Oct 12 21:34:21 2016 +0100 @@ -51,8 +51,11 @@ ~PiperClient() { if (m_process) { if (m_process->state() != QProcess::NotRunning) { + m_process->closeWriteChannel(); + m_process->waitForFinished(200); m_process->close(); m_process->waitForFinished(); + cerr << "server exited" << endl; } delete m_process; } @@ -338,6 +341,23 @@ } (void)plugin->getRemainingFeatures(); + + cerr << "calling reset..." << endl; + plugin->reset(); + cerr << "...round 2!" << endl; + + std::vector buf = { 1.0, -1.0, 1.0, -1.0 }; + float *bd = buf.data(); + Vamp::Plugin::FeatureSet features = plugin->process + (&bd, Vamp::RealTime::zeroTime); + cerr << "results for output 0:" << endl; + auto fl(features[0]); + for (const auto &f: fl) { + cerr << f.values[0] << endl; + } + + (void)plugin->getRemainingFeatures(); + delete plugin; //!!! -- and also implement reset(), which will need to reconstruct internally } diff -r bf2e6f939f9f -r 03ed2e0a6c8f vamp-server/server.cpp --- a/vamp-server/server.cpp Wed Oct 12 19:02:31 2016 +0100 +++ b/vamp-server/server.cpp Wed Oct 12 21:34:21 2016 +0100 @@ -276,7 +276,7 @@ // NotValid without an exception indicates EOF: if (request.type == RRType::NotValid) { - cerr << "piper-vamp-server: eof reached" << endl; + cerr << "piper-vamp-server: eof reached, exiting" << endl; break; }