File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed
modules/wechat_qrcode/src Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -35,7 +35,8 @@ class WeChatQRCode::Impl {
3535 * @param points succussfully decoded qrcode with bounding box points.
3636 * @return vector<string>
3737 */
38- std::vector<std::string> decode (const Mat& img, std::vector<Mat>& candidate_points,
38+ std::vector<std::string> decode (const Mat& img,
39+ const std::vector<Mat>& candidate_points,
3940 std::vector<Mat>& points);
4041 int applyDetector (const Mat& img, std::vector<Mat>& points);
4142 Mat cropObj (const Mat& img, const Mat& point, Align& aligner);
@@ -123,13 +124,14 @@ float WeChatQRCode::getScaleFactor() {
123124 return p->scaleFactor ;
124125};
125126
126- vector<string> WeChatQRCode::Impl::decode (const Mat& img, vector<Mat>& candidate_points,
127+ vector<string> WeChatQRCode::Impl::decode (const Mat& img,
128+ const vector<Mat>& candidate_points,
127129 vector<Mat>& points) {
128130 if (candidate_points.size () == 0 ) {
129131 return vector<string>();
130132 }
131133 vector<string> decode_results;
132- for (auto & point : candidate_points) {
134+ for (const auto & point : candidate_points) {
133135 Mat cropped_img;
134136 Align aligner;
135137 if (use_nn_detector_) {
You can’t perform that action at this time.
0 commit comments