1D Histogram with OpenCV C++
This post is also available in: Spanish
I’d like to say again that the documentation of the OpenCV is very poor.
This is a histogram of 1D for an image of 8 bit single channel (grayscale).
The code is commented for an easier understanding.
I used the same image to obtain the histogram as i made it in Python

The advantage of the opencv histograms functions is that you can obtain a histogram of n – dimensions.

English
Español
Français