mirror of
https://github.com/opencv/opencv.git
synced 2024-12-01 06:49:50 +08:00
Merge pull request #17055 from vnikoofard:patch-1
This commit is contained in:
commit
65b3209441
@ -31,7 +31,7 @@ def Hist_and_Backproj(val):
|
|||||||
histImg = np.zeros((h, w, 3), dtype=np.uint8)
|
histImg = np.zeros((h, w, 3), dtype=np.uint8)
|
||||||
|
|
||||||
for i in range(bins):
|
for i in range(bins):
|
||||||
cv.rectangle(histImg, (i*bin_w, h), ( (i+1)*bin_w, h - int(round( hist[i]*h/255.0 )) ), (0, 0, 255), cv.FILLED)
|
cv.rectangle(histImg, (i*bin_w, h), ( (i+1)*bin_w, h - int(np.round( hist[i]*h/255.0 )) ), (0, 0, 255), cv.FILLED)
|
||||||
|
|
||||||
cv.imshow('Histogram', histImg)
|
cv.imshow('Histogram', histImg)
|
||||||
## [Draw the histogram]
|
## [Draw the histogram]
|
||||||
|
Loading…
Reference in New Issue
Block a user