From 3892ce1f734c5045510fdb2c38a36f4e225a7cfa Mon Sep 17 00:00:00 2001 From: Alexandre Benoit Date: Mon, 30 Jan 2012 09:40:02 +0000 Subject: [PATCH] added access methods to retreive retina input and output buffers sizes --- modules/contrib/include/opencv2/contrib/retina.hpp | 10 ++++++++++ modules/contrib/src/retina.cpp | 11 +++++++++++ 2 files changed, 21 insertions(+) diff --git a/modules/contrib/include/opencv2/contrib/retina.hpp b/modules/contrib/include/opencv2/contrib/retina.hpp index 770114a286..6bf4877302 100644 --- a/modules/contrib/include/opencv2/contrib/retina.hpp +++ b/modules/contrib/include/opencv2/contrib/retina.hpp @@ -165,6 +165,16 @@ public: virtual ~Retina(); + /** + * retreive retina input buffer size + */ + Size inputSize(); + + /** + * retreive retina output buffer size + */ + Size outputSize(); + /** * try to open an XML retina parameters file to adjust current retina instance setup * => if the xml file does not exist, then default setup is applied diff --git a/modules/contrib/src/retina.cpp b/modules/contrib/src/retina.cpp index bd6e552b2b..daf1c0146a 100644 --- a/modules/contrib/src/retina.cpp +++ b/modules/contrib/src/retina.cpp @@ -93,6 +93,17 @@ Retina::~Retina() delete _retinaFilter; } +/** +* retreive retina input buffer size +*/ +Size Retina::inputSize(){return cv::Size(_retinaFilter->getInputNBcolumns(), _retinaFilter->getInputNBrows());} + +/** +* retreive retina output buffer size +*/ +Size Retina::outputSize(){return cv::Size(_retinaFilter->getOutputNBcolumns(), _retinaFilter->getOutputNBrows());} + + void Retina::setColorSaturation(const bool saturateColors, const float colorSaturationValue) { _retinaFilter->setColorSaturation(saturateColors, colorSaturationValue);