halcon怎样显示图像的直方图
1个回答
展开全部
有例子啊!帆迟
比如下面的例模察子代态码李码
* Calculate the gray value distribution of two regions of an image
*
read_image (Image, 'fabrik')
dev_close_window ()
get_image_size (Image, Width, Height)
dev_open_window (0, 0, Width, Height, 'black', WindowID)
dev_display (Image)
dev_set_draw ('margin')
dev_set_color ('red')
* Create two rectangles parallel to the coordinate axes
gen_rectangle1 (Rectangle1, 351, 289, 407, 340)
dev_set_color ('green')
gen_rectangle1 (Rectangle2, 78, 178, 144, 244)
gray_histo (Rectangle1, Image, AbsoluteHisto1, RelativeHisto1)
gray_histo (Rectangle2, Image, AbsoluteHisto2, RelativeHisto2)
dev_set_color ('red')
* Convert a histogram created with gray_histo into a region
gen_region_histo (Histo1, AbsoluteHisto1, 255, 255, 1)
dev_set_color ('green')
gen_region_histo (Histo2, AbsoluteHisto2, 255, 255, 1)
比如下面的例模察子代态码李码
* Calculate the gray value distribution of two regions of an image
*
read_image (Image, 'fabrik')
dev_close_window ()
get_image_size (Image, Width, Height)
dev_open_window (0, 0, Width, Height, 'black', WindowID)
dev_display (Image)
dev_set_draw ('margin')
dev_set_color ('red')
* Create two rectangles parallel to the coordinate axes
gen_rectangle1 (Rectangle1, 351, 289, 407, 340)
dev_set_color ('green')
gen_rectangle1 (Rectangle2, 78, 178, 144, 244)
gray_histo (Rectangle1, Image, AbsoluteHisto1, RelativeHisto1)
gray_histo (Rectangle2, Image, AbsoluteHisto2, RelativeHisto2)
dev_set_color ('red')
* Convert a histogram created with gray_histo into a region
gen_region_histo (Histo1, AbsoluteHisto1, 255, 255, 1)
dev_set_color ('green')
gen_region_histo (Histo2, AbsoluteHisto2, 255, 255, 1)
东莞大凡
2024-11-19 广告
2024-11-19 广告
作为东莞市大凡光学科技有限公司的工作人员,对于halcon标定板有所了解。Halcon标定板是高精度相机标定的关键工具,通常采用实心圆点或方格作为标志点。我们公司提供的halcon标定板,具有高精度、稳定可靠的特点,适用于机器视觉领域的各种...
点击进入详情页
本回答由东莞大凡提供
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询