#define H_ERR_WHDL 2450 /* Wrong (unknown) HALCON handle */ #define H_ERR_WID 2451 /* Wrong HALCON id, no data available */ #define H_ERR_IDOOR 2452 /* HALCON id out of range */ #define H_ERR_HANDLE_NULL 2453 /* Handle is NULL */ #define H_ERR_HANDLE_CLEARED 2454 ...
下面是一个示例代码,展示了如何传递HalconWindowHandle参数: 在上面的代码中: 1.我们首先声明了一个HalconWindowHandle变量hv_WindowHandle。 2.使用open_window函数打开一个图像窗口,并将窗口句柄存储在hv_WindowHandle中。 3.读取一张图像,并使用set_window函数将当前窗口设置为hv_WindowHandle对应的窗口,然后使用disp...
也具备和C一样的全局函数——对应HALCON所有operator,同名同参数序列。C#和C++类似,具有面向对象和过程两种编程方式。面向过程:HOperatorSet类提供了所有operator,HObject是iconic data,HTuple是control data。面向对象:像HData2Code2d,HMeasure,HShapeModel这样的类提供了核心功能,另外iconic data可以使用如HImage,HRegion...
HOperatorSet.SetPart(hv_ExpDefaultWinHandle, 0, 0, hv_Height - 1, hv_Width - 1); HOperatorSet.DispObj(ho_Image, hv_ExpDefaultWinHandle); // 显示ho_Image中的图片 HOperatorSet.SetDraw(hv_ExpDefaultWinHandle,"margin"); // 填充模式为只画框 HOperatorSet.SetColor(hv_ExpDefaultWinHandle,...
1. 使用算子处理图像基本流程 *关闭当前窗体dev_close_window()*读取图像read_image(Image,'test.jpg')*图像尺寸get_image_size(Image,Width,Height)*打开窗体dev_open_window(0,0,Width,Height,'black',WindowHandle)*绘制轮廓不填充dev_set_draw('margin')*线宽dev_set_line_width(1)*字体set_display_font...
Halcon是一种计算机视觉软件工具,用于图像处理、分析和机器视觉应用。它由德国MVTec公司开发,是一种功能强大的视觉软件工具,可用于解决各种计算机视觉问题,包括目标检测、图像识别、三维视觉等。Halcon支持多种编程语言,包括C++、C#、Python等,用户可以使用自己熟悉的编程语言进行开发和应用。
clear_handle( : :Handle: ) Description clear_handleclears the content of the handle contained inHandle. The handle is left in a cleared state afterwards. Attempts to use it in any other operator will raise an error. Usually, handles are automatically cleared once all references in all tuples...
// //Input parameters: //WindowHandle: The WindowHandle of the graphics window, where // the message should be displayed. //String: A tuple of strings containing the text messages to be displayed. //CoordSystem: If set to 'window', the text position is given // with respect to the ...
Note that due to the generic nature of this operator, some of the returned keys might not be valid for the particular handle. In this case, get_handle_tuple or get_handle_object will return an error for those keys. 'key_data_type': Returns the data type of Key. The type is ...
(0, 0, 512, 512, WindowID, "visible", "", out hv_WindowHandle); if (HalconAPI.isWindows) HOperatorSet.SetSystem("use_window_thread", "true"); HDevWindowStack.Push(hv_WindowHandle); if (HDevWindowStack.IsOpen()) { HOperatorSet.SetDraw(HDevWindowStack.GetActive(), "fill"); } }...