diff options
author | Yuqian Yang <crupest@crupest.life> | 2025-02-28 23:13:39 +0800 |
---|---|---|
committer | Yuqian Yang <crupest@crupest.life> | 2025-02-28 23:13:39 +0800 |
commit | dc1f0c4c0096013799416664894c5194dc7e1f52 (patch) | |
tree | 2f5d235f778cd720f4c39ec3e56b77ba6d99f375 /works/life/digital-image-process-lab/HistogramEqulization.cpp | |
parent | 7299d424d90b1effb6db69e3476ddd5af72eeba4 (diff) | |
download | crupest-dc1f0c4c0096013799416664894c5194dc7e1f52.tar.gz crupest-dc1f0c4c0096013799416664894c5194dc7e1f52.tar.bz2 crupest-dc1f0c4c0096013799416664894c5194dc7e1f52.zip |
chore(store): move everything to store.
Diffstat (limited to 'works/life/digital-image-process-lab/HistogramEqulization.cpp')
-rw-r--r-- | works/life/digital-image-process-lab/HistogramEqulization.cpp | 34 |
1 files changed, 0 insertions, 34 deletions
diff --git a/works/life/digital-image-process-lab/HistogramEqulization.cpp b/works/life/digital-image-process-lab/HistogramEqulization.cpp deleted file mode 100644 index 951a966..0000000 --- a/works/life/digital-image-process-lab/HistogramEqulization.cpp +++ /dev/null @@ -1,34 +0,0 @@ -#include <iostream> -#include <string> - -#include <opencv2/highgui.hpp> -#include <opencv2/imgcodecs.hpp> -#include <opencv2/imgproc.hpp> - -int main(int argc, char **argv) { - if (argc != 2) { - std::cerr << "Please input an image file path as the only arg." - << std::endl; - return -1; - } - - std::string file_name(argv[1]); - - cv::Mat src, dst; - - src = cv::imread(file_name, cv::IMREAD_COLOR); - if (src.empty()) { - std::cerr << "Failed to load image file: " << file_name << std::endl; - return -2; - } - - cv::cvtColor(src, src, cv::COLOR_BGR2GRAY); - - cv::equalizeHist(src, dst); - - cv::imshow("Source Image", src); - cv::imshow("Equalized Image", dst); - cv::waitKey(); - - return 0; -} |