RelativeRect.ToPixelRect method
小于 1 分钟
RelativeRect.ToPixelRect method
将相对坐标转换为像素坐标,并做边界保护。 这里的边界保护是为了避免: 1) 反序列化后出现微小越界 2) 极端缩放时产生 0 宽高
public Rect ToPixelRect(int imageWidth, int imageHeight)| parameter | description |
|---|---|
| imageWidth | 目标图像宽度(像素) |
| imageHeight | 目标图像高度(像素) |
Return Value
可直接用于 OpenCV 裁剪的像素矩形
See Also
- struct RelativeRect
- namespace neo_bpsys_wpf.Core.Models
