From 358397d204e975244f7b077bc33ab8b2987534fc Mon Sep 17 00:00:00 2001 From: wangchunlin Date: Fri, 25 Feb 2022 15:18:49 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E4=BA=86opencv4=E7=9A=84?= =?UTF-8?q?=E5=85=BC=E5=AE=B9=E6=80=A7=EF=BC=8C=E7=8E=B0=E5=9C=A8opencv3?= =?UTF-8?q?=E6=9C=AA=E7=9F=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ImageDetect/ImageDetect.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ImageDetect/ImageDetect.cxx b/ImageDetect/ImageDetect.cxx index 81c9640..9d0bb8f 100644 --- a/ImageDetect/ImageDetect.cxx +++ b/ImageDetect/ImageDetect.cxx @@ -1,7 +1,7 @@ #include #include #include -#include +#include #include #include #include @@ -22,7 +22,7 @@ using namespace cv; void detect_brightness(cv::Mat input_img, float& cast, float& da) { cv::Mat gray_img; - cv::cvtColor(input_img, gray_img, CV_BGR2GRAY); + cv::cvtColor(input_img, gray_img, COLOR_BGR2GRAY); float a = 0, Ma = 0; int hist[256] = { 0 }; @@ -65,4 +65,4 @@ int main(int argc, char *argv[]) detect_saturation(img, satu); cout<