retina included in namespace bioinspired + followed suggestions made by Vadim
This commit is contained in:
@@ -128,7 +128,7 @@ static void drawPlot(const cv::Mat curve, const std::string figureTitle, const i
|
||||
normalize(imageInputRescaled, imageInputRescaled, 0.0, 255.0, cv::NORM_MINMAX);
|
||||
}
|
||||
|
||||
cv::Ptr<Retina> retina;
|
||||
cv::Ptr<cv::bioinspired::Retina> retina;
|
||||
int retinaHcellsGain;
|
||||
int localAdaptation_photoreceptors, localAdaptation_Gcells;
|
||||
static void callBack_updateRetinaParams(int, void*)
|
||||
@@ -218,10 +218,10 @@ static void drawPlot(const cv::Mat curve, const std::string figureTitle, const i
|
||||
*/
|
||||
if (useLogSampling)
|
||||
{
|
||||
retina = createRetina(inputImage.size(),true, RETINA_COLOR_BAYER, true, 2.0, 10.0);
|
||||
retina = cv::bioinspired::createRetina(inputImage.size(),true, cv::bioinspired::RETINA_COLOR_BAYER, true, 2.0, 10.0);
|
||||
}
|
||||
else// -> else allocate "classical" retina :
|
||||
retina = createRetina(inputImage.size());
|
||||
retina = cv::bioinspired::createRetina(inputImage.size());
|
||||
|
||||
// create a fast retina tone mapper (Meyla&al algorithm)
|
||||
std::cout<<"Allocating fast tone mapper..."<<std::endl;
|
||||
|
@@ -161,7 +161,7 @@ static void rescaleGrayLevelMat(const cv::Mat &inputMat, cv::Mat &outputMat, con
|
||||
|
||||
}
|
||||
|
||||
cv::Ptr<Retina> retina;
|
||||
cv::Ptr<cv::bioinspired::Retina> retina;
|
||||
int retinaHcellsGain;
|
||||
int localAdaptation_photoreceptors, localAdaptation_Gcells;
|
||||
static void callBack_updateRetinaParams(int, void*)
|
||||
@@ -281,10 +281,10 @@ static void loadNewFrame(const std::string filenamePrototype, const int currentF
|
||||
*/
|
||||
if (useLogSampling)
|
||||
{
|
||||
retina = createRetina(inputImage.size(),true, RETINA_COLOR_BAYER, true, 2.0, 10.0);
|
||||
retina = cv::bioinspired::createRetina(inputImage.size(),true, cv::bioinspired::RETINA_COLOR_BAYER, true, 2.0, 10.0);
|
||||
}
|
||||
else// -> else allocate "classical" retina :
|
||||
retina = createRetina(inputImage.size());
|
||||
retina = cv::bioinspired::createRetina(inputImage.size());
|
||||
|
||||
// save default retina parameters file in order to let you see this and maybe modify it and reload using method "setup"
|
||||
retina->write("RetinaDefaultParameters.xml");
|
||||
|
@@ -106,15 +106,15 @@ int main(int argc, char* argv[]) {
|
||||
try
|
||||
{
|
||||
// create a retina instance with default parameters setup, uncomment the initialisation you wanna test
|
||||
cv::Ptr<Retina> myRetina;
|
||||
cv::Ptr<cv::bioinspired::Retina> myRetina;
|
||||
|
||||
// if the last parameter is 'log', then activate log sampling (favour foveal vision and subsamples peripheral vision)
|
||||
if (useLogSampling)
|
||||
{
|
||||
myRetina = createRetina(inputFrame.size(), true, RETINA_COLOR_BAYER, true, 2.0, 10.0);
|
||||
myRetina = cv::bioinspired::createRetina(inputFrame.size(), true, cv::bioinspired::RETINA_COLOR_BAYER, true, 2.0, 10.0);
|
||||
}
|
||||
else// -> else allocate "classical" retina :
|
||||
myRetina = createRetina(inputFrame.size());
|
||||
myRetina = cv::bioinspired::createRetina(inputFrame.size());
|
||||
|
||||
// save default retina parameters file in order to let you see this and maybe modify it and reload using method "setup"
|
||||
myRetina->write("RetinaDefaultParameters.xml");
|
||||
|
@@ -95,16 +95,16 @@ int main(int argc, char* argv[]) {
|
||||
try
|
||||
{
|
||||
// create a retina instance with default parameters setup, uncomment the initialisation you wanna test
|
||||
cv::Ptr<Retina> myRetina;
|
||||
cv::Ptr<cv::bioinspired::Retina> myRetina;
|
||||
|
||||
// if the last parameter is 'log', then activate log sampling (favour foveal vision and subsamples peripheral vision)
|
||||
if (useLogSampling)
|
||||
{
|
||||
myRetina = createRetina(inputFrame.size(), true, RETINA_COLOR_BAYER, true, 2.0, 10.0);
|
||||
myRetina = cv::bioinspired::createRetina(inputFrame.size(), true, cv::bioinspired::RETINA_COLOR_BAYER, true, 2.0, 10.0);
|
||||
}
|
||||
else// -> else allocate "classical" retina :
|
||||
{
|
||||
myRetina = createRetina(inputFrame.size());
|
||||
myRetina = cv::bioinspired::createRetina(inputFrame.size());
|
||||
}
|
||||
|
||||
// save default retina parameters file in order to let you see this and maybe modify it and reload using method "setup"
|
||||
|
Reference in New Issue
Block a user