From 1c65e6366dd9ef09385a4a45b717bc5731228ec9 Mon Sep 17 00:00:00 2001 From: indianocean10000 Date: Fri, 7 Dec 2018 16:14:56 -0800 Subject: [PATCH] fix typo I think that that there was a typo in the variable names. fill2, texture2, and size2 were never used. Also, minor fix to reduce initialization costs of vector --- modules/ximgproc/src/selectivesearchsegmentation.cpp | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/modules/ximgproc/src/selectivesearchsegmentation.cpp b/modules/ximgproc/src/selectivesearchsegmentation.cpp index 05e80e063..2ec355fc4 100644 --- a/modules/ximgproc/src/selectivesearchsegmentation.cpp +++ b/modules/ximgproc/src/selectivesearchsegmentation.cpp @@ -811,7 +811,7 @@ namespace cv { Ptr texture2 = createSelectiveSearchSegmentationStrategyTexture(); Ptr size2 = createSelectiveSearchSegmentationStrategySize(); - Ptr m2 = createSelectiveSearchSegmentationStrategyMultiple(fill, texture, size); + Ptr m2 = createSelectiveSearchSegmentationStrategyMultiple(fill2, texture2, size2); addStrategy(m2); @@ -839,10 +839,7 @@ namespace cv { addImage(channel[0]); split(base_image, channel); - std::vector channel2; - channel2.push_back(channel[2]); - channel2.push_back(channel[1]); - channel2.push_back(I); + std::vector channel2 = {channel[2], channel[1], I}; Mat rgI; merge(channel2, rgI); @@ -868,7 +865,7 @@ namespace cv { Ptr texture2 = createSelectiveSearchSegmentationStrategyTexture(); Ptr size2 = createSelectiveSearchSegmentationStrategySize(); - Ptr m2 = createSelectiveSearchSegmentationStrategyMultiple(fill, texture, size); + Ptr m2 = createSelectiveSearchSegmentationStrategyMultiple(fill2, texture2, size2); addStrategy(m2);