0

I am trying to display image frame from the video and its histograms in one window using canvas. Here is the piece of my code. It displays only the image but not the histogram, I am saving the calculated histogram in cv::Mat histogram. Separately the histogram in another window is displayed without problem. makeCanvas is from here

vector<Mat> vecMat1;
vecMat1.push_back(frame);
vecMat1.push_back(histogram);
cv::namedWindow("canvas");
cv::imshow("canvas", makeCanvas(vecMat1, 600, 2));`

Is it possible to do? Any references, any information is appreciated. Thank you.

Alexey
  • 1,198
  • 1
  • 15
  • 35
  • Is `histogram` an image of the histogram or the histogram as a simple 1d-array? In other words, does `cv::imshow("histogram", histogram) look as expected? – chtz Dec 30 '16 at 23:47
  • I would use this: [HSV histogram showed as 3D graph](http://stackoverflow.com/a/29286584/2521214) – Spektre Dec 31 '16 at 10:26
  • @chtz `histogram` is as an image, it can be displayed in different window, but not in canvas together with image. – Galiya Numar Jan 01 '17 at 12:56

0 Answers0