Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 3 additions & 6 deletions pixelstats.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -493,11 +493,8 @@ void pixelStats::updateHisto(){
ui->histo->detachItems( QwtPlotItem::Rtti_PlotCurve);
ui->histo->detachItems( QwtPlotItem::Rtti_PlotMarker);
ui->histo->detachItems(QwtPlotItem::Rtti_PlotItem);
// Quantize the hue to 30 levels
// and the saturation to 32 levels
int hbins = 1000, sbins = 32;
int histSize[] = {hbins, sbins};
// hue varies from 0 to 179, see cvtColor
int hbins = 1000; // make histogram with 1000 bins
int histSize[] = {hbins};


cv::Mat hist;
Expand All @@ -510,7 +507,7 @@ void pixelStats::updateHisto(){

float hranges[] = { (float)m_wf->min, (float)m_wf->max};
const float* ranges[] = { hranges };
int channels[] = {0, 1};
int channels[] = { 0 };
cv::calcHist( &values, 1, channels, m_wf->workMask, // do not use mask
hist, 1, histSize, ranges,
true, // the histogram is uniform
Expand Down
Loading