opencv: Add cvcalchist element for calculating histogram
Submitted by Josh Doe
Link to original bug (#635646)
Description
Created attachment 175134
Patch to add cvcalchist
Added the element cvcalchist which wraps the OpenCV function cvCalcHist. Only
8- and 16-bit monochrome video is supported at this time. By default the
element will not alter the data, but if "draw-histogram" is true, then a crude
histogram will be drawn over the image.
I've included a test program under tests/examples/opencv that draws a text histogram to the console using the "histogram" message.
Please review the patch, as I'm sure there are some issues. I wasn't sure of a nice way to handle RGB histograms, especially in terms of how to package the data in a message, so I left that alone for the time being. Also note I'm developed this under Windows, but hopefully I've modified the Makefiles appropriately.
Patch 175134, "Patch to add cvcalchist":
0001-opencv-Add-cvcalchist-element-for-calculating-histog.patch