@@ -336,6 +336,15 @@ Debayer::~Debayer()
* debayer processing.
*/
+/**
+ * \fn void Debayer::stop()
+ * \brief Stop the debayering process and perform cleanup
+ *
+ * In the DebayerCPU case this is an empty stub function but
+ * for the GPU case this does something useful. The stub here is to
+ * ensure the right version of the virtual gets called.
+ */
+
/**
* \fn void Debayer::setParams(DebayerParams ¶ms)
* \brief Select the bayer params to use for the next frame debayer
@@ -48,6 +48,7 @@ public:
strideAndFrameSize(const PixelFormat &outputFormat, const Size &size) = 0;
virtual void process(uint32_t frame, FrameBuffer *input, FrameBuffer *output, DebayerParams params) = 0;
+ virtual void stop() { }
virtual SizeRange sizes(PixelFormat inputFormat, const Size &inputSize) = 0;
@@ -367,9 +367,11 @@ int SoftwareIsp::start()
*/
void SoftwareIsp::stop()
{
+ debayer_->invokeMethod(&DebayerCpu::stop,
+ ConnectionTypeBlocking);
+
ispWorkerThread_.exit();
ispWorkerThread_.wait();
- ispWorkerThread_.removeMessages(debayer_.get());
Thread::current()->dispatchMessages(Message::Type::InvokeMessage, this);