当前位置:网站首页>Opencv learning log 30 -- histogram equalization
Opencv learning log 30 -- histogram equalization
2022-07-06 15:43:00 【@Spring sauce】
Preface
This article is mainly about opencv Histogram equalization in image processing algorithm .
One 、 Histogram equalization
// The second question is Histogram equalization
#include <opencv2/opencv.hpp>
#include <iostream>
using namespace cv;
float chance[256];
int main()
{
cv::Mat src_color = imread("C://Users//john//Desktop//1.jpg");
//cv::imshow("src_color",src_color);
std::vector<cv::Mat> channels;
cv::split(src_color, channels);
cv::Mat B = channels.at(0);
cv::Mat G = channels.at(1);
cv::Mat R = channels.at(2);
cv::imshow("redFI", R);
cv::imshow("blueFI", B);
cv::imshow("greenFI", G);
cv::imshow("original MatFI", src_color);
equalizeHist(B, B);
equalizeHist(G, G);
equalizeHist(R, R);
cv::imshow("red", R);
cv::imshow("blue", B);
cv::imshow("green", G);
cv::imshow("original Mat", src_color);
waitKey(0);
}
summary
1. The code can run directly , If you don't understand, you can leave a message .
2. Missing material pictures , Follow up, thank you .
边栏推荐
- 初入Redis
- JS --- detailed explanation of JS DOM (IV)
- Accounting regulations and professional ethics [3]
- China's PCB connector market trend report, technological innovation and market forecast
- Accounting regulations and professional ethics [2]
- STM32学习记录:玩转按键控制蜂鸣器和LED
- Printing quality inspection and verification system Industry Research Report - market status analysis and development prospect forecast
- Cost accounting [14]
- MATLAB综合练习:信号与系统中的应用
- Flink 使用之 CEP
猜你喜欢
ucorelab3
Learning record: how to perform PWM output
STM32學習記錄:輸入捕獲應用
Flex --- detailed explanation of flex layout attributes
STM32 learning record: LED light flashes (register version)
LeetCode#36. Effective Sudoku
Borg Maze (BFS+最小生成树)(解题报告)
Crawling cat's eye movie review, data visualization analysis source code operation instructions
Crawler series (9): item+pipeline data storage
学习记录:使用STM32外部输入中断
随机推荐
0-1背包问题(一)
Accounting regulations and professional ethics [3]
China's salt water membrane market trend report, technological innovation and market forecast
Learning records: serial communication and solutions to errors encountered
STM32如何使用STLINK下载程序:点亮LED跑马灯(库版本)
毕业才知道IT专业大学生毕业前必做的1010件事
Market trend report, technical innovation and market forecast of Chinese hospital respiratory humidification equipment
Unpleasant error typeerror: cannot perform 'ROR_‘ with a dtyped [float64] array and scalar of type [bool]
TCP的三次握手与四次挥手
Cost accounting [14]
学习记录:如何进行PWM 输出
Cost accounting [16]
Research Report on market supply and demand and strategy of China's land incineration plant industry
JS --- all knowledge of JS objects and built-in objects (III)
Research Report on medical anesthesia machine industry - market status analysis and development prospect prediction
想应聘程序员,您的简历就该这样写【精华总结】
洛谷P1102 A-B数对(二分,map,双指针)
MATLAB实例:阶跃函数的两种表达方式
Cost accounting [18]
LeetCode#198. raid homes and plunder houses