Luc*_*ngo 11
如果要使用EmguCV,则应使用DenseHistogram类.我会告诉你基本用法:
// Create a grayscale image
Image<Gray, Byte> img = new Image<Gray, byte>(400, 400);
// Fill image with random values
img.SetRandUniform(new MCvScalar(), new MCvScalar(255));
// Create and initialize histogram
DenseHistogram hist = new DenseHistogram(256, new RangeF(0.0f, 255.0f));
// Histogram Computing
hist.Calculate<Byte>(new Image<Gray, byte>[] { img }, true, null);
Run Code Online (Sandbox Code Playgroud)
在DenseHistogram类中有许多其他常用方法,例如Back Projection
| 归档时间: |
|
| 查看次数: |
15202 次 |
| 最近记录: |