├── LICENSE ├── README.md ├── applications ├── Calibration │ ├── source │ │ ├── AssemblyInfo.cs │ │ ├── CalibrationForm.cs │ │ └── CalibrationForm.resx │ └── vs2005 │ │ ├── CalibrationMain.csproj │ │ ├── CalibrationMain.sln │ │ └── Properties │ │ ├── Settings.Designer.cs │ │ └── Settings.settings ├── GraphicsStack │ ├── source │ │ ├── AssemblyInfo.cs │ │ ├── GraphicsStackForm.cs │ │ └── GraphicsStackForm.resx │ └── vs2005 │ │ ├── GraphicsStack.csproj │ │ ├── GraphicsStack.sln │ │ └── Properties │ │ ├── Settings.Designer.cs │ │ └── Settings.settings ├── GraphicsWindow │ ├── source │ │ ├── AssemblyInfo.cs │ │ ├── GraphicsWindowForm.cs │ │ └── GraphicsWindowForm.resx │ └── vs2005 │ │ ├── GraphicsWindow.csproj │ │ ├── GraphicsWindow.sln │ │ └── Properties │ │ ├── Settings.Designer.cs │ │ └── Settings.settings ├── InteractiveROI │ ├── source │ │ ├── AssemblyInfo.cs │ │ ├── InteractROIForm.cs │ │ └── InteractROIForm.resx │ └── vs2005 │ │ ├── InteractiveROI.csproj │ │ ├── InteractiveROI.sln │ │ └── Properties │ │ ├── Settings.Designer.cs │ │ └── Settings.settings ├── Matching │ ├── source │ │ ├── AssemblyInfo.cs │ │ ├── MatchingForm.cs │ │ └── MatchingForm.resx │ └── vs2005 │ │ ├── MatchingMain.csproj │ │ ├── MatchingMain.sln │ │ └── Properties │ │ ├── Settings.Designer.cs │ │ └── Settings.settings ├── Measure │ ├── source │ │ ├── AssemblyInfo.cs │ │ ├── MeasureForm.cs │ │ └── MeasureForm.resx │ └── vs2005 │ │ ├── MeasureMain.csproj │ │ ├── MeasureMain.sln │ │ └── Properties │ │ ├── Settings.Designer.cs │ │ └── Settings.settings ├── SmartWindow1 │ ├── source │ │ ├── AssemblyInfo.cs │ │ ├── SmartWindow1Form.cs │ │ └── SmartWindow1Form.resx │ └── vs2005 │ │ ├── Properties │ │ ├── Settings.Designer.cs │ │ └── Settings.settings │ │ ├── SmartWindow1.csproj │ │ └── SmartWindow1.sln └── SmartWindow2 │ ├── source │ ├── AssemblyInfo.cs │ ├── SmartWindow2Form.cs │ └── SmartWindow2Form.resx │ └── vs2005 │ ├── Properties │ ├── Settings.Designer.cs │ └── Settings.settings │ ├── SmartWindow2.csproj │ └── SmartWindow2.sln ├── assistants ├── Calibration │ ├── source │ │ ├── AssemblyInfo.cs │ │ ├── CalibImage.cs │ │ ├── CalibrationAssistant.cs │ │ ├── QualityIssue.cs │ │ └── QualityProcedures.cs │ └── vs2005 │ │ ├── CalibrationModule.csproj │ │ └── CalibrationModule.sln ├── Matching │ ├── source │ │ ├── AssemblyInfo.cs │ │ ├── MatchingAssistant.cs │ │ ├── MatchingOpt.cs │ │ ├── MatchingOptSpeed.cs │ │ ├── MatchingOptStatistics.cs │ │ ├── MatchingParam.cs │ │ └── MatchingResult.cs │ └── vs2005 │ │ ├── MatchingModule.csproj │ │ └── MatchingModule.sln └── Measure │ ├── source │ ├── AssemblyInfo.cs │ ├── MeasureAssistant.cs │ ├── Measurement.cs │ ├── MeasurementEdge.cs │ ├── MeasurementPair.cs │ └── MeasurementResult.cs │ └── vs2005 │ ├── MeasureModule.csproj │ └── MeasureModule.sln ├── base └── ViewROI │ ├── source │ ├── AssemblyInfo.cs │ ├── FunctionPlot.cs │ ├── GraphicsContext.cs │ ├── HObjectEntry.cs │ ├── HWndCtrl.cs │ ├── ROI.cs │ ├── ROICircle.cs │ ├── ROICircularArc.cs │ ├── ROIController.cs │ ├── ROILine.cs │ ├── ROIRectangle1.cs │ └── ROIRectangle2.cs │ └── vs2005 │ ├── ViewROI.csproj │ └── ViewROI.sln └── controls ├── HDisplayControl ├── source │ ├── FunctionPlot.cs │ ├── GraphicsContext.cs │ ├── HDisplayControl.Designer.cs │ ├── HDisplayControl.cs │ ├── HDisplayControl.resx │ ├── HObjectEntry.cs │ ├── HWndCtrl.cs │ ├── ROI.cs │ ├── ROICircle.cs │ ├── ROICircularArc.cs │ ├── ROIController.cs │ ├── ROILine.cs │ ├── ROIRectangle1.cs │ └── ROIRectangle2.cs └── vs2005 │ ├── HDisplayControl.csproj │ ├── HDisplayControl.sln │ ├── Properties │ ├── Resources.Designer.cs │ └── Resources.resx │ └── Resources │ ├── clear_roi_sel.png │ ├── gen_circle.png │ ├── gen_circular_arc.png │ ├── gen_line.png │ ├── gen_rect1.png │ ├── gen_rect2.png │ ├── roi_op_difference.png │ └── roi_op_union.png ├── HImageAcquisition ├── source │ ├── HImageAcquisition.Designer.cs │ ├── HImageAcquisition.cs │ └── IAParameterEntry.cs └── vs2005 │ ├── HImageAcquisition.csproj │ └── HImageAcquisition.sln ├── examples ├── GrabAndDisplay │ ├── source │ │ ├── GrabAndDisplayForm.Designer.cs │ │ ├── GrabAndDisplayForm.cs │ │ └── GrabAndDisplayForm.resx │ └── vs2005 │ │ ├── Backup │ │ ├── GrabAndDisplay.csproj │ │ ├── GrabAndDisplay.sln │ │ ├── GrabAndDisplayForm.Designer.cs │ │ ├── GrabAndDisplayForm.cs │ │ ├── GrabAndDisplayForm.resx │ │ └── HDisplayControl │ │ │ ├── FunctionPlot.cs │ │ │ ├── GraphicsContext.cs │ │ │ ├── HDisplayControl.Designer.cs │ │ │ ├── HDisplayControl.cs │ │ │ ├── HDisplayControl.csproj │ │ │ ├── HDisplayControl.resx │ │ │ ├── HObjectEntry.cs │ │ │ ├── HWndCtrl.cs │ │ │ ├── Properties │ │ │ ├── Resources.Designer.cs │ │ │ └── Resources.resx │ │ │ ├── ROI.cs │ │ │ ├── ROICircle.cs │ │ │ ├── ROICircularArc.cs │ │ │ ├── ROIController.cs │ │ │ ├── ROILine.cs │ │ │ ├── ROIRectangle1.cs │ │ │ ├── ROIRectangle2.cs │ │ │ └── Resources │ │ │ ├── clear_roi_sel.png │ │ │ ├── gen_circle.png │ │ │ ├── gen_circular_arc.png │ │ │ ├── gen_line.png │ │ │ ├── gen_rect1.png │ │ │ ├── gen_rect2.png │ │ │ ├── roi_op_difference.png │ │ │ └── roi_op_union.png │ │ ├── GrabAndDisplay.csproj │ │ └── GrabAndDisplay.sln └── SimpleGrabApplication │ ├── source │ ├── Form1.Designer.vb │ ├── Form1.resx │ └── Form1.vb │ └── vs2005 │ ├── My Project │ ├── Application.Designer.vb │ ├── Application.myapp │ ├── AssemblyInfo.vb │ ├── Resources.Designer.vb │ ├── Resources.resx │ ├── Settings.Designer.vb │ └── Settings.settings │ ├── SimpleGrabApplication.sln │ └── SimpleGrabApplication.vbproj └── readme.txt /README.md: -------------------------------------------------------------------------------- 1 | # Halcon-codelets 2 | -------------------------------------------------------------------------------- /applications/Calibration/source/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | 4 | // 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | // 9 | [assembly: AssemblyTitle("")] 10 | [assembly: AssemblyDescription("")] 11 | [assembly: AssemblyConfiguration("")] 12 | [assembly: AssemblyCompany("")] 13 | [assembly: AssemblyProduct("")] 14 | [assembly: AssemblyCopyright("")] 15 | [assembly: AssemblyTrademark("")] 16 | [assembly: AssemblyCulture("")] 17 | 18 | // 19 | // Version information for an assembly consists of the following four values: 20 | // 21 | // Major Version 22 | // Minor Version 23 | // Build Number 24 | // Revision 25 | // 26 | // You can specify all the values or you can default the Revision and Build Numbers 27 | // by using the '*' as shown below: 28 | 29 | [assembly: AssemblyVersion("1.0.*")] 30 | 31 | // 32 | // In order to sign your assembly you must specify a key to use. Refer to the 33 | // Microsoft .NET Framework documentation for more information on assembly signing. 34 | // 35 | // Use the attributes below to control which key is used for signing. 36 | // 37 | // Notes: 38 | // (*) If no key is specified, the assembly is not signed. 39 | // (*) KeyName refers to a key that has been installed in the Crypto Service 40 | // Provider (CSP) on your machine. KeyFile refers to a file which contains 41 | // a key. 42 | // (*) If the KeyFile and the KeyName values are both specified, the 43 | // following processing occurs: 44 | // (1) If the KeyName can be found in the CSP, that key is used. 45 | // (2) If the KeyName does not exist and the KeyFile does exist, the key 46 | // in the KeyFile is installed into the CSP and used. 47 | // (*) In order to create a KeyFile, you can use the sn.exe (Strong Name) utility. 48 | // When specifying the KeyFile, the location of the KeyFile should be 49 | // relative to the project output directory which is 50 | // %Project Directory%\obj\. For example, if your KeyFile is 51 | // located in the project directory, you would specify the AssemblyKeyFile 52 | // attribute as [assembly: AssemblyKeyFile("..\\..\\mykey.snk")] 53 | // (*) Delay Signing is an advanced option - see the Microsoft .NET Framework 54 | // documentation for more information on this. 55 | // 56 | [assembly: AssemblyDelaySign(false)] 57 | [assembly: AssemblyKeyFile("")] 58 | [assembly: AssemblyKeyName("")] 59 | -------------------------------------------------------------------------------- /applications/Calibration/source/CalibrationForm.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rtigithub/HALCON-12-codelets/323f337ec58c5d4845be1ae35f3238aab4e6459a/applications/Calibration/source/CalibrationForm.cs -------------------------------------------------------------------------------- /applications/Calibration/vs2005/CalibrationMain.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | Debug 4 | AnyCPU 5 | 8.0.50727 6 | 2.0 7 | {919F241F-30D6-4B18-A87A-C8542EA48663} 8 | WinExe 9 | Properties 10 | CalibrationMain 11 | CalibrationMain 12 | 13 | 14 | true 15 | full 16 | false 17 | bin\Debug\ 18 | DEBUG;TRACE 19 | prompt 20 | 4 21 | 22 | 23 | pdbonly 24 | true 25 | bin\Release\ 26 | TRACE 27 | prompt 28 | 4 29 | 30 | 31 | 32 | False 33 | $(HALCONROOT)\bin\dotnet20\halcondotnet.dll 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | SettingsSingleFileGenerator 45 | Settings.Designer.cs 46 | 47 | 48 | AssemblyInfo.cs 49 | 50 | 51 | CalibrationForm.cs 52 | Form 53 | 54 | 55 | True 56 | Settings.settings 57 | True 58 | 59 | 60 | 61 | 62 | CalibrationForm.resx 63 | CalibrationForm.cs 64 | Designer 65 | 66 | 67 | 68 | 69 | {5B8A5685-BE62-4C1C-9464-E96A98C65744} 70 | CalibrationModule 71 | 72 | 73 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F} 74 | ViewROI 75 | 76 | 77 | 78 | 85 | -------------------------------------------------------------------------------- /applications/Calibration/vs2005/CalibrationMain.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 9.00 3 | # Visual Studio 2005 4 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "CalibrationMain", "CalibrationMain.csproj", "{919F241F-30D6-4B18-A87A-C8542EA48663}" 5 | ProjectSection(ProjectDependencies) = postProject 6 | {5B8A5685-BE62-4C1C-9464-E96A98C65744} = {5B8A5685-BE62-4C1C-9464-E96A98C65744} 7 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F} = {C4F5C5DE-7EA8-47FE-8218-48138F48965F} 8 | EndProjectSection 9 | EndProject 10 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "CalibrationModule", "..\..\..\assistants\Calibration\vs2005\CalibrationModule.csproj", "{5B8A5685-BE62-4C1C-9464-E96A98C65744}" 11 | EndProject 12 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ViewROI", "..\..\..\base\ViewROI\vs2005\ViewROI.csproj", "{C4F5C5DE-7EA8-47FE-8218-48138F48965F}" 13 | EndProject 14 | Global 15 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 16 | Debug|Any CPU = Debug|Any CPU 17 | Release|Any CPU = Release|Any CPU 18 | EndGlobalSection 19 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 20 | {919F241F-30D6-4B18-A87A-C8542EA48663}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 21 | {919F241F-30D6-4B18-A87A-C8542EA48663}.Debug|Any CPU.Build.0 = Debug|Any CPU 22 | {919F241F-30D6-4B18-A87A-C8542EA48663}.Release|Any CPU.ActiveCfg = Release|Any CPU 23 | {919F241F-30D6-4B18-A87A-C8542EA48663}.Release|Any CPU.Build.0 = Release|Any CPU 24 | {5B8A5685-BE62-4C1C-9464-E96A98C65744}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 25 | {5B8A5685-BE62-4C1C-9464-E96A98C65744}.Debug|Any CPU.Build.0 = Debug|Any CPU 26 | {5B8A5685-BE62-4C1C-9464-E96A98C65744}.Release|Any CPU.ActiveCfg = Release|Any CPU 27 | {5B8A5685-BE62-4C1C-9464-E96A98C65744}.Release|Any CPU.Build.0 = Release|Any CPU 28 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 29 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Debug|Any CPU.Build.0 = Debug|Any CPU 30 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Release|Any CPU.ActiveCfg = Release|Any CPU 31 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Release|Any CPU.Build.0 = Release|Any CPU 32 | EndGlobalSection 33 | GlobalSection(SolutionProperties) = preSolution 34 | HideSolutionNode = FALSE 35 | EndGlobalSection 36 | EndGlobal 37 | -------------------------------------------------------------------------------- /applications/Calibration/vs2005/Properties/Settings.Designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // Runtime Version:2.0.50727.1433 5 | // 6 | // Changes to this file may cause incorrect behavior and will be lost if 7 | // the code is regenerated. 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | namespace CalibrationMain.Properties 12 | { 13 | 14 | 15 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] 16 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "8.0.0.0")] 17 | internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase 18 | { 19 | 20 | private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings()))); 21 | 22 | public static Settings Default 23 | { 24 | get 25 | { 26 | return defaultInstance; 27 | } 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /applications/Calibration/vs2005/Properties/Settings.settings: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /applications/GraphicsStack/source/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | 4 | // 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | // 9 | [assembly: AssemblyTitle("")] 10 | [assembly: AssemblyDescription("")] 11 | [assembly: AssemblyConfiguration("")] 12 | [assembly: AssemblyCompany("")] 13 | [assembly: AssemblyProduct("")] 14 | [assembly: AssemblyCopyright("")] 15 | [assembly: AssemblyTrademark("")] 16 | [assembly: AssemblyCulture("")] 17 | 18 | // 19 | // Version information for an assembly consists of the following four values: 20 | // 21 | // Major Version 22 | // Minor Version 23 | // Build Number 24 | // Revision 25 | // 26 | // You can specify all the values or you can default the Revision and Build Numbers 27 | // by using the '*' as shown below: 28 | 29 | [assembly: AssemblyVersion("1.0.*")] 30 | 31 | // 32 | // In order to sign your assembly you must specify a key to use. Refer to the 33 | // Microsoft .NET Framework documentation for more information on assembly signing. 34 | // 35 | // Use the attributes below to control which key is used for signing. 36 | // 37 | // Notes: 38 | // (*) If no key is specified, the assembly is not signed. 39 | // (*) KeyName refers to a key that has been installed in the Crypto Service 40 | // Provider (CSP) on your machine. KeyFile refers to a file which contains 41 | // a key. 42 | // (*) If the KeyFile and the KeyName values are both specified, the 43 | // following processing occurs: 44 | // (1) If the KeyName can be found in the CSP, that key is used. 45 | // (2) If the KeyName does not exist and the KeyFile does exist, the key 46 | // in the KeyFile is installed into the CSP and used. 47 | // (*) In order to create a KeyFile, you can use the sn.exe (Strong Name) utility. 48 | // When specifying the KeyFile, the location of the KeyFile should be 49 | // relative to the project output directory which is 50 | // %Project Directory%\obj\. For example, if your KeyFile is 51 | // located in the project directory, you would specify the AssemblyKeyFile 52 | // attribute as [assembly: AssemblyKeyFile("..\\..\\mykey.snk")] 53 | // (*) Delay Signing is an advanced option - see the Microsoft .NET Framework 54 | // documentation for more information on this. 55 | // 56 | [assembly: AssemblyDelaySign(false)] 57 | [assembly: AssemblyKeyFile("")] 58 | [assembly: AssemblyKeyName("")] 59 | -------------------------------------------------------------------------------- /applications/GraphicsStack/source/GraphicsStackForm.resx: -------------------------------------------------------------------------------- 1 | 2 | 3 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | text/microsoft-resx 89 | 90 | 91 | 1.3 92 | 93 | 94 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=1.0.3300.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 95 | 96 | 97 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=1.0.3300.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 98 | 99 | 100 | 101 | 102 | 103 | GraphicsStackForm 104 | 105 | -------------------------------------------------------------------------------- /applications/GraphicsStack/vs2005/GraphicsStack.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | Debug 4 | AnyCPU 5 | 8.0.50727 6 | 2.0 7 | {C4D9D0C3-13C3-4111-A0F2-36A50DCA79F1} 8 | WinExe 9 | Properties 10 | GraphicsStack 11 | GraphicsStack 12 | 13 | 14 | true 15 | full 16 | false 17 | bin\Debug\ 18 | DEBUG;TRACE 19 | prompt 20 | 4 21 | 22 | 23 | pdbonly 24 | true 25 | bin\Release\ 26 | TRACE 27 | prompt 28 | 4 29 | 30 | 31 | 32 | False 33 | $(HALCONROOT)\bin\dotnet20\halcondotnet.dll 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | SettingsSingleFileGenerator 45 | Settings.Designer.cs 46 | 47 | 48 | AssemblyInfo.cs 49 | 50 | 51 | GraphicsStackForm.cs 52 | Form 53 | 54 | 55 | True 56 | Settings.settings 57 | True 58 | 59 | 60 | 61 | 62 | GraphicsStackForm.resx 63 | GraphicsStackForm.cs 64 | Designer 65 | 66 | 67 | 68 | 69 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F} 70 | ViewROI 71 | 72 | 73 | 74 | 81 | -------------------------------------------------------------------------------- /applications/GraphicsStack/vs2005/GraphicsStack.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 9.00 3 | # Visual Studio 2005 4 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "GraphicsStack", "GraphicsStack.csproj", "{C4D9D0C3-13C3-4111-A0F2-36A50DCA79F1}" 5 | ProjectSection(ProjectDependencies) = postProject 6 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F} = {C4F5C5DE-7EA8-47FE-8218-48138F48965F} 7 | EndProjectSection 8 | EndProject 9 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ViewROI", "..\..\..\base\ViewROI\vs2005\ViewROI.csproj", "{C4F5C5DE-7EA8-47FE-8218-48138F48965F}" 10 | EndProject 11 | Global 12 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 13 | Debug|Any CPU = Debug|Any CPU 14 | Release|Any CPU = Release|Any CPU 15 | EndGlobalSection 16 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 17 | {C4D9D0C3-13C3-4111-A0F2-36A50DCA79F1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 18 | {C4D9D0C3-13C3-4111-A0F2-36A50DCA79F1}.Debug|Any CPU.Build.0 = Debug|Any CPU 19 | {C4D9D0C3-13C3-4111-A0F2-36A50DCA79F1}.Release|Any CPU.ActiveCfg = Release|Any CPU 20 | {C4D9D0C3-13C3-4111-A0F2-36A50DCA79F1}.Release|Any CPU.Build.0 = Release|Any CPU 21 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 22 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Debug|Any CPU.Build.0 = Debug|Any CPU 23 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Release|Any CPU.ActiveCfg = Release|Any CPU 24 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Release|Any CPU.Build.0 = Release|Any CPU 25 | EndGlobalSection 26 | GlobalSection(SolutionProperties) = preSolution 27 | HideSolutionNode = FALSE 28 | EndGlobalSection 29 | EndGlobal 30 | -------------------------------------------------------------------------------- /applications/GraphicsStack/vs2005/Properties/Settings.Designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // Runtime Version:2.0.50727.832 5 | // 6 | // Changes to this file may cause incorrect behavior and will be lost if 7 | // the code is regenerated. 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | namespace GraphicsStack.Properties 12 | { 13 | 14 | 15 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] 16 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "8.0.0.0")] 17 | internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase 18 | { 19 | 20 | private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings()))); 21 | 22 | public static Settings Default 23 | { 24 | get 25 | { 26 | return defaultInstance; 27 | } 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /applications/GraphicsStack/vs2005/Properties/Settings.settings: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /applications/GraphicsWindow/source/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | 4 | // 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | // 9 | [assembly: AssemblyTitle("")] 10 | [assembly: AssemblyDescription("")] 11 | [assembly: AssemblyConfiguration("")] 12 | [assembly: AssemblyCompany("")] 13 | [assembly: AssemblyProduct("")] 14 | [assembly: AssemblyCopyright("")] 15 | [assembly: AssemblyTrademark("")] 16 | [assembly: AssemblyCulture("")] 17 | 18 | // 19 | // Version information for an assembly consists of the following four values: 20 | // 21 | // Major Version 22 | // Minor Version 23 | // Build Number 24 | // Revision 25 | // 26 | // You can specify all the values or you can default the Revision and Build Numbers 27 | // by using the '*' as shown below: 28 | 29 | [assembly: AssemblyVersion("1.0.*")] 30 | 31 | // 32 | // In order to sign your assembly you must specify a key to use. Refer to the 33 | // Microsoft .NET Framework documentation for more information on assembly signing. 34 | // 35 | // Use the attributes below to control which key is used for signing. 36 | // 37 | // Notes: 38 | // (*) If no key is specified, the assembly is not signed. 39 | // (*) KeyName refers to a key that has been installed in the Crypto Service 40 | // Provider (CSP) on your machine. KeyFile refers to a file which contains 41 | // a key. 42 | // (*) If the KeyFile and the KeyName values are both specified, the 43 | // following processing occurs: 44 | // (1) If the KeyName can be found in the CSP, that key is used. 45 | // (2) If the KeyName does not exist and the KeyFile does exist, the key 46 | // in the KeyFile is installed into the CSP and used. 47 | // (*) In order to create a KeyFile, you can use the sn.exe (Strong Name) utility. 48 | // When specifying the KeyFile, the location of the KeyFile should be 49 | // relative to the project output directory which is 50 | // %Project Directory%\obj\. For example, if your KeyFile is 51 | // located in the project directory, you would specify the AssemblyKeyFile 52 | // attribute as [assembly: AssemblyKeyFile("..\\..\\mykey.snk")] 53 | // (*) Delay Signing is an advanced option - see the Microsoft .NET Framework 54 | // documentation for more information on this. 55 | // 56 | [assembly: AssemblyDelaySign(false)] 57 | [assembly: AssemblyKeyFile("")] 58 | [assembly: AssemblyKeyName("")] 59 | -------------------------------------------------------------------------------- /applications/GraphicsWindow/vs2005/GraphicsWindow.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | Debug 4 | AnyCPU 5 | 8.0.50727 6 | 2.0 7 | {03D52CE8-076F-4869-9762-E9C9B2E1F3E8} 8 | WinExe 9 | Properties 10 | GraphicsWindow 11 | GraphicsWindow 12 | 13 | 14 | true 15 | full 16 | false 17 | bin\Debug\ 18 | DEBUG;TRACE 19 | prompt 20 | 4 21 | 22 | 23 | pdbonly 24 | true 25 | bin\Release\ 26 | TRACE 27 | prompt 28 | 4 29 | 30 | 31 | 32 | False 33 | $(HALCONROOT)\bin\dotnet20\halcondotnet.dll 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | AssemblyInfo.cs 45 | 46 | 47 | GraphicsWindowForm.cs 48 | Form 49 | 50 | 51 | GraphicsWindowForm.resx 52 | GraphicsWindowForm.cs 53 | Designer 54 | 55 | 56 | SettingsSingleFileGenerator 57 | Settings.Designer.cs 58 | 59 | 60 | True 61 | Settings.settings 62 | True 63 | 64 | 65 | 66 | 67 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F} 68 | ViewROI 69 | 70 | 71 | 72 | 79 | -------------------------------------------------------------------------------- /applications/GraphicsWindow/vs2005/GraphicsWindow.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 9.00 3 | # Visual Studio 2005 4 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "GraphicsWindow", "GraphicsWindow.csproj", "{03D52CE8-076F-4869-9762-E9C9B2E1F3E8}" 5 | ProjectSection(ProjectDependencies) = postProject 6 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F} = {C4F5C5DE-7EA8-47FE-8218-48138F48965F} 7 | EndProjectSection 8 | EndProject 9 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ViewROI", "..\..\..\base\ViewROI\vs2005\ViewROI.csproj", "{C4F5C5DE-7EA8-47FE-8218-48138F48965F}" 10 | EndProject 11 | Global 12 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 13 | Debug|Any CPU = Debug|Any CPU 14 | Release|Any CPU = Release|Any CPU 15 | EndGlobalSection 16 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 17 | {03D52CE8-076F-4869-9762-E9C9B2E1F3E8}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 18 | {03D52CE8-076F-4869-9762-E9C9B2E1F3E8}.Debug|Any CPU.Build.0 = Debug|Any CPU 19 | {03D52CE8-076F-4869-9762-E9C9B2E1F3E8}.Release|Any CPU.ActiveCfg = Release|Any CPU 20 | {03D52CE8-076F-4869-9762-E9C9B2E1F3E8}.Release|Any CPU.Build.0 = Release|Any CPU 21 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 22 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Debug|Any CPU.Build.0 = Debug|Any CPU 23 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Release|Any CPU.ActiveCfg = Release|Any CPU 24 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Release|Any CPU.Build.0 = Release|Any CPU 25 | EndGlobalSection 26 | GlobalSection(SolutionProperties) = preSolution 27 | HideSolutionNode = FALSE 28 | EndGlobalSection 29 | EndGlobal 30 | -------------------------------------------------------------------------------- /applications/GraphicsWindow/vs2005/Properties/Settings.Designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // Runtime Version:2.0.50727.832 5 | // 6 | // Changes to this file may cause incorrect behavior and will be lost if 7 | // the code is regenerated. 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | namespace GraphicsWindow.Properties 12 | { 13 | 14 | 15 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] 16 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "8.0.0.0")] 17 | internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase 18 | { 19 | 20 | private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings()))); 21 | 22 | public static Settings Default 23 | { 24 | get 25 | { 26 | return defaultInstance; 27 | } 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /applications/GraphicsWindow/vs2005/Properties/Settings.settings: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /applications/InteractiveROI/source/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | 4 | // 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | // 9 | [assembly: AssemblyTitle("")] 10 | [assembly: AssemblyDescription("")] 11 | [assembly: AssemblyConfiguration("")] 12 | [assembly: AssemblyCompany("MVTec GmbH")] 13 | [assembly: AssemblyProduct("HALCON Application Examples")] 14 | [assembly: AssemblyCopyright("")] 15 | [assembly: AssemblyTrademark("")] 16 | [assembly: AssemblyCulture("")] 17 | 18 | // 19 | // Version information for an assembly consists of the following four values: 20 | // 21 | // Major Version 22 | // Minor Version 23 | // Build Number 24 | // Revision 25 | // 26 | // You can specify all the values or you can default the Revision and Build Numbers 27 | // by using the '*' as shown below: 28 | 29 | [assembly: AssemblyVersion("1.0.*")] 30 | 31 | // 32 | // In order to sign your assembly you must specify a key to use. Refer to the 33 | // Microsoft .NET Framework documentation for more information on assembly signing. 34 | // 35 | // Use the attributes below to control which key is used for signing. 36 | // 37 | // Notes: 38 | // (*) If no key is specified, the assembly is not signed. 39 | // (*) KeyName refers to a key that has been installed in the Crypto Service 40 | // Provider (CSP) on your machine. KeyFile refers to a file which contains 41 | // a key. 42 | // (*) If the KeyFile and the KeyName values are both specified, the 43 | // following processing occurs: 44 | // (1) If the KeyName can be found in the CSP, that key is used. 45 | // (2) If the KeyName does not exist and the KeyFile does exist, the key 46 | // in the KeyFile is installed into the CSP and used. 47 | // (*) In order to create a KeyFile, you can use the sn.exe (Strong Name) utility. 48 | // When specifying the KeyFile, the location of the KeyFile should be 49 | // relative to the project output directory which is 50 | // %Project Directory%\obj\. For example, if your KeyFile is 51 | // located in the project directory, you would specify the AssemblyKeyFile 52 | // attribute as [assembly: AssemblyKeyFile("..\\..\\mykey.snk")] 53 | // (*) Delay Signing is an advanced option - see the Microsoft .NET Framework 54 | // documentation for more information on this. 55 | // 56 | [assembly: AssemblyDelaySign(false)] 57 | [assembly: AssemblyKeyFile("")] 58 | [assembly: AssemblyKeyName("")] 59 | -------------------------------------------------------------------------------- /applications/InteractiveROI/vs2005/InteractiveROI.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | Debug 4 | AnyCPU 5 | 8.0.50727 6 | 2.0 7 | {B1DF112F-0212-412C-A6F5-0E93C1C74BB2} 8 | WinExe 9 | Properties 10 | InteractiveROI 11 | InteractiveROI 12 | 13 | 14 | true 15 | full 16 | false 17 | bin\Debug\ 18 | DEBUG;TRACE 19 | prompt 20 | 4 21 | 22 | 23 | pdbonly 24 | true 25 | bin\Release\ 26 | TRACE 27 | prompt 28 | 4 29 | 30 | 31 | 32 | False 33 | $(HALCONROOT)\bin\dotnet20\halcondotnet.dll 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | SettingsSingleFileGenerator 45 | Settings.Designer.cs 46 | 47 | 48 | AssemblyInfo.cs 49 | 50 | 51 | InteractROIForm.cs 52 | Form 53 | 54 | 55 | True 56 | Settings.settings 57 | True 58 | 59 | 60 | 61 | 62 | InteractROIForm.resx 63 | InteractROIForm.cs 64 | Designer 65 | 66 | 67 | 68 | 69 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F} 70 | ViewROI 71 | 72 | 73 | 74 | 81 | -------------------------------------------------------------------------------- /applications/InteractiveROI/vs2005/InteractiveROI.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 9.00 3 | # Visual Studio 2005 4 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "InteractiveROI", "InteractiveROI.csproj", "{B1DF112F-0212-412C-A6F5-0E93C1C74BB2}" 5 | ProjectSection(ProjectDependencies) = postProject 6 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F} = {C4F5C5DE-7EA8-47FE-8218-48138F48965F} 7 | EndProjectSection 8 | EndProject 9 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ViewROI", "..\..\..\base\ViewROI\vs2005\ViewROI.csproj", "{C4F5C5DE-7EA8-47FE-8218-48138F48965F}" 10 | EndProject 11 | Global 12 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 13 | Debug|Any CPU = Debug|Any CPU 14 | Release|Any CPU = Release|Any CPU 15 | EndGlobalSection 16 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 17 | {B1DF112F-0212-412C-A6F5-0E93C1C74BB2}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 18 | {B1DF112F-0212-412C-A6F5-0E93C1C74BB2}.Debug|Any CPU.Build.0 = Debug|Any CPU 19 | {B1DF112F-0212-412C-A6F5-0E93C1C74BB2}.Release|Any CPU.ActiveCfg = Release|Any CPU 20 | {B1DF112F-0212-412C-A6F5-0E93C1C74BB2}.Release|Any CPU.Build.0 = Release|Any CPU 21 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 22 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Debug|Any CPU.Build.0 = Debug|Any CPU 23 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Release|Any CPU.ActiveCfg = Release|Any CPU 24 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Release|Any CPU.Build.0 = Release|Any CPU 25 | EndGlobalSection 26 | GlobalSection(SolutionProperties) = preSolution 27 | HideSolutionNode = FALSE 28 | EndGlobalSection 29 | EndGlobal 30 | -------------------------------------------------------------------------------- /applications/InteractiveROI/vs2005/Properties/Settings.Designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // Runtime Version:2.0.50727.1433 5 | // 6 | // Changes to this file may cause incorrect behavior and will be lost if 7 | // the code is regenerated. 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | namespace InteractiveROI.Properties { 12 | 13 | 14 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] 15 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "8.0.0.0")] 16 | internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase { 17 | 18 | private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings()))); 19 | 20 | public static Settings Default { 21 | get { 22 | return defaultInstance; 23 | } 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /applications/InteractiveROI/vs2005/Properties/Settings.settings: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /applications/Matching/source/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | 4 | // 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | // 9 | [assembly: AssemblyTitle("")] 10 | [assembly: AssemblyDescription("")] 11 | [assembly: AssemblyConfiguration("")] 12 | [assembly: AssemblyCompany("")] 13 | [assembly: AssemblyProduct("")] 14 | [assembly: AssemblyCopyright("")] 15 | [assembly: AssemblyTrademark("")] 16 | [assembly: AssemblyCulture("")] 17 | 18 | // 19 | // Version information for an assembly consists of the following four values: 20 | // 21 | // Major Version 22 | // Minor Version 23 | // Build Number 24 | // Revision 25 | // 26 | // You can specify all the values or you can default the Revision and Build Numbers 27 | // by using the '*' as shown below: 28 | 29 | [assembly: AssemblyVersion("1.0.*")] 30 | 31 | // 32 | // In order to sign your assembly you must specify a key to use. Refer to the 33 | // Microsoft .NET Framework documentation for more information on assembly signing. 34 | // 35 | // Use the attributes below to control which key is used for signing. 36 | // 37 | // Notes: 38 | // (*) If no key is specified, the assembly is not signed. 39 | // (*) KeyName refers to a key that has been installed in the Crypto Service 40 | // Provider (CSP) on your machine. KeyFile refers to a file which contains 41 | // a key. 42 | // (*) If the KeyFile and the KeyName values are both specified, the 43 | // following processing occurs: 44 | // (1) If the KeyName can be found in the CSP, that key is used. 45 | // (2) If the KeyName does not exist and the KeyFile does exist, the key 46 | // in the KeyFile is installed into the CSP and used. 47 | // (*) In order to create a KeyFile, you can use the sn.exe (Strong Name) utility. 48 | // When specifying the KeyFile, the location of the KeyFile should be 49 | // relative to the project output directory which is 50 | // %Project Directory%\obj\. For example, if your KeyFile is 51 | // located in the project directory, you would specify the AssemblyKeyFile 52 | // attribute as [assembly: AssemblyKeyFile("..\\..\\mykey.snk")] 53 | // (*) Delay Signing is an advanced option - see the Microsoft .NET Framework 54 | // documentation for more information on this. 55 | // 56 | [assembly: AssemblyDelaySign(false)] 57 | [assembly: AssemblyKeyFile("")] 58 | [assembly: AssemblyKeyName("")] 59 | -------------------------------------------------------------------------------- /applications/Matching/vs2005/MatchingMain.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | Debug 4 | AnyCPU 5 | 8.0.50727 6 | 2.0 7 | {ABF0EAE9-0A9F-4F06-9C28-C030AEB4F9E8} 8 | WinExe 9 | Properties 10 | MatchingMain 11 | MatchingMain 12 | 13 | 14 | true 15 | full 16 | false 17 | bin\Debug\ 18 | DEBUG;TRACE 19 | prompt 20 | 4 21 | 22 | 23 | pdbonly 24 | true 25 | bin\Release\ 26 | TRACE 27 | prompt 28 | 4 29 | 30 | 31 | 32 | False 33 | $(HALCONROOT)\bin\dotnet20\halcondotnet.dll 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | SettingsSingleFileGenerator 45 | Settings.Designer.cs 46 | 47 | 48 | AssemblyInfo.cs 49 | 50 | 51 | MatchingForm.cs 52 | Form 53 | 54 | 55 | True 56 | Settings.settings 57 | True 58 | 59 | 60 | 61 | 62 | MatchingForm.resx 63 | MatchingForm.cs 64 | Designer 65 | 66 | 67 | 68 | 69 | {87035C5C-B4E6-4B94-A7B9-5031A34DBFB0} 70 | MatchingModule 71 | 72 | 73 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F} 74 | ViewROI 75 | 76 | 77 | 78 | 85 | -------------------------------------------------------------------------------- /applications/Matching/vs2005/MatchingMain.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 9.00 3 | # Visual Studio 2005 4 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MatchingMain", "MatchingMain.csproj", "{ABF0EAE9-0A9F-4F06-9C28-C030AEB4F9E8}" 5 | ProjectSection(ProjectDependencies) = postProject 6 | {87035C5C-B4E6-4B94-A7B9-5031A34DBFB0} = {87035C5C-B4E6-4B94-A7B9-5031A34DBFB0} 7 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F} = {C4F5C5DE-7EA8-47FE-8218-48138F48965F} 8 | EndProjectSection 9 | EndProject 10 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MatchingModule", "..\..\..\assistants\Matching\vs2005\MatchingModule.csproj", "{87035C5C-B4E6-4B94-A7B9-5031A34DBFB0}" 11 | EndProject 12 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ViewROI", "..\..\..\base\ViewROI\vs2005\ViewROI.csproj", "{C4F5C5DE-7EA8-47FE-8218-48138F48965F}" 13 | EndProject 14 | Global 15 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 16 | Debug|Any CPU = Debug|Any CPU 17 | Release|Any CPU = Release|Any CPU 18 | EndGlobalSection 19 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 20 | {ABF0EAE9-0A9F-4F06-9C28-C030AEB4F9E8}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 21 | {ABF0EAE9-0A9F-4F06-9C28-C030AEB4F9E8}.Debug|Any CPU.Build.0 = Debug|Any CPU 22 | {ABF0EAE9-0A9F-4F06-9C28-C030AEB4F9E8}.Release|Any CPU.ActiveCfg = Release|Any CPU 23 | {ABF0EAE9-0A9F-4F06-9C28-C030AEB4F9E8}.Release|Any CPU.Build.0 = Release|Any CPU 24 | {87035C5C-B4E6-4B94-A7B9-5031A34DBFB0}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 25 | {87035C5C-B4E6-4B94-A7B9-5031A34DBFB0}.Debug|Any CPU.Build.0 = Debug|Any CPU 26 | {87035C5C-B4E6-4B94-A7B9-5031A34DBFB0}.Release|Any CPU.ActiveCfg = Release|Any CPU 27 | {87035C5C-B4E6-4B94-A7B9-5031A34DBFB0}.Release|Any CPU.Build.0 = Release|Any CPU 28 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 29 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Debug|Any CPU.Build.0 = Debug|Any CPU 30 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Release|Any CPU.ActiveCfg = Release|Any CPU 31 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Release|Any CPU.Build.0 = Release|Any CPU 32 | EndGlobalSection 33 | GlobalSection(SolutionProperties) = preSolution 34 | HideSolutionNode = FALSE 35 | EndGlobalSection 36 | EndGlobal 37 | -------------------------------------------------------------------------------- /applications/Matching/vs2005/Properties/Settings.Designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // Runtime Version:2.0.50727.1433 5 | // 6 | // Changes to this file may cause incorrect behavior and will be lost if 7 | // the code is regenerated. 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | namespace MatchingMain.Properties { 12 | 13 | 14 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] 15 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "8.0.0.0")] 16 | internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase { 17 | 18 | private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings()))); 19 | 20 | public static Settings Default { 21 | get { 22 | return defaultInstance; 23 | } 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /applications/Matching/vs2005/Properties/Settings.settings: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /applications/Measure/source/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | 4 | // 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | // 9 | [assembly: AssemblyTitle("")] 10 | [assembly: AssemblyDescription("")] 11 | [assembly: AssemblyConfiguration("")] 12 | [assembly: AssemblyCompany("")] 13 | [assembly: AssemblyProduct("")] 14 | [assembly: AssemblyCopyright("")] 15 | [assembly: AssemblyTrademark("")] 16 | [assembly: AssemblyCulture("")] 17 | 18 | // 19 | // Version information for an assembly consists of the following four values: 20 | // 21 | // Major Version 22 | // Minor Version 23 | // Build Number 24 | // Revision 25 | // 26 | // You can specify all the values or you can default the Revision and Build Numbers 27 | // by using the '*' as shown below: 28 | 29 | [assembly: AssemblyVersion("1.0.*")] 30 | 31 | // 32 | // In order to sign your assembly you must specify a key to use. Refer to the 33 | // Microsoft .NET Framework documentation for more information on assembly signing. 34 | // 35 | // Use the attributes below to control which key is used for signing. 36 | // 37 | // Notes: 38 | // (*) If no key is specified, the assembly is not signed. 39 | // (*) KeyName refers to a key that has been installed in the Crypto Service 40 | // Provider (CSP) on your machine. KeyFile refers to a file which contains 41 | // a key. 42 | // (*) If the KeyFile and the KeyName values are both specified, the 43 | // following processing occurs: 44 | // (1) If the KeyName can be found in the CSP, that key is used. 45 | // (2) If the KeyName does not exist and the KeyFile does exist, the key 46 | // in the KeyFile is installed into the CSP and used. 47 | // (*) In order to create a KeyFile, you can use the sn.exe (Strong Name) utility. 48 | // When specifying the KeyFile, the location of the KeyFile should be 49 | // relative to the project output directory which is 50 | // %Project Directory%\obj\. For example, if your KeyFile is 51 | // located in the project directory, you would specify the AssemblyKeyFile 52 | // attribute as [assembly: AssemblyKeyFile("..\\..\\mykey.snk")] 53 | // (*) Delay Signing is an advanced option - see the Microsoft .NET Framework 54 | // documentation for more information on this. 55 | // 56 | [assembly: AssemblyDelaySign(false)] 57 | [assembly: AssemblyKeyFile("")] 58 | [assembly: AssemblyKeyName("")] 59 | -------------------------------------------------------------------------------- /applications/Measure/source/MeasureForm.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rtigithub/HALCON-12-codelets/323f337ec58c5d4845be1ae35f3238aab4e6459a/applications/Measure/source/MeasureForm.cs -------------------------------------------------------------------------------- /applications/Measure/vs2005/MeasureMain.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | Debug 4 | AnyCPU 5 | 8.0.50727 6 | 2.0 7 | {031D3A45-0317-4ABD-B9F6-605B3AA4557F} 8 | WinExe 9 | Properties 10 | MeasureMain 11 | MeasureMain 12 | 13 | 14 | true 15 | full 16 | false 17 | bin\Debug\ 18 | DEBUG;TRACE 19 | prompt 20 | 4 21 | 22 | 23 | pdbonly 24 | true 25 | bin\Release\ 26 | TRACE 27 | prompt 28 | 4 29 | 30 | 31 | 32 | False 33 | $(HALCONROOT)\bin\dotnet20\halcondotnet.dll 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | AssemblyInfo.cs 45 | 46 | 47 | MeasureForm.cs 48 | Form 49 | 50 | 51 | MeasureForm.resx 52 | MeasureForm.cs 53 | Designer 54 | 55 | 56 | SettingsSingleFileGenerator 57 | Settings.Designer.cs 58 | 59 | 60 | True 61 | Settings.settings 62 | True 63 | 64 | 65 | 66 | 67 | {A5B3B77C-7F30-4109-8EF6-8CE30DD1317E} 68 | MeasureModule 69 | 70 | 71 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F} 72 | ViewROI 73 | 74 | 75 | 76 | 83 | -------------------------------------------------------------------------------- /applications/Measure/vs2005/MeasureMain.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 9.00 3 | # Visual Studio 2005 4 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MeasureMain", "MeasureMain.csproj", "{031D3A45-0317-4ABD-B9F6-605B3AA4557F}" 5 | ProjectSection(ProjectDependencies) = postProject 6 | {A5B3B77C-7F30-4109-8EF6-8CE30DD1317E} = {A5B3B77C-7F30-4109-8EF6-8CE30DD1317E} 7 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F} = {C4F5C5DE-7EA8-47FE-8218-48138F48965F} 8 | EndProjectSection 9 | EndProject 10 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ViewROI", "..\..\..\base\ViewROI\vs2005\ViewROI.csproj", "{C4F5C5DE-7EA8-47FE-8218-48138F48965F}" 11 | EndProject 12 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MeasureModule", "..\..\..\assistants\Measure\vs2005\MeasureModule.csproj", "{A5B3B77C-7F30-4109-8EF6-8CE30DD1317E}" 13 | EndProject 14 | Global 15 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 16 | Debug|Any CPU = Debug|Any CPU 17 | Release|Any CPU = Release|Any CPU 18 | EndGlobalSection 19 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 20 | {031D3A45-0317-4ABD-B9F6-605B3AA4557F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 21 | {031D3A45-0317-4ABD-B9F6-605B3AA4557F}.Debug|Any CPU.Build.0 = Debug|Any CPU 22 | {031D3A45-0317-4ABD-B9F6-605B3AA4557F}.Release|Any CPU.ActiveCfg = Release|Any CPU 23 | {031D3A45-0317-4ABD-B9F6-605B3AA4557F}.Release|Any CPU.Build.0 = Release|Any CPU 24 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 25 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Debug|Any CPU.Build.0 = Debug|Any CPU 26 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Release|Any CPU.ActiveCfg = Release|Any CPU 27 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Release|Any CPU.Build.0 = Release|Any CPU 28 | {A5B3B77C-7F30-4109-8EF6-8CE30DD1317E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 29 | {A5B3B77C-7F30-4109-8EF6-8CE30DD1317E}.Debug|Any CPU.Build.0 = Debug|Any CPU 30 | {A5B3B77C-7F30-4109-8EF6-8CE30DD1317E}.Release|Any CPU.ActiveCfg = Release|Any CPU 31 | {A5B3B77C-7F30-4109-8EF6-8CE30DD1317E}.Release|Any CPU.Build.0 = Release|Any CPU 32 | EndGlobalSection 33 | GlobalSection(SolutionProperties) = preSolution 34 | HideSolutionNode = FALSE 35 | EndGlobalSection 36 | EndGlobal 37 | -------------------------------------------------------------------------------- /applications/Measure/vs2005/Properties/Settings.Designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // Runtime Version:2.0.50727.3082 5 | // 6 | // Changes to this file may cause incorrect behavior and will be lost if 7 | // the code is regenerated. 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | namespace MeasureMain.Properties 12 | { 13 | 14 | 15 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] 16 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "8.0.0.0")] 17 | internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase 18 | { 19 | 20 | private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings()))); 21 | 22 | public static Settings Default 23 | { 24 | get 25 | { 26 | return defaultInstance; 27 | } 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /applications/Measure/vs2005/Properties/Settings.settings: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /applications/SmartWindow1/source/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | 4 | // 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | // 9 | [assembly: AssemblyTitle("")] 10 | [assembly: AssemblyDescription("")] 11 | [assembly: AssemblyConfiguration("")] 12 | [assembly: AssemblyCompany("")] 13 | [assembly: AssemblyProduct("")] 14 | [assembly: AssemblyCopyright("")] 15 | [assembly: AssemblyTrademark("")] 16 | [assembly: AssemblyCulture("")] 17 | 18 | // 19 | // Version information for an assembly consists of the following four values: 20 | // 21 | // Major Version 22 | // Minor Version 23 | // Build Number 24 | // Revision 25 | // 26 | // You can specify all the values or you can default the Revision and Build Numbers 27 | // by using the '*' as shown below: 28 | 29 | [assembly: AssemblyVersion("1.0.*")] 30 | 31 | // 32 | // In order to sign your assembly you must specify a key to use. Refer to the 33 | // Microsoft .NET Framework documentation for more information on assembly signing. 34 | // 35 | // Use the attributes below to control which key is used for signing. 36 | // 37 | // Notes: 38 | // (*) If no key is specified, the assembly is not signed. 39 | // (*) KeyName refers to a key that has been installed in the Crypto Service 40 | // Provider (CSP) on your machine. KeyFile refers to a file which contains 41 | // a key. 42 | // (*) If the KeyFile and the KeyName values are both specified, the 43 | // following processing occurs: 44 | // (1) If the KeyName can be found in the CSP, that key is used. 45 | // (2) If the KeyName does not exist and the KeyFile does exist, the key 46 | // in the KeyFile is installed into the CSP and used. 47 | // (*) In order to create a KeyFile, you can use the sn.exe (Strong Name) utility. 48 | // When specifying the KeyFile, the location of the KeyFile should be 49 | // relative to the project output directory which is 50 | // %Project Directory%\obj\. For example, if your KeyFile is 51 | // located in the project directory, you would specify the AssemblyKeyFile 52 | // attribute as [assembly: AssemblyKeyFile("..\\..\\mykey.snk")] 53 | // (*) Delay Signing is an advanced option - see the Microsoft .NET Framework 54 | // documentation for more information on this. 55 | // 56 | [assembly: AssemblyDelaySign(false)] 57 | [assembly: AssemblyKeyFile("")] 58 | [assembly: AssemblyKeyName("")] 59 | -------------------------------------------------------------------------------- /applications/SmartWindow1/vs2005/Properties/Settings.Designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // Runtime Version:2.0.50727.1433 5 | // 6 | // Changes to this file may cause incorrect behavior and will be lost if 7 | // the code is regenerated. 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | namespace SmartWindow1.Properties 12 | { 13 | 14 | 15 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] 16 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "8.0.0.0")] 17 | internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase 18 | { 19 | 20 | private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings()))); 21 | 22 | public static Settings Default 23 | { 24 | get 25 | { 26 | return defaultInstance; 27 | } 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /applications/SmartWindow1/vs2005/Properties/Settings.settings: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /applications/SmartWindow1/vs2005/SmartWindow1.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | Debug 4 | AnyCPU 5 | 8.0.50727 6 | 2.0 7 | {1CA974A4-E3A7-414F-878C-727372E852EC} 8 | WinExe 9 | Properties 10 | SmartWindow1 11 | SmartWindow1 12 | 13 | 14 | true 15 | full 16 | false 17 | bin\Debug\ 18 | DEBUG;TRACE 19 | prompt 20 | 4 21 | 22 | 23 | pdbonly 24 | true 25 | bin\Release\ 26 | TRACE 27 | prompt 28 | 4 29 | 30 | 31 | 32 | False 33 | $(HALCONROOT)\bin\dotnet20\halcondotnet.dll 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | SettingsSingleFileGenerator 45 | Settings.Designer.cs 46 | 47 | 48 | AssemblyInfo.cs 49 | 50 | 51 | SmartWindow1Form.cs 52 | Form 53 | 54 | 55 | True 56 | Settings.settings 57 | True 58 | 59 | 60 | 61 | 62 | SmartWindow1Form.resx 63 | SmartWindow1Form.cs 64 | Designer 65 | 66 | 67 | 68 | 69 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F} 70 | ViewROI 71 | 72 | 73 | 74 | 81 | -------------------------------------------------------------------------------- /applications/SmartWindow1/vs2005/SmartWindow1.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 9.00 3 | # Visual Studio 2005 4 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SmartWindow1", "SmartWindow1.csproj", "{1CA974A4-E3A7-414F-878C-727372E852EC}" 5 | ProjectSection(ProjectDependencies) = postProject 6 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F} = {C4F5C5DE-7EA8-47FE-8218-48138F48965F} 7 | EndProjectSection 8 | EndProject 9 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ViewROI", "..\..\..\base\ViewROI\vs2005\ViewROI.csproj", "{C4F5C5DE-7EA8-47FE-8218-48138F48965F}" 10 | EndProject 11 | Global 12 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 13 | Debug|Any CPU = Debug|Any CPU 14 | Release|Any CPU = Release|Any CPU 15 | EndGlobalSection 16 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 17 | {1CA974A4-E3A7-414F-878C-727372E852EC}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 18 | {1CA974A4-E3A7-414F-878C-727372E852EC}.Debug|Any CPU.Build.0 = Debug|Any CPU 19 | {1CA974A4-E3A7-414F-878C-727372E852EC}.Release|Any CPU.ActiveCfg = Release|Any CPU 20 | {1CA974A4-E3A7-414F-878C-727372E852EC}.Release|Any CPU.Build.0 = Release|Any CPU 21 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 22 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Debug|Any CPU.Build.0 = Debug|Any CPU 23 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Release|Any CPU.ActiveCfg = Release|Any CPU 24 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Release|Any CPU.Build.0 = Release|Any CPU 25 | EndGlobalSection 26 | GlobalSection(SolutionProperties) = preSolution 27 | HideSolutionNode = FALSE 28 | EndGlobalSection 29 | EndGlobal 30 | -------------------------------------------------------------------------------- /applications/SmartWindow2/source/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | 4 | // 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | // 9 | [assembly: AssemblyTitle("")] 10 | [assembly: AssemblyDescription("")] 11 | [assembly: AssemblyConfiguration("")] 12 | [assembly: AssemblyCompany("")] 13 | [assembly: AssemblyProduct("")] 14 | [assembly: AssemblyCopyright("")] 15 | [assembly: AssemblyTrademark("")] 16 | [assembly: AssemblyCulture("")] 17 | 18 | // 19 | // Version information for an assembly consists of the following four values: 20 | // 21 | // Major Version 22 | // Minor Version 23 | // Build Number 24 | // Revision 25 | // 26 | // You can specify all the values or you can default the Revision and Build Numbers 27 | // by using the '*' as shown below: 28 | 29 | [assembly: AssemblyVersion("1.0.*")] 30 | 31 | // 32 | // In order to sign your assembly you must specify a key to use. Refer to the 33 | // Microsoft .NET Framework documentation for more information on assembly signing. 34 | // 35 | // Use the attributes below to control which key is used for signing. 36 | // 37 | // Notes: 38 | // (*) If no key is specified, the assembly is not signed. 39 | // (*) KeyName refers to a key that has been installed in the Crypto Service 40 | // Provider (CSP) on your machine. KeyFile refers to a file which contains 41 | // a key. 42 | // (*) If the KeyFile and the KeyName values are both specified, the 43 | // following processing occurs: 44 | // (1) If the KeyName can be found in the CSP, that key is used. 45 | // (2) If the KeyName does not exist and the KeyFile does exist, the key 46 | // in the KeyFile is installed into the CSP and used. 47 | // (*) In order to create a KeyFile, you can use the sn.exe (Strong Name) utility. 48 | // When specifying the KeyFile, the location of the KeyFile should be 49 | // relative to the project output directory which is 50 | // %Project Directory%\obj\. For example, if your KeyFile is 51 | // located in the project directory, you would specify the AssemblyKeyFile 52 | // attribute as [assembly: AssemblyKeyFile("..\\..\\mykey.snk")] 53 | // (*) Delay Signing is an advanced option - see the Microsoft .NET Framework 54 | // documentation for more information on this. 55 | // 56 | [assembly: AssemblyDelaySign(false)] 57 | [assembly: AssemblyKeyFile("")] 58 | [assembly: AssemblyKeyName("")] 59 | -------------------------------------------------------------------------------- /applications/SmartWindow2/vs2005/Properties/Settings.Designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // Runtime Version:2.0.50727.832 5 | // 6 | // Changes to this file may cause incorrect behavior and will be lost if 7 | // the code is regenerated. 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | namespace SmartWindow2.Properties 12 | { 13 | 14 | 15 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] 16 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "8.0.0.0")] 17 | internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase 18 | { 19 | 20 | private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings()))); 21 | 22 | public static Settings Default 23 | { 24 | get 25 | { 26 | return defaultInstance; 27 | } 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /applications/SmartWindow2/vs2005/Properties/Settings.settings: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /applications/SmartWindow2/vs2005/SmartWindow2.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | Debug 4 | AnyCPU 5 | 8.0.50727 6 | 2.0 7 | {72D3F595-E9B7-4956-9355-19AE498A5DCA} 8 | WinExe 9 | Properties 10 | SmartWindow2 11 | SmartWindow2 12 | 13 | 14 | true 15 | full 16 | false 17 | bin\Debug\ 18 | DEBUG;TRACE 19 | prompt 20 | 4 21 | 22 | 23 | pdbonly 24 | true 25 | bin\Release\ 26 | TRACE 27 | prompt 28 | 4 29 | 30 | 31 | 32 | False 33 | $(HALCONROOT)\bin\dotnet20\halcondotnet.dll 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | SettingsSingleFileGenerator 45 | Settings.Designer.cs 46 | 47 | 48 | AssemblyInfo.cs 49 | 50 | 51 | SmartWindow2Form.cs 52 | Form 53 | 54 | 55 | True 56 | Settings.settings 57 | True 58 | 59 | 60 | 61 | 62 | SmartWindow2Form.resx 63 | SmartWindow2Form.cs 64 | Designer 65 | 66 | 67 | 68 | 69 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F} 70 | ViewROI 71 | 72 | 73 | 74 | 81 | -------------------------------------------------------------------------------- /applications/SmartWindow2/vs2005/SmartWindow2.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 9.00 3 | # Visual Studio 2005 4 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SmartWindow2", "SmartWindow2.csproj", "{72D3F595-E9B7-4956-9355-19AE498A5DCA}" 5 | ProjectSection(ProjectDependencies) = postProject 6 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F} = {C4F5C5DE-7EA8-47FE-8218-48138F48965F} 7 | EndProjectSection 8 | EndProject 9 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ViewROI", "..\..\..\base\ViewROI\vs2005\ViewROI.csproj", "{C4F5C5DE-7EA8-47FE-8218-48138F48965F}" 10 | EndProject 11 | Global 12 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 13 | Debug|Any CPU = Debug|Any CPU 14 | Release|Any CPU = Release|Any CPU 15 | EndGlobalSection 16 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 17 | {72D3F595-E9B7-4956-9355-19AE498A5DCA}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 18 | {72D3F595-E9B7-4956-9355-19AE498A5DCA}.Debug|Any CPU.Build.0 = Debug|Any CPU 19 | {72D3F595-E9B7-4956-9355-19AE498A5DCA}.Release|Any CPU.ActiveCfg = Release|Any CPU 20 | {72D3F595-E9B7-4956-9355-19AE498A5DCA}.Release|Any CPU.Build.0 = Release|Any CPU 21 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 22 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Debug|Any CPU.Build.0 = Debug|Any CPU 23 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Release|Any CPU.ActiveCfg = Release|Any CPU 24 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Release|Any CPU.Build.0 = Release|Any CPU 25 | EndGlobalSection 26 | GlobalSection(SolutionProperties) = preSolution 27 | HideSolutionNode = FALSE 28 | EndGlobalSection 29 | EndGlobal 30 | -------------------------------------------------------------------------------- /assistants/Calibration/source/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | 4 | // 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | // 9 | [assembly: AssemblyTitle("")] 10 | [assembly: AssemblyDescription("")] 11 | [assembly: AssemblyConfiguration("")] 12 | [assembly: AssemblyCompany("")] 13 | [assembly: AssemblyProduct("")] 14 | [assembly: AssemblyCopyright("")] 15 | [assembly: AssemblyTrademark("")] 16 | [assembly: AssemblyCulture("")] 17 | 18 | // 19 | // Version information for an assembly consists of the following four values: 20 | // 21 | // Major Version 22 | // Minor Version 23 | // Build Number 24 | // Revision 25 | // 26 | // You can specify all the values or you can default the Revision and Build Numbers 27 | // by using the '*' as shown below: 28 | 29 | [assembly: AssemblyVersion("1.0.*")] 30 | 31 | // 32 | // In order to sign your assembly you must specify a key to use. Refer to the 33 | // Microsoft .NET Framework documentation for more information on assembly signing. 34 | // 35 | // Use the attributes below to control which key is used for signing. 36 | // 37 | // Notes: 38 | // (*) If no key is specified, the assembly is not signed. 39 | // (*) KeyName refers to a key that has been installed in the Crypto Service 40 | // Provider (CSP) on your machine. KeyFile refers to a file which contains 41 | // a key. 42 | // (*) If the KeyFile and the KeyName values are both specified, the 43 | // following processing occurs: 44 | // (1) If the KeyName can be found in the CSP, that key is used. 45 | // (2) If the KeyName does not exist and the KeyFile does exist, the key 46 | // in the KeyFile is installed into the CSP and used. 47 | // (*) In order to create a KeyFile, you can use the sn.exe (Strong Name) utility. 48 | // When specifying the KeyFile, the location of the KeyFile should be 49 | // relative to the project output directory which is 50 | // %Project Directory%\obj\. For example, if your KeyFile is 51 | // located in the project directory, you would specify the AssemblyKeyFile 52 | // attribute as [assembly: AssemblyKeyFile("..\\..\\mykey.snk")] 53 | // (*) Delay Signing is an advanced option - see the Microsoft .NET Framework 54 | // documentation for more information on this. 55 | // 56 | [assembly: AssemblyDelaySign(false)] 57 | [assembly: AssemblyKeyFile("")] 58 | [assembly: AssemblyKeyName("")] 59 | -------------------------------------------------------------------------------- /assistants/Calibration/source/QualityIssue.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | 4 | namespace CalibrationModule 5 | { 6 | /// 7 | /// This auxiliary class is used to reference the operation 8 | /// type for the quality assessment with the achieved score. 9 | /// 10 | public class QualityIssue 11 | { 12 | /// 13 | /// Constant starting with QUALITY_ISSUE_*, defined in the class 14 | /// CalibrationAssistant. 15 | /// 16 | private int qIssue; 17 | /// 18 | /// Score obtained from the quality assessment 19 | /// 20 | private double qScore; 21 | 22 | /// Initialize an instance 23 | /// 24 | /// Constant starting with QUALITY_ISSUE_*, defined in 25 | /// the class CalibrationAssistant. 26 | /// 27 | /// 28 | /// Score achieved for this quality measurement. 29 | /// 30 | public QualityIssue(int IType, double scr) 31 | { 32 | qIssue = IType; 33 | qScore = scr; 34 | } 35 | 36 | // getter-setter methods 37 | public double getScore() 38 | { 39 | return qScore; 40 | } 41 | 42 | public int getIssueType() 43 | { 44 | return qIssue; 45 | } 46 | 47 | }//end of class 48 | }//end of namespace 49 | -------------------------------------------------------------------------------- /assistants/Calibration/vs2005/CalibrationModule.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | Debug 4 | AnyCPU 5 | 8.0.50727 6 | 2.0 7 | {5B8A5685-BE62-4C1C-9464-E96A98C65744} 8 | Library 9 | Properties 10 | CalibrationModule 11 | CalibrationModule 12 | 13 | 14 | true 15 | full 16 | false 17 | bin\Debug\ 18 | DEBUG;TRACE 19 | prompt 20 | 4 21 | 22 | 23 | pdbonly 24 | true 25 | bin\Release\ 26 | TRACE 27 | prompt 28 | 4 29 | 30 | 31 | 32 | False 33 | $(HALCONROOT)\bin\dotnet20\halcondotnet.dll 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | AssemblyInfo.cs 42 | 43 | 44 | CalibImage.cs 45 | 46 | 47 | CalibrationAssistant.cs 48 | 49 | 50 | QualityIssue.cs 51 | 52 | 53 | QualityProcedures.cs 54 | 55 | 56 | 57 | 58 | 59 | 60 | 67 | -------------------------------------------------------------------------------- /assistants/Calibration/vs2005/CalibrationModule.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 9.00 3 | # Visual Studio 2005 4 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "CalibrationModule", "CalibrationModule.csproj", "{5B8A5685-BE62-4C1C-9464-E96A98C65744}" 5 | EndProject 6 | Global 7 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 8 | Debug|Any CPU = Debug|Any CPU 9 | Release|Any CPU = Release|Any CPU 10 | EndGlobalSection 11 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 12 | {5B8A5685-BE62-4C1C-9464-E96A98C65744}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 13 | {5B8A5685-BE62-4C1C-9464-E96A98C65744}.Debug|Any CPU.Build.0 = Debug|Any CPU 14 | {5B8A5685-BE62-4C1C-9464-E96A98C65744}.Release|Any CPU.ActiveCfg = Release|Any CPU 15 | {5B8A5685-BE62-4C1C-9464-E96A98C65744}.Release|Any CPU.Build.0 = Release|Any CPU 16 | EndGlobalSection 17 | GlobalSection(SolutionProperties) = preSolution 18 | HideSolutionNode = FALSE 19 | EndGlobalSection 20 | EndGlobal 21 | -------------------------------------------------------------------------------- /assistants/Matching/source/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | 4 | // 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | // 9 | [assembly: AssemblyTitle("")] 10 | [assembly: AssemblyDescription("")] 11 | [assembly: AssemblyConfiguration("")] 12 | [assembly: AssemblyCompany("")] 13 | [assembly: AssemblyProduct("")] 14 | [assembly: AssemblyCopyright("")] 15 | [assembly: AssemblyTrademark("")] 16 | [assembly: AssemblyCulture("")] 17 | 18 | // 19 | // Version information for an assembly consists of the following four values: 20 | // 21 | // Major Version 22 | // Minor Version 23 | // Build Number 24 | // Revision 25 | // 26 | // You can specify all the values or you can default the Revision and Build Numbers 27 | // by using the '*' as shown below: 28 | 29 | [assembly: AssemblyVersion("1.0.*")] 30 | 31 | // 32 | // In order to sign your assembly you must specify a key to use. Refer to the 33 | // Microsoft .NET Framework documentation for more information on assembly signing. 34 | // 35 | // Use the attributes below to control which key is used for signing. 36 | // 37 | // Notes: 38 | // (*) If no key is specified, the assembly is not signed. 39 | // (*) KeyName refers to a key that has been installed in the Crypto Service 40 | // Provider (CSP) on your machine. KeyFile refers to a file which contains 41 | // a key. 42 | // (*) If the KeyFile and the KeyName values are both specified, the 43 | // following processing occurs: 44 | // (1) If the KeyName can be found in the CSP, that key is used. 45 | // (2) If the KeyName does not exist and the KeyFile does exist, the key 46 | // in the KeyFile is installed into the CSP and used. 47 | // (*) In order to create a KeyFile, you can use the sn.exe (Strong Name) utility. 48 | // When specifying the KeyFile, the location of the KeyFile should be 49 | // relative to the project output directory which is 50 | // %Project Directory%\obj\. For example, if your KeyFile is 51 | // located in the project directory, you would specify the AssemblyKeyFile 52 | // attribute as [assembly: AssemblyKeyFile("..\\..\\mykey.snk")] 53 | // (*) Delay Signing is an advanced option - see the Microsoft .NET Framework 54 | // documentation for more information on this. 55 | // 56 | [assembly: AssemblyDelaySign(false)] 57 | [assembly: AssemblyKeyFile("")] 58 | [assembly: AssemblyKeyName("")] 59 | -------------------------------------------------------------------------------- /assistants/Matching/source/MatchingOpt.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections; 3 | 4 | 5 | 6 | namespace MatchingModule 7 | { 8 | public delegate void StatisticsDelegate(int val); 9 | 10 | /// 11 | /// This class and its derived classes MatchingOptSpeed and 12 | /// MatchingOptStatistics implement the optimization process for the 13 | /// matching parameters in terms of the recognition speed and the 14 | /// recognition rate. Similar to the processing in HDevelop, a timer 15 | /// is used to be able to abort the processing during a run. 16 | /// 17 | public class MatchingOpt 18 | { 19 | 20 | /// 21 | /// Delegate to notify about the state of the optimization process 22 | /// 23 | public StatisticsDelegate NotifyStatisticsObserver; 24 | /// 25 | /// Information about the optimization process 26 | /// (e.g. Success or Failure) to be displayed in the GUI 27 | /// 28 | public string statusString; 29 | /// 30 | /// Statistics for the parameter optimization 31 | /// 32 | public string [] recogTabOptimizationData = new string[8]; 33 | /// 34 | /// Statistics for the recognition rate 35 | /// 36 | public string [] inspectTabRecogRateData = new string[5]; 37 | /// 38 | /// Statistics of detection results for the optimal 39 | /// recognition rate 40 | /// 41 | public string [] inspectTabStatisticsData = new string[21]; 42 | 43 | /// 44 | /// Reference to instance of MatchingAssistant, 45 | /// which triggers the optimization performance. 46 | /// 47 | public MatchingAssistant mAssistant; 48 | /// 49 | /// Result of detection 50 | /// 51 | public MatchingResult mResults; 52 | /// 53 | /// Set of matching parameters 54 | /// 55 | public MatchingParam mParams; 56 | /// 57 | /// Number of all test images to be inspected 58 | /// 59 | public int tImageCount; 60 | /// 61 | /// Index of test image, being inspected currently 62 | /// 63 | public int mCurrentIndex; 64 | /// 65 | /// Flag, indicating success or failure of optimization process 66 | /// 67 | public bool mOptSuccess; 68 | 69 | public IEnumerator iterator; 70 | 71 | /// 72 | /// Constant describing a change in the status line 73 | /// 74 | public const int UPDATE_RECOG_STATISTICS_STATUS= 21; 75 | /// 76 | /// Constant describing a change in the statistics of 77 | /// the last recognition run 78 | /// 79 | public const int UPDATE_RECOG_UPDATE_VALS = 22; 80 | /// 81 | /// Constant describing a change in the statistics of 82 | /// the optimal recognition run 83 | /// 84 | public const int UPDATE_RECOG_OPTIMUM_VALS = 23; 85 | /// 86 | /// Constant describing an error during the optimization 87 | /// run, concerning the test image data or matching model 88 | /// 89 | public const int UPDATE_TEST_ERR = 24; 90 | /// 91 | /// Constant describing an error, which says that there is 92 | /// no possible combination of matching parameters to obtain 93 | /// a detection result 94 | /// 95 | public const int UPDATE_RECOG_ERR = 25; 96 | 97 | /// 98 | /// Constant describing a change in the statistics of 99 | /// the recognition rate 100 | /// 101 | public const int UPDATE_INSP_RECOGRATE = 26; 102 | /// 103 | /// Constant describing a change in the statics of 104 | /// the average recognition results 105 | /// 106 | public const int UPDATE_INSP_STATISTICS = 27; 107 | /// 108 | /// Constant describing an update of the 109 | /// detection results 110 | /// 111 | public const int UPDATE_TESTVIEW = 28; 112 | /// 113 | /// Constant describing the success of the optimization 114 | /// process and triggering the adjustment of the GUI 115 | /// components to the optimal parameter setting 116 | /// 117 | public const int RUN_SUCCESSFUL = 29; 118 | /// 119 | /// Constant describing the failure of the optimization 120 | /// process and reseting the matching parameters to the 121 | /// initial setup 122 | /// 123 | public const int RUN_FAILED = 30; 124 | 125 | /// 126 | /// Constructor 127 | /// 128 | public MatchingOpt(){} 129 | 130 | /// 131 | /// Performs an optimization step. 132 | /// 133 | public virtual bool ExecuteStep(){ return true; } 134 | 135 | /// 136 | /// Resets all parameters for evaluating the performance to their initial values. 137 | /// 138 | public virtual void reset(){} 139 | 140 | /// 141 | /// 142 | /// 143 | public virtual void stop(){} 144 | 145 | public void dummy(int val) { } 146 | }//class 147 | }//end of namespace 148 | -------------------------------------------------------------------------------- /assistants/Matching/source/MatchingOptStatistics.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rtigithub/HALCON-12-codelets/323f337ec58c5d4845be1ae35f3238aab4e6459a/assistants/Matching/source/MatchingOptStatistics.cs -------------------------------------------------------------------------------- /assistants/Matching/source/MatchingResult.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using HalconDotNet; 3 | 4 | 5 | namespace MatchingModule 6 | { 7 | 8 | /// 9 | /// This class holds the result data from a model detection. For any new 10 | /// detection run, it also remembers the time needed 11 | /// for the model detection. 12 | /// 13 | public class MatchingResult 14 | { 15 | 16 | /// 17 | /// Model contour applied for model detection 18 | /// 19 | public HXLDCont mContour; 20 | /// 21 | /// All model contours detected 22 | /// 23 | public HXLDCont mContResults; 24 | 25 | /// 26 | /// Row coordinate of the found instances of the model 27 | /// 28 | public HTuple mRow; 29 | /// 30 | /// Column coordinate of the found instances of the model 31 | /// 32 | public HTuple mCol; 33 | 34 | /// 35 | /// Rotation angle of the found instances of the model 36 | /// 37 | public HTuple mAngle; 38 | /// 39 | /// Scale of the found instances of the model in the row direction 40 | /// 41 | public HTuple mScaleRow; 42 | /// 43 | /// Scale of the found instances of the model in the column direction 44 | /// 45 | public HTuple mScaleCol; 46 | /// 47 | /// Score of the found instances of the model 48 | /// 49 | public HTuple mScore; 50 | /// 51 | /// Time needed to detect count numbers of model instances 52 | /// 53 | public double mTime; 54 | /// 55 | /// Number of model instances found 56 | /// 57 | public int count; 58 | /// 59 | /// 2D homogeneous transformation matrix that can be used to transform 60 | /// data from the model into the test image. 61 | /// 62 | public HHomMat2D hmat; 63 | 64 | /// Constructor 65 | public MatchingResult() 66 | { 67 | hmat = new HHomMat2D(); 68 | mContResults = new HXLDCont(); 69 | } 70 | 71 | 72 | /// 73 | /// Gets the detected contour. 74 | /// 75 | /// Detected contour 76 | public HXLDCont getDetectionResults() 77 | { 78 | HXLDCont rContours = new HXLDCont(); 79 | hmat.HomMat2dIdentity(); 80 | mContResults.GenEmptyObj(); 81 | 82 | for(int i = 0; i 93 | /// Resets the detection results and sets count to 0. 94 | /// 95 | public void reset() 96 | { 97 | count = 0; 98 | } 99 | 100 | }//end of class 101 | }//end of namespace 102 | -------------------------------------------------------------------------------- /assistants/Matching/vs2005/MatchingModule.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | Debug 4 | AnyCPU 5 | 8.0.50727 6 | 2.0 7 | {87035C5C-B4E6-4B94-A7B9-5031A34DBFB0} 8 | Library 9 | Properties 10 | MatchingModule 11 | MatchingModule 12 | 13 | 14 | true 15 | full 16 | false 17 | bin\Debug\ 18 | DEBUG;TRACE 19 | prompt 20 | 4 21 | 22 | 23 | pdbonly 24 | true 25 | bin\Release\ 26 | TRACE 27 | prompt 28 | 4 29 | 30 | 31 | 32 | False 33 | $(HALCONROOT)\bin\dotnet20\halcondotnet.dll 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | AssemblyInfo.cs 43 | 44 | 45 | MatchingAssistant.cs 46 | 47 | 48 | MatchingOpt.cs 49 | 50 | 51 | MatchingOptSpeed.cs 52 | 53 | 54 | MatchingOptStatistics.cs 55 | 56 | 57 | MatchingParam.cs 58 | 59 | 60 | MatchingResult.cs 61 | 62 | 63 | 64 | 65 | 66 | 67 | 74 | -------------------------------------------------------------------------------- /assistants/Matching/vs2005/MatchingModule.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 9.00 3 | # Visual Studio 2005 4 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MatchingModule", "MatchingModule.csproj", "{87035C5C-B4E6-4B94-A7B9-5031A34DBFB0}" 5 | EndProject 6 | Global 7 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 8 | Debug|Any CPU = Debug|Any CPU 9 | Release|Any CPU = Release|Any CPU 10 | EndGlobalSection 11 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 12 | {87035C5C-B4E6-4B94-A7B9-5031A34DBFB0}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 13 | {87035C5C-B4E6-4B94-A7B9-5031A34DBFB0}.Debug|Any CPU.Build.0 = Debug|Any CPU 14 | {87035C5C-B4E6-4B94-A7B9-5031A34DBFB0}.Release|Any CPU.ActiveCfg = Release|Any CPU 15 | {87035C5C-B4E6-4B94-A7B9-5031A34DBFB0}.Release|Any CPU.Build.0 = Release|Any CPU 16 | EndGlobalSection 17 | GlobalSection(SolutionProperties) = preSolution 18 | HideSolutionNode = FALSE 19 | EndGlobalSection 20 | EndGlobal 21 | -------------------------------------------------------------------------------- /assistants/Measure/source/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | 4 | // 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | // 9 | [assembly: AssemblyTitle("")] 10 | [assembly: AssemblyDescription("")] 11 | [assembly: AssemblyConfiguration("")] 12 | [assembly: AssemblyCompany("")] 13 | [assembly: AssemblyProduct("")] 14 | [assembly: AssemblyCopyright("")] 15 | [assembly: AssemblyTrademark("")] 16 | [assembly: AssemblyCulture("")] 17 | 18 | // 19 | // Version information for an assembly consists of the following four values: 20 | // 21 | // Major Version 22 | // Minor Version 23 | // Build Number 24 | // Revision 25 | // 26 | // You can specify all the values or you can default the Revision and Build Numbers 27 | // by using the '*' as shown below: 28 | 29 | [assembly: AssemblyVersion("1.0.*")] 30 | 31 | // 32 | // In order to sign your assembly you must specify a key to use. Refer to the 33 | // Microsoft .NET Framework documentation for more information on assembly signing. 34 | // 35 | // Use the attributes below to control which key is used for signing. 36 | // 37 | // Notes: 38 | // (*) If no key is specified, the assembly is not signed. 39 | // (*) KeyName refers to a key that has been installed in the Crypto Service 40 | // Provider (CSP) on your machine. KeyFile refers to a file which contains 41 | // a key. 42 | // (*) If the KeyFile and the KeyName values are both specified, the 43 | // following processing occurs: 44 | // (1) If the KeyName can be found in the CSP, that key is used. 45 | // (2) If the KeyName does not exist and the KeyFile does exist, the key 46 | // in the KeyFile is installed into the CSP and used. 47 | // (*) In order to create a KeyFile, you can use the sn.exe (Strong Name) utility. 48 | // When specifying the KeyFile, the location of the KeyFile should be 49 | // relative to the project output directory which is 50 | // %Project Directory%\obj\. For example, if your KeyFile is 51 | // located in the project directory, you would specify the AssemblyKeyFile 52 | // attribute as [assembly: AssemblyKeyFile("..\\..\\mykey.snk")] 53 | // (*) Delay Signing is an advanced option - see the Microsoft .NET Framework 54 | // documentation for more information on this. 55 | // 56 | [assembly: AssemblyDelaySign(false)] 57 | [assembly: AssemblyKeyFile("")] 58 | [assembly: AssemblyKeyName("")] 59 | -------------------------------------------------------------------------------- /assistants/Measure/source/Measurement.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rtigithub/HALCON-12-codelets/323f337ec58c5d4845be1ae35f3238aab4e6459a/assistants/Measure/source/Measurement.cs -------------------------------------------------------------------------------- /assistants/Measure/source/MeasurementEdge.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using ViewROI; 3 | using HalconDotNet; 4 | 5 | namespace MeasureModule 6 | { 7 | 8 | /// 9 | /// The class MeasurementEdge describes single-edge measurement 10 | /// and inherits from the base class Measurement. Virtual methods 11 | /// defined in the base class are customized here to apply 12 | /// HALCON operators for single-edge extraction. 13 | /// 14 | public class MeasurementEdge : Measurement 15 | { 16 | /// 17 | /// Result container for the edge information returned 18 | /// by the HALCON measure operator. 19 | /// 20 | private EdgeResult mResult; 21 | /// 22 | /// Result container for the edge information converted 23 | /// into world coordinates. If calibration data is not available, 24 | /// the variable contains the same information as mResult. 25 | /// 26 | private EdgeResult mResultWorld; 27 | 28 | 29 | /// 30 | /// Creates a measurement object for the provided ROI instance. 31 | /// 32 | /// ROI instance 33 | /// Reference to controller class 34 | public MeasurementEdge(ROI roi, MeasureAssistant mAssist) 35 | : base(roi, mAssist) 36 | { 37 | mResult = new EdgeResult(); 38 | mResultWorld = new EdgeResult(); 39 | UpdateMeasure(); 40 | } 41 | 42 | /// 43 | /// Triggers an update of the measure results because of 44 | /// changes in the parameter setup or a recreation of the measure 45 | /// object caused by an update in the ROI model. 46 | /// 47 | public override void UpdateResults() 48 | { 49 | if (mHandle == null) 50 | return; 51 | 52 | mMeasAssist.exceptionText = ""; 53 | 54 | try 55 | { 56 | mHandle.MeasurePos(mMeasAssist.mImage, 57 | mMeasAssist.mSigma, mMeasAssist.mThresh, 58 | mMeasAssist.mTransition, mMeasAssist.mPosition, 59 | out mResult.rowEdge, out mResult.colEdge, 60 | out mResult.amplitude, out mResult.distance); 61 | 62 | if (mMeasAssist.mIsCalibValid && mMeasAssist.mTransWorldCoord) 63 | { 64 | Rectify(mResult.rowEdge, mResult.colEdge, out mResultWorld.rowEdge, out mResultWorld.colEdge); 65 | mResultWorld.distance = Distance(mResult.rowEdge, mResult.colEdge, mResult.rowEdge, mResult.colEdge, 1); 66 | mResultWorld.amplitude = mResult.amplitude; 67 | } 68 | else 69 | { 70 | mResultWorld = new EdgeResult(mResult); 71 | } 72 | } 73 | catch (HOperatorException e) 74 | { 75 | mEdgeXLD.Dispose(); 76 | mMeasAssist.exceptionText = e.Message; 77 | mResultWorld = new EdgeResult(); 78 | return; 79 | } 80 | UpdateXLD(); 81 | } 82 | 83 | /// Updates display object for measured edge results 84 | public override void UpdateXLD() 85 | { 86 | double width, phi, cRow, cCol, radius; 87 | 88 | if (mHandle == null && ((int)mHandle.Handle < 0)) 89 | return; 90 | 91 | mMeasAssist.exceptionText = ""; 92 | width = mMeasAssist.mDispROIWidth ? mMeasAssist.mRoiWidth : mMeasAssist.mDispEdgeLength; 93 | mEdgeXLD.Dispose(); 94 | mEdgeXLD.GenEmptyObj(); 95 | 96 | try 97 | { 98 | if (mROIType == ROI.ROI_TYPE_LINE) 99 | { 100 | phi = mMeasROI[2].D; 101 | 102 | for (int i = 0; i < mResult.rowEdge.Length; i++) 103 | mEdgeXLD = mEdgeXLD.ConcatObj(DetermineEdgeLine(mResult.rowEdge[i].D, mResult.colEdge[i].D, phi, width)); 104 | 105 | } 106 | else if (mROIType == ROI.ROI_TYPE_CIRCLEARC) 107 | { 108 | cRow = mROICoord[0].D; 109 | cCol = mROICoord[1].D; 110 | radius = mROICoord[2].D; 111 | 112 | for (int i = 0; i < mResult.rowEdge.Length; i++) 113 | mEdgeXLD = mEdgeXLD.ConcatObj(DetermineEdgeCircularArc(mResult.rowEdge[i].D, mResult.colEdge[i].D, cRow, cCol, radius, width)); 114 | } 115 | } 116 | catch (HOperatorException e) 117 | { 118 | mMeasAssist.exceptionText = e.Message; 119 | } 120 | } 121 | 122 | /// Returns measurement result. 123 | public override MeasureResult getMeasureResultData() 124 | { 125 | return mResultWorld; 126 | } 127 | 128 | /// Clears measurement result. 129 | public override void ClearResultData() 130 | { 131 | mResultWorld = new EdgeResult(); 132 | } 133 | 134 | }//end of class 135 | }//end of namespace 136 | -------------------------------------------------------------------------------- /assistants/Measure/source/MeasurementResult.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using HalconDotNet; 3 | using ViewROI; 4 | 5 | namespace MeasureModule 6 | { 7 | 8 | /// 9 | /// Base class to have a more abstract definition of a measure result. 10 | /// 11 | public class MeasureResult 12 | { 13 | public MeasureResult() { } 14 | } 15 | 16 | /****************************************************************/ 17 | /****************************************************************/ 18 | 19 | /// 20 | /// Measure result class containing data obtained from the HALCON measure 21 | /// operator for single-edge measurement 22 | /// 23 | public class EdgeResult : MeasureResult 24 | { 25 | /// Row coordinate of extracted edges. 26 | public HTuple rowEdge; 27 | 28 | /// Column coordinate of extracted edges. 29 | public HTuple colEdge; 30 | 31 | /// Amplitude of the extracted edges (with sign). 32 | public HTuple amplitude; 33 | 34 | /// Distance between consecutive edges. 35 | public HTuple distance; 36 | 37 | /// Creates empty instance. 38 | public EdgeResult() { } 39 | 40 | /// 41 | /// Creates an edge result instance containing data from 42 | /// the provided result value (deep copy). 43 | /// 44 | public EdgeResult(EdgeResult result) 45 | : this(result.rowEdge, result.colEdge, 46 | result.amplitude, result.distance) 47 | { 48 | } 49 | 50 | /// 51 | /// Creates an edge result instance using the passed values. 52 | /// 53 | public EdgeResult(HTuple Nrow, HTuple Ncol, 54 | HTuple Nampl, HTuple Ndist) 55 | { 56 | rowEdge = new HTuple(Nrow); 57 | colEdge = new HTuple(Ncol); 58 | amplitude = new HTuple(Nampl); 59 | distance = new HTuple(Ndist); 60 | } 61 | 62 | /// 63 | /// Creates an edge result instance using the passed values. 64 | /// 65 | public EdgeResult(double Nrow, double Ncol, 66 | double Nampl, double Ndist) 67 | { 68 | rowEdge = new HTuple(Nrow); 69 | colEdge = new HTuple(Ncol); 70 | amplitude = new HTuple(Nampl); 71 | distance = new HTuple(Ndist); 72 | } 73 | 74 | }//end of class EdgeResult 75 | 76 | 77 | /****************************************************************/ 78 | /****************************************************************/ 79 | 80 | /// 81 | /// Measure result class containing data obtained from the HALCON measure 82 | /// operator for edge pair measurement 83 | /// 84 | public class PairResult : MeasureResult 85 | { 86 | 87 | /// 88 | /// Row coordinate of first extracted edges of a pair. 89 | /// 90 | public HTuple rowEdgeFirst; 91 | /// 92 | /// Column coordinate of first extracted edges of a pair. 93 | /// 94 | public HTuple colEdgeFirst; 95 | /// 96 | /// Row coordinate of second extracted edges of a pair. 97 | /// 98 | public HTuple rowEdgeSecond; 99 | /// 100 | /// Column coordinate of second extracted edges of a pair. 101 | /// 102 | public HTuple colEdgeSecond; 103 | /// Amplitude of the first extracted edges of a pair (with sign). 104 | public HTuple amplitudeFirst; 105 | /// Amplitude of the second extracted edges of a pair (with sign). 106 | public HTuple amplitudeSecond; 107 | /// Distance between edges of a pair. 108 | public HTuple intraDistance; 109 | /// Distance between consecutive edge pairs 110 | public HTuple interDistance; 111 | 112 | 113 | /// Creates empty instance. 114 | public PairResult() { } 115 | 116 | /// 117 | /// Creates an edge result instance containing data from 118 | /// the provided result value (deep copy). 119 | /// 120 | public PairResult(PairResult result) 121 | : this(result.rowEdgeFirst, result.colEdgeFirst, 122 | result.rowEdgeSecond, result.colEdgeSecond, 123 | result.amplitudeFirst, result.amplitudeSecond, 124 | result.intraDistance, result.interDistance) 125 | { 126 | } 127 | 128 | /// 129 | /// Creates an edge result instance using the passed values. 130 | /// 131 | public PairResult(HTuple Nrow1, HTuple Ncol1, 132 | HTuple Nrow2, HTuple Ncol2, 133 | HTuple Nampl1, HTuple Nampl2, 134 | HTuple Ndist, HTuple Nwidth) 135 | { 136 | rowEdgeFirst = new HTuple(Nrow1); 137 | colEdgeFirst = new HTuple(Ncol1); 138 | rowEdgeSecond = new HTuple(Nrow2); 139 | colEdgeSecond = new HTuple(Ncol2); 140 | amplitudeFirst = new HTuple(Nampl1); 141 | amplitudeSecond = new HTuple(Nampl2); 142 | intraDistance = new HTuple(Ndist); 143 | interDistance = new HTuple(Nwidth); 144 | } 145 | 146 | /// 147 | /// Creates an edge result instance using the passed values. 148 | /// 149 | public PairResult(double Nrow1, double Ncol1, 150 | double Nrow2, double Ncol2, 151 | double Nampl1, double Nampl2, 152 | double Ndist, double Nwidth) 153 | { 154 | rowEdgeFirst = new HTuple(Nrow1); 155 | colEdgeFirst = new HTuple(Ncol1); 156 | rowEdgeSecond = new HTuple(Nrow2); 157 | colEdgeSecond = new HTuple(Ncol2); 158 | amplitudeFirst = new HTuple(Nampl1); 159 | amplitudeSecond = new HTuple(Nampl2); 160 | intraDistance = new HTuple(Ndist); 161 | interDistance = new HTuple(Nwidth); 162 | } 163 | 164 | }//end of class PairResult 165 | }//end of namespace 166 | -------------------------------------------------------------------------------- /assistants/Measure/vs2005/MeasureModule.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | Debug 4 | AnyCPU 5 | 8.0.50727 6 | 2.0 7 | {A5B3B77C-7F30-4109-8EF6-8CE30DD1317E} 8 | Library 9 | Properties 10 | MeasureModule 11 | MeasureModule 12 | 13 | 14 | true 15 | full 16 | false 17 | bin\Debug\ 18 | DEBUG;TRACE 19 | prompt 20 | 4 21 | 22 | 23 | pdbonly 24 | true 25 | bin\Release\ 26 | TRACE 27 | prompt 28 | 4 29 | 30 | 31 | 32 | False 33 | $(HALCONROOT)\bin\dotnet20\halcondotnet.dll 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | AssemblyInfo.cs 42 | 43 | 44 | MeasureAssistant.cs 45 | 46 | 47 | Measurement.cs 48 | 49 | 50 | MeasurementEdge.cs 51 | 52 | 53 | MeasurementPair.cs 54 | 55 | 56 | MeasurementResult.cs 57 | 58 | 59 | 60 | 61 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F} 62 | ViewROI 63 | 64 | 65 | 66 | 67 | 68 | 69 | 76 | -------------------------------------------------------------------------------- /assistants/Measure/vs2005/MeasureModule.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 9.00 3 | # Visual Studio 2005 4 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MeasureModule", "MeasureModule.csproj", "{A5B3B77C-7F30-4109-8EF6-8CE30DD1317E}" 5 | EndProject 6 | Global 7 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 8 | Debug|Any CPU = Debug|Any CPU 9 | Release|Any CPU = Release|Any CPU 10 | EndGlobalSection 11 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 12 | {A5B3B77C-7F30-4109-8EF6-8CE30DD1317E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 13 | {A5B3B77C-7F30-4109-8EF6-8CE30DD1317E}.Debug|Any CPU.Build.0 = Debug|Any CPU 14 | {A5B3B77C-7F30-4109-8EF6-8CE30DD1317E}.Release|Any CPU.ActiveCfg = Release|Any CPU 15 | {A5B3B77C-7F30-4109-8EF6-8CE30DD1317E}.Release|Any CPU.Build.0 = Release|Any CPU 16 | EndGlobalSection 17 | GlobalSection(SolutionProperties) = preSolution 18 | HideSolutionNode = FALSE 19 | EndGlobalSection 20 | EndGlobal 21 | -------------------------------------------------------------------------------- /base/ViewROI/source/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | 4 | // 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | // 9 | [assembly: AssemblyTitle("")] 10 | [assembly: AssemblyDescription("")] 11 | [assembly: AssemblyConfiguration("")] 12 | [assembly: AssemblyCompany("")] 13 | [assembly: AssemblyProduct("")] 14 | [assembly: AssemblyCopyright("")] 15 | [assembly: AssemblyTrademark("")] 16 | [assembly: AssemblyCulture("")] 17 | 18 | // 19 | // Version information for an assembly consists of the following four values: 20 | // 21 | // Major Version 22 | // Minor Version 23 | // Build Number 24 | // Revision 25 | // 26 | // You can specify all the values or you can default the Revision and Build Numbers 27 | // by using the '*' as shown below: 28 | 29 | [assembly: AssemblyVersion("1.0.*")] 30 | 31 | // 32 | // In order to sign your assembly you must specify a key to use. Refer to the 33 | // Microsoft .NET Framework documentation for more information on assembly signing. 34 | // 35 | // Use the attributes below to control which key is used for signing. 36 | // 37 | // Notes: 38 | // (*) If no key is specified, the assembly is not signed. 39 | // (*) KeyName refers to a key that has been installed in the Crypto Service 40 | // Provider (CSP) on your machine. KeyFile refers to a file which contains 41 | // a key. 42 | // (*) If the KeyFile and the KeyName values are both specified, the 43 | // following processing occurs: 44 | // (1) If the KeyName can be found in the CSP, that key is used. 45 | // (2) If the KeyName does not exist and the KeyFile does exist, the key 46 | // in the KeyFile is installed into the CSP and used. 47 | // (*) In order to create a KeyFile, you can use the sn.exe (Strong Name) utility. 48 | // When specifying the KeyFile, the location of the KeyFile should be 49 | // relative to the project output directory which is 50 | // %Project Directory%\obj\. For example, if your KeyFile is 51 | // located in the project directory, you would specify the AssemblyKeyFile 52 | // attribute as [assembly: AssemblyKeyFile("..\\..\\mykey.snk")] 53 | // (*) Delay Signing is an advanced option - see the Microsoft .NET Framework 54 | // documentation for more information on this. 55 | // 56 | [assembly: AssemblyDelaySign(false)] 57 | [assembly: AssemblyKeyFile("")] 58 | [assembly: AssemblyKeyName("")] 59 | -------------------------------------------------------------------------------- /base/ViewROI/source/HObjectEntry.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using HalconDotNet; 3 | using System.Collections; 4 | 5 | 6 | 7 | namespace ViewROI 8 | { 9 | 10 | /// 11 | /// This class is an auxiliary class, which is used to 12 | /// link a graphical context to an HALCON object. The graphical 13 | /// context is described by a hashtable, which contains a list of 14 | /// graphical modes (e.g GC_COLOR, GC_LINEWIDTH and GC_PAINT) 15 | /// and their corresponding values (e.g "blue", "4", "3D-plot"). These 16 | /// graphical states are applied to the window before displaying the 17 | /// object. 18 | /// 19 | public class HObjectEntry 20 | { 21 | /// Hashlist defining the graphical context for HObj 22 | public Hashtable gContext; 23 | 24 | /// HALCON object 25 | public HObject HObj; 26 | 27 | 28 | 29 | /// Constructor 30 | /// 31 | /// HALCON object that is linked to the graphical context gc. 32 | /// 33 | /// 34 | /// Hashlist of graphical states that are applied before the object 35 | /// is displayed. 36 | /// 37 | public HObjectEntry(HObject obj, Hashtable gc) 38 | { 39 | gContext = gc; 40 | HObj = obj; 41 | } 42 | 43 | /// 44 | /// Clears the entries of the class members Hobj and gContext 45 | /// 46 | public void clear() 47 | { 48 | gContext.Clear(); 49 | HObj.Dispose(); 50 | } 51 | 52 | }//end of class 53 | }//end of namespace 54 | -------------------------------------------------------------------------------- /base/ViewROI/source/ROI.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using HalconDotNet; 3 | 4 | 5 | namespace ViewROI 6 | { 7 | 8 | /// 9 | /// This class is a base class containing virtual methods for handling 10 | /// ROIs. Therefore, an inheriting class needs to define/override these 11 | /// methods to provide the ROIController with the necessary information on 12 | /// its (= the ROIs) shape and position. The example project provides 13 | /// derived ROI shapes for rectangles, lines, circles, and circular arcs. 14 | /// To use other shapes you must derive a new class from the base class 15 | /// ROI and implement its methods. 16 | /// 17 | public class ROI 18 | { 19 | 20 | // class members of inheriting ROI classes 21 | protected int NumHandles; 22 | protected int activeHandleIdx; 23 | 24 | /// 25 | /// Flag to define the ROI to be 'positive' or 'negative'. 26 | /// 27 | protected int OperatorFlag; 28 | 29 | /// Parameter to define the line style of the ROI. 30 | public HTuple flagLineStyle; 31 | 32 | /// Constant for a positive ROI flag. 33 | public const int POSITIVE_FLAG = ROIController.MODE_ROI_POS; 34 | 35 | /// Constant for a negative ROI flag. 36 | public const int NEGATIVE_FLAG = ROIController.MODE_ROI_NEG; 37 | 38 | public const int ROI_TYPE_LINE = 10; 39 | public const int ROI_TYPE_CIRCLE = 11; 40 | public const int ROI_TYPE_CIRCLEARC = 12; 41 | public const int ROI_TYPE_RECTANCLE1 = 13; 42 | public const int ROI_TYPE_RECTANGLE2 = 14; 43 | 44 | 45 | protected HTuple posOperation = new HTuple(); 46 | protected HTuple negOperation = new HTuple(new int[] { 2, 2 }); 47 | 48 | /// Constructor of abstract ROI class. 49 | public ROI() { } 50 | 51 | /// Creates a new ROI instance at the mouse position. 52 | /// 53 | /// x (=column) coordinate for ROI 54 | /// 55 | /// 56 | /// y (=row) coordinate for ROI 57 | /// 58 | public virtual void createROI(double midX, double midY) { } 59 | 60 | /// Paints the ROI into the supplied window. 61 | /// HALCON window 62 | public virtual void draw(HalconDotNet.HWindow window) { } 63 | 64 | /// 65 | /// Returns the distance of the ROI handle being 66 | /// closest to the image point(x,y) 67 | /// 68 | /// x (=column) coordinate 69 | /// y (=row) coordinate 70 | /// 71 | /// Distance of the closest ROI handle. 72 | /// 73 | public virtual double distToClosestHandle(double x, double y) 74 | { 75 | return 0.0; 76 | } 77 | 78 | /// 79 | /// Paints the active handle of the ROI object into the supplied window. 80 | /// 81 | /// HALCON window 82 | public virtual void displayActive(HalconDotNet.HWindow window) { } 83 | 84 | /// 85 | /// Recalculates the shape of the ROI. Translation is 86 | /// performed at the active handle of the ROI object 87 | /// for the image coordinate (x,y). 88 | /// 89 | /// x (=column) coordinate 90 | /// y (=row) coordinate 91 | public virtual void moveByHandle(double x, double y) { } 92 | 93 | /// Gets the HALCON region described by the ROI. 94 | public virtual HRegion getRegion() 95 | { 96 | return null; 97 | } 98 | 99 | public virtual double getDistanceFromStartPoint(double row, double col) 100 | { 101 | return 0.0; 102 | } 103 | /// 104 | /// Gets the model information described by 105 | /// the ROI. 106 | /// 107 | public virtual HTuple getModelData() 108 | { 109 | return null; 110 | } 111 | 112 | /// Number of handles defined for the ROI. 113 | /// Number of handles 114 | public int getNumHandles() 115 | { 116 | return NumHandles; 117 | } 118 | 119 | /// Gets the active handle of the ROI. 120 | /// Index of the active handle (from the handle list) 121 | public int getActHandleIdx() 122 | { 123 | return activeHandleIdx; 124 | } 125 | 126 | /// 127 | /// Gets the sign of the ROI object, being either 128 | /// 'positive' or 'negative'. This sign is used when creating a model 129 | /// region for matching applications from a list of ROIs. 130 | /// 131 | public int getOperatorFlag() 132 | { 133 | return OperatorFlag; 134 | } 135 | 136 | /// 137 | /// Sets the sign of a ROI object to be positive or negative. 138 | /// The sign is used when creating a model region for matching 139 | /// applications by summing up all positive and negative ROI models 140 | /// created so far. 141 | /// 142 | /// Sign of ROI object 143 | public void setOperatorFlag(int flag) 144 | { 145 | OperatorFlag = flag; 146 | 147 | switch (OperatorFlag) 148 | { 149 | case ROI.POSITIVE_FLAG: 150 | flagLineStyle = posOperation; 151 | break; 152 | case ROI.NEGATIVE_FLAG: 153 | flagLineStyle = negOperation; 154 | break; 155 | default: 156 | flagLineStyle = posOperation; 157 | break; 158 | } 159 | } 160 | }//end of class 161 | }//end of namespace 162 | -------------------------------------------------------------------------------- /base/ViewROI/source/ROICircle.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using HalconDotNet; 3 | 4 | namespace ViewROI 5 | { 6 | /// 7 | /// This class demonstrates one of the possible implementations for a 8 | /// circular ROI. ROICircle inherits from the base class ROI and 9 | /// implements (besides other auxiliary methods) all virtual methods 10 | /// defined in ROI.cs. 11 | /// 12 | public class ROICircle : ROI 13 | { 14 | 15 | private double radius; 16 | private double row1, col1; // first handle 17 | private double midR, midC; // second handle 18 | 19 | 20 | public ROICircle() 21 | { 22 | NumHandles = 2; // one at corner of circle + midpoint 23 | activeHandleIdx = 1; 24 | } 25 | 26 | 27 | 28 | /// Creates a new ROI instance at the mouse position 29 | public override void createROI(double midX, double midY) 30 | { 31 | midR = midY; 32 | midC = midX; 33 | 34 | radius = 100; 35 | 36 | row1 = midR; 37 | col1 = midC + radius; 38 | } 39 | 40 | /// Paints the ROI into the supplied window 41 | /// HALCON window 42 | public override void draw(HalconDotNet.HWindow window) 43 | { 44 | window.DispCircle(midR, midC, radius); 45 | window.DispRectangle2(row1, col1, 0, 5, 5); 46 | window.DispRectangle2(midR, midC, 0, 5, 5); 47 | } 48 | 49 | /// 50 | /// Returns the distance of the ROI handle being 51 | /// closest to the image point(x,y) 52 | /// 53 | public override double distToClosestHandle(double x, double y) 54 | { 55 | double max = 10000; 56 | double [] val = new double[NumHandles]; 57 | 58 | val[0] = HMisc.DistancePp(y, x, row1, col1); // border handle 59 | val[1] = HMisc.DistancePp(y, x, midR, midC); // midpoint 60 | 61 | for (int i=0; i < NumHandles; i++) 62 | { 63 | if (val[i] < max) 64 | { 65 | max = val[i]; 66 | activeHandleIdx = i; 67 | } 68 | }// end of for 69 | return val[activeHandleIdx]; 70 | } 71 | 72 | /// 73 | /// Paints the active handle of the ROI object into the supplied window 74 | /// 75 | public override void displayActive(HalconDotNet.HWindow window) 76 | { 77 | 78 | switch (activeHandleIdx) 79 | { 80 | case 0: 81 | window.DispRectangle2(row1, col1, 0, 5, 5); 82 | break; 83 | case 1: 84 | window.DispRectangle2(midR, midC, 0, 5, 5); 85 | break; 86 | } 87 | } 88 | 89 | /// Gets the HALCON region described by the ROI 90 | public override HRegion getRegion() 91 | { 92 | HRegion region = new HRegion(); 93 | region.GenCircle(midR, midC, radius); 94 | return region; 95 | } 96 | 97 | public override double getDistanceFromStartPoint(double row, double col) 98 | { 99 | double sRow = midR; // assumption: we have an angle starting at 0.0 100 | double sCol = midC + 1 * radius; 101 | 102 | double angle = HMisc.AngleLl(midR, midC, sRow, sCol, midR, midC, row, col); 103 | 104 | if (angle < 0) 105 | angle += 2 * Math.PI; 106 | 107 | return (radius * angle); 108 | } 109 | 110 | /// 111 | /// Gets the model information described by 112 | /// the ROI 113 | /// 114 | public override HTuple getModelData() 115 | { 116 | return new HTuple(new double[] { midR, midC, radius }); 117 | } 118 | 119 | /// 120 | /// Recalculates the shape of the ROI. Translation is 121 | /// performed at the active handle of the ROI object 122 | /// for the image coordinate (x,y) 123 | /// 124 | public override void moveByHandle(double newX, double newY) 125 | { 126 | HTuple distance; 127 | double shiftX,shiftY; 128 | 129 | switch (activeHandleIdx) 130 | { 131 | case 0: // handle at circle border 132 | 133 | row1 = newY; 134 | col1 = newX; 135 | HOperatorSet.DistancePp(new HTuple(row1), new HTuple(col1), 136 | new HTuple(midR), new HTuple(midC), 137 | out distance); 138 | 139 | radius = distance[0].D; 140 | break; 141 | case 1: // midpoint 142 | 143 | shiftY = midR - newY; 144 | shiftX = midC - newX; 145 | 146 | midR = newY; 147 | midC = newX; 148 | 149 | row1 -= shiftY; 150 | col1 -= shiftX; 151 | break; 152 | } 153 | } 154 | }//end of class 155 | }//end of namespace 156 | -------------------------------------------------------------------------------- /base/ViewROI/vs2005/ViewROI.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | Debug 4 | AnyCPU 5 | 8.0.50727 6 | 2.0 7 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F} 8 | Library 9 | Properties 10 | ViewROI 11 | ViewROI 12 | 13 | 14 | true 15 | full 16 | false 17 | bin\Debug\ 18 | DEBUG;TRACE 19 | prompt 20 | 4 21 | 22 | 23 | pdbonly 24 | true 25 | bin\Release\ 26 | TRACE 27 | prompt 28 | 4 29 | 30 | 31 | 32 | False 33 | $(HALCONROOT)\bin\dotnet20\halcondotnet.dll 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | AssemblyInfo.cs 44 | 45 | 46 | FunctionPlot.cs 47 | 48 | 49 | GraphicsContext.cs 50 | 51 | 52 | HObjectEntry.cs 53 | 54 | 55 | HWndCtrl.cs 56 | 57 | 58 | ROI.cs 59 | 60 | 61 | ROICircle.cs 62 | 63 | 64 | ROICircularArc.cs 65 | 66 | 67 | ROIController.cs 68 | 69 | 70 | ROILine.cs 71 | 72 | 73 | ROIRectangle1.cs 74 | 75 | 76 | ROIRectangle2.cs 77 | 78 | 79 | 80 | 81 | 82 | 83 | 90 | -------------------------------------------------------------------------------- /base/ViewROI/vs2005/ViewROI.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 9.00 3 | # Visual Studio 2005 4 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ViewROI", "ViewROI.csproj", "{C4F5C5DE-7EA8-47FE-8218-48138F48965F}" 5 | EndProject 6 | Global 7 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 8 | Debug|Any CPU = Debug|Any CPU 9 | Release|Any CPU = Release|Any CPU 10 | EndGlobalSection 11 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 12 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 13 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Debug|Any CPU.Build.0 = Debug|Any CPU 14 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Release|Any CPU.ActiveCfg = Release|Any CPU 15 | {C4F5C5DE-7EA8-47FE-8218-48138F48965F}.Release|Any CPU.Build.0 = Release|Any CPU 16 | EndGlobalSection 17 | GlobalSection(SolutionProperties) = preSolution 18 | HideSolutionNode = FALSE 19 | EndGlobalSection 20 | EndGlobal 21 | -------------------------------------------------------------------------------- /controls/HDisplayControl/source/HObjectEntry.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using HalconDotNet; 3 | using System.Collections; 4 | 5 | 6 | 7 | namespace HDisplayControl.ViewROI 8 | { 9 | 10 | /// 11 | /// This class is an auxiliary class, which is used to 12 | /// link a graphical context to an HALCON object. The graphical 13 | /// context is described by a hashtable, which contains a list of 14 | /// graphical modes (e.g GC_COLOR, GC_LINEWIDTH and GC_PAINT) 15 | /// and their corresponding values (e.g "blue", "4", "3D-plot"). These 16 | /// graphical states are applied to the window before displaying the 17 | /// object. 18 | /// 19 | public class HObjectEntry 20 | { 21 | /// Hashlist defining the graphical context for HObj 22 | public Hashtable gContext; 23 | 24 | /// HALCON object 25 | public HObject HObj; 26 | 27 | public bool isRegion; 28 | public int RegionID; 29 | 30 | /// Constructor 31 | /// 32 | /// HALCON object that is linked to the graphical context gc. 33 | /// 34 | /// 35 | /// Hashlist of graphical states that are applied before the object 36 | /// is displayed. 37 | /// 38 | public HObjectEntry(HObject obj, Hashtable gc) 39 | { 40 | gContext = gc; 41 | HObj = obj; 42 | isRegion = false; 43 | } 44 | 45 | /// 46 | /// Clears the entries of the class members Hobj and gContext 47 | /// 48 | public void clear() 49 | { 50 | gContext.Clear(); 51 | HObj.Dispose(); 52 | } 53 | 54 | }//end of class 55 | }//end of namespace 56 | -------------------------------------------------------------------------------- /controls/HDisplayControl/source/ROI.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using HalconDotNet; 3 | 4 | 5 | namespace HDisplayControl.ViewROI 6 | { 7 | 8 | /// 9 | /// This class is a base class containing virtual methods for handling 10 | /// ROIs. Therefore, an inheriting class needs to define/override these 11 | /// methods to provide the ROIController with the necessary information on 12 | /// its (= the ROIs) shape and position. The example project provides 13 | /// derived ROI shapes for rectangles, lines, circles, and circular arcs. 14 | /// To use other shapes you must derive a new class from the base class 15 | /// ROI and implement its methods. 16 | /// 17 | public class ROI 18 | { 19 | 20 | // class members of inheriting ROI classes 21 | protected int NumHandles; 22 | protected int activeHandleIdx; 23 | 24 | /// 25 | /// Flag to define the ROI to be 'positive' or 'negative'. 26 | /// 27 | protected int OperatorFlag; 28 | 29 | /// Parameter to define the line style of the ROI. 30 | public HTuple flagLineStyle; 31 | 32 | /// Constant for a positive ROI flag. 33 | public const int POSITIVE_FLAG = ROIController.MODE_ROI_POS; 34 | 35 | /// Constant for a negative ROI flag. 36 | public const int NEGATIVE_FLAG = ROIController.MODE_ROI_NEG; 37 | 38 | public const int ROI_TYPE_LINE = 10; 39 | public const int ROI_TYPE_CIRCLE = 11; 40 | public const int ROI_TYPE_CIRCLEARC = 12; 41 | public const int ROI_TYPE_RECTANCLE1 = 13; 42 | public const int ROI_TYPE_RECTANGLE2 = 14; 43 | 44 | 45 | protected HTuple posOperation = new HTuple(); 46 | protected HTuple negOperation = new HTuple(new int[] { 2, 2 }); 47 | 48 | /// Constructor of abstract ROI class. 49 | public ROI() { } 50 | 51 | /// Creates a new ROI instance at the mouse position. 52 | /// 53 | /// x (=column) coordinate for ROI 54 | /// 55 | /// 56 | /// y (=row) coordinate for ROI 57 | /// 58 | public virtual void createROI(double midX, double midY) { } 59 | 60 | /// Paints the ROI into the supplied window. 61 | /// HALCON window 62 | public virtual void draw(HalconDotNet.HWindow window) { } 63 | 64 | /// 65 | /// Returns the distance of the ROI handle being 66 | /// closest to the image point(x,y) 67 | /// 68 | /// x (=column) coordinate 69 | /// y (=row) coordinate 70 | /// 71 | /// Distance of the closest ROI handle. 72 | /// 73 | public virtual double distToClosestHandle(double x, double y) 74 | { 75 | return 0.0; 76 | } 77 | 78 | /// 79 | /// Paints the active handle of the ROI object into the supplied window. 80 | /// 81 | /// HALCON window 82 | public virtual void displayActive(HalconDotNet.HWindow window) { } 83 | 84 | /// 85 | /// Recalculates the shape of the ROI. Translation is 86 | /// performed at the active handle of the ROI object 87 | /// for the image coordinate (x,y). 88 | /// 89 | /// x (=column) coordinate 90 | /// y (=row) coordinate 91 | public virtual void moveByHandle(double x, double y) { } 92 | 93 | /// Gets the HALCON region described by the ROI. 94 | public virtual HRegion getRegion() 95 | { 96 | return null; 97 | } 98 | 99 | public virtual double getDistanceFromStartPoint(double row, double col) 100 | { 101 | return 0.0; 102 | } 103 | /// 104 | /// Gets the model information described by 105 | /// the ROI. 106 | /// 107 | public virtual HTuple getModelData() 108 | { 109 | return null; 110 | } 111 | 112 | /// Number of handles defined for the ROI. 113 | /// Number of handles 114 | public int getNumHandles() 115 | { 116 | return NumHandles; 117 | } 118 | 119 | /// Gets the active handle of the ROI. 120 | /// Index of the active handle (from the handle list) 121 | public int getActHandleIdx() 122 | { 123 | return activeHandleIdx; 124 | } 125 | 126 | /// 127 | /// Gets the sign of the ROI object, being either 128 | /// 'positive' or 'negative'. This sign is used when creating a model 129 | /// region for matching applications from a list of ROIs. 130 | /// 131 | public int getOperatorFlag() 132 | { 133 | return OperatorFlag; 134 | } 135 | 136 | /// 137 | /// Sets the sign of a ROI object to be positive or negative. 138 | /// The sign is used when creating a model region for matching 139 | /// applications by summing up all positive and negative ROI models 140 | /// created so far. 141 | /// 142 | /// Sign of ROI object 143 | public void setOperatorFlag(int flag) 144 | { 145 | OperatorFlag = flag; 146 | 147 | switch (OperatorFlag) 148 | { 149 | case ROI.POSITIVE_FLAG: 150 | flagLineStyle = posOperation; 151 | break; 152 | case ROI.NEGATIVE_FLAG: 153 | flagLineStyle = negOperation; 154 | break; 155 | default: 156 | flagLineStyle = posOperation; 157 | break; 158 | } 159 | } 160 | }//end of class 161 | }//end of namespace 162 | -------------------------------------------------------------------------------- /controls/HDisplayControl/source/ROICircle.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using HalconDotNet; 3 | 4 | namespace HDisplayControl.ViewROI 5 | { 6 | /// 7 | /// This class demonstrates one of the possible implementations for a 8 | /// circular ROI. ROICircle inherits from the base class ROI and 9 | /// implements (besides other auxiliary methods) all virtual methods 10 | /// defined in ROI.cs. 11 | /// 12 | public class ROICircle : ROI 13 | { 14 | 15 | private double radius; 16 | private double row1, col1; // first handle 17 | private double midR, midC; // second handle 18 | 19 | 20 | public ROICircle() 21 | { 22 | NumHandles = 2; // one at corner of circle + midpoint 23 | activeHandleIdx = 1; 24 | } 25 | 26 | 27 | 28 | /// Creates a new ROI instance at the mouse position 29 | public override void createROI(double midX, double midY) 30 | { 31 | midR = midY; 32 | midC = midX; 33 | 34 | radius = 100; 35 | 36 | row1 = midR; 37 | col1 = midC + radius; 38 | } 39 | 40 | /// Paints the ROI into the supplied window 41 | /// HALCON window 42 | public override void draw(HalconDotNet.HWindow window) 43 | { 44 | window.DispCircle(midR, midC, radius); 45 | window.DispRectangle2(row1, col1, 0, 5, 5); 46 | window.DispRectangle2(midR, midC, 0, 5, 5); 47 | } 48 | 49 | /// 50 | /// Returns the distance of the ROI handle being 51 | /// closest to the image point(x,y) 52 | /// 53 | public override double distToClosestHandle(double x, double y) 54 | { 55 | double max = 10000; 56 | double [] val = new double[NumHandles]; 57 | 58 | val[0] = HMisc.DistancePp(y, x, row1, col1); // border handle 59 | val[1] = HMisc.DistancePp(y, x, midR, midC); // midpoint 60 | 61 | for (int i=0; i < NumHandles; i++) 62 | { 63 | if (val[i] < max) 64 | { 65 | max = val[i]; 66 | activeHandleIdx = i; 67 | } 68 | }// end of for 69 | return val[activeHandleIdx]; 70 | } 71 | 72 | /// 73 | /// Paints the active handle of the ROI object into the supplied window 74 | /// 75 | public override void displayActive(HalconDotNet.HWindow window) 76 | { 77 | 78 | switch (activeHandleIdx) 79 | { 80 | case 0: 81 | window.DispRectangle2(row1, col1, 0, 5, 5); 82 | break; 83 | case 1: 84 | window.DispRectangle2(midR, midC, 0, 5, 5); 85 | break; 86 | } 87 | } 88 | 89 | /// Gets the HALCON region described by the ROI 90 | public override HRegion getRegion() 91 | { 92 | HRegion region = new HRegion(); 93 | region.GenCircle(midR, midC, radius); 94 | return region; 95 | } 96 | 97 | public override double getDistanceFromStartPoint(double row, double col) 98 | { 99 | double sRow = midR; // assumption: we have an angle starting at 0.0 100 | double sCol = midC + 1 * radius; 101 | 102 | double angle = HMisc.AngleLl(midR, midC, sRow, sCol, midR, midC, row, col); 103 | 104 | if (angle < 0) 105 | angle += 2 * Math.PI; 106 | 107 | return (radius * angle); 108 | } 109 | 110 | /// 111 | /// Gets the model information described by 112 | /// the ROI 113 | /// 114 | public override HTuple getModelData() 115 | { 116 | return new HTuple(new double[] { midR, midC, radius }); 117 | } 118 | 119 | /// 120 | /// Recalculates the shape of the ROI. Translation is 121 | /// performed at the active handle of the ROI object 122 | /// for the image coordinate (x,y) 123 | /// 124 | public override void moveByHandle(double newX, double newY) 125 | { 126 | HTuple distance; 127 | double shiftX,shiftY; 128 | 129 | switch (activeHandleIdx) 130 | { 131 | case 0: // handle at circle border 132 | 133 | row1 = newY; 134 | col1 = newX; 135 | HOperatorSet.DistancePp(new HTuple(row1), new HTuple(col1), 136 | new HTuple(midR), new HTuple(midC), 137 | out distance); 138 | 139 | radius = distance[0].D; 140 | break; 141 | case 1: // midpoint 142 | 143 | shiftY = midR - newY; 144 | shiftX = midC - newX; 145 | 146 | midR = newY; 147 | midC = newX; 148 | 149 | row1 -= shiftY; 150 | col1 -= shiftX; 151 | break; 152 | } 153 | } 154 | }//end of class 155 | }//end of namespace 156 | -------------------------------------------------------------------------------- /controls/HDisplayControl/vs2005/HDisplayControl.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 9.00 3 | # Visual Studio 2005 4 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HDisplayControl", "HDisplayControl.csproj", "{65448F33-C957-49DF-A588-FDB0D6C25A37}" 5 | EndProject 6 | Global 7 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 8 | Debug|Any CPU = Debug|Any CPU 9 | Release|Any CPU = Release|Any CPU 10 | EndGlobalSection 11 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 12 | {65448F33-C957-49DF-A588-FDB0D6C25A37}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 13 | {65448F33-C957-49DF-A588-FDB0D6C25A37}.Debug|Any CPU.Build.0 = Debug|Any CPU 14 | {65448F33-C957-49DF-A588-FDB0D6C25A37}.Release|Any CPU.ActiveCfg = Release|Any CPU 15 | {65448F33-C957-49DF-A588-FDB0D6C25A37}.Release|Any CPU.Build.0 = Release|Any CPU 16 | EndGlobalSection 17 | GlobalSection(SolutionProperties) = preSolution 18 | HideSolutionNode = FALSE 19 | EndGlobalSection 20 | EndGlobal 21 | -------------------------------------------------------------------------------- /controls/HDisplayControl/vs2005/Resources/clear_roi_sel.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rtigithub/HALCON-12-codelets/323f337ec58c5d4845be1ae35f3238aab4e6459a/controls/HDisplayControl/vs2005/Resources/clear_roi_sel.png -------------------------------------------------------------------------------- /controls/HDisplayControl/vs2005/Resources/gen_circle.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rtigithub/HALCON-12-codelets/323f337ec58c5d4845be1ae35f3238aab4e6459a/controls/HDisplayControl/vs2005/Resources/gen_circle.png -------------------------------------------------------------------------------- /controls/HDisplayControl/vs2005/Resources/gen_circular_arc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rtigithub/HALCON-12-codelets/323f337ec58c5d4845be1ae35f3238aab4e6459a/controls/HDisplayControl/vs2005/Resources/gen_circular_arc.png -------------------------------------------------------------------------------- /controls/HDisplayControl/vs2005/Resources/gen_line.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rtigithub/HALCON-12-codelets/323f337ec58c5d4845be1ae35f3238aab4e6459a/controls/HDisplayControl/vs2005/Resources/gen_line.png -------------------------------------------------------------------------------- /controls/HDisplayControl/vs2005/Resources/gen_rect1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rtigithub/HALCON-12-codelets/323f337ec58c5d4845be1ae35f3238aab4e6459a/controls/HDisplayControl/vs2005/Resources/gen_rect1.png -------------------------------------------------------------------------------- /controls/HDisplayControl/vs2005/Resources/gen_rect2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rtigithub/HALCON-12-codelets/323f337ec58c5d4845be1ae35f3238aab4e6459a/controls/HDisplayControl/vs2005/Resources/gen_rect2.png -------------------------------------------------------------------------------- /controls/HDisplayControl/vs2005/Resources/roi_op_difference.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rtigithub/HALCON-12-codelets/323f337ec58c5d4845be1ae35f3238aab4e6459a/controls/HDisplayControl/vs2005/Resources/roi_op_difference.png -------------------------------------------------------------------------------- /controls/HDisplayControl/vs2005/Resources/roi_op_union.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rtigithub/HALCON-12-codelets/323f337ec58c5d4845be1ae35f3238aab4e6459a/controls/HDisplayControl/vs2005/Resources/roi_op_union.png -------------------------------------------------------------------------------- /controls/HImageAcquisition/source/HImageAcquisition.Designer.cs: -------------------------------------------------------------------------------- 1 | namespace HImageAcquisition 2 | { 3 | partial class HImageAcquisition 4 | { 5 | /// 6 | /// Required designer variable. 7 | /// 8 | private System.ComponentModel.IContainer components = null; 9 | 10 | /// 11 | /// Clean up any resources being used. 12 | /// 13 | /// true if managed resources should be disposed; otherwise, false. 14 | protected override void Dispose(bool disposing) 15 | { 16 | if (disposing && (components != null)) 17 | { 18 | components.Dispose(); 19 | } 20 | base.Dispose(disposing); 21 | } 22 | 23 | #region Component Designer generated code 24 | 25 | /// 26 | /// Required method for Designer support - do not modify 27 | /// the contents of this method with the code editor. 28 | /// 29 | private void InitializeComponent() 30 | { 31 | components = new System.ComponentModel.Container(); 32 | } 33 | 34 | #endregion 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /controls/HImageAcquisition/source/HImageAcquisition.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rtigithub/HALCON-12-codelets/323f337ec58c5d4845be1ae35f3238aab4e6459a/controls/HImageAcquisition/source/HImageAcquisition.cs -------------------------------------------------------------------------------- /controls/HImageAcquisition/source/IAParameterEntry.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Text; 4 | using HalconDotNet; 5 | 6 | namespace HImageAcquisition 7 | { 8 | 9 | /// 10 | /// The class contains the name and the value 11 | /// of a parameter of an image acquisition interface 12 | /// 13 | class IAParameterEntry 14 | { 15 | string parameterName; 16 | HTuple parameterValue; 17 | 18 | 19 | /// 20 | /// Constructor 21 | /// 22 | public IAParameterEntry(string paramName, HTuple paramValue) 23 | { 24 | this.parameterName = paramName; 25 | this.parameterValue = paramValue; 26 | } 27 | 28 | /// 29 | /// Gets a parameter name. The parameter name doesn't change. 30 | /// 31 | public string ParameterName 32 | { 33 | get 34 | { 35 | return this.parameterName; 36 | } 37 | } 38 | 39 | /// 40 | /// Gets a parameter name as a tuple. 41 | /// The parameter name doesn't change. 42 | /// 43 | public HTuple ParameterNameTuple 44 | { 45 | get 46 | { 47 | return new HTuple(this.parameterName); 48 | } 49 | } 50 | 51 | /// 52 | /// Gets or sets a parameter value 53 | /// 54 | public HTuple ParameterValue 55 | { 56 | get 57 | { 58 | return this.parameterValue; 59 | } 60 | set 61 | { 62 | this.parameterValue = value; 63 | } 64 | } 65 | 66 | } 67 | } 68 | -------------------------------------------------------------------------------- /controls/HImageAcquisition/vs2005/HImageAcquisition.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 9.00 3 | # Visual Studio 2005 4 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HImageAcquisition", "HImageAcquisition.csproj", "{39205745-A672-4B06-94EA-E857C5684808}" 5 | EndProject 6 | Global 7 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 8 | Debug|Any CPU = Debug|Any CPU 9 | Release|Any CPU = Release|Any CPU 10 | EndGlobalSection 11 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 12 | {39205745-A672-4B06-94EA-E857C5684808}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 13 | {39205745-A672-4B06-94EA-E857C5684808}.Debug|Any CPU.Build.0 = Debug|Any CPU 14 | {39205745-A672-4B06-94EA-E857C5684808}.Release|Any CPU.ActiveCfg = Release|Any CPU 15 | {39205745-A672-4B06-94EA-E857C5684808}.Release|Any CPU.Build.0 = Release|Any CPU 16 | EndGlobalSection 17 | GlobalSection(SolutionProperties) = preSolution 18 | HideSolutionNode = FALSE 19 | EndGlobalSection 20 | EndGlobal 21 | -------------------------------------------------------------------------------- /controls/examples/GrabAndDisplay/vs2005/Backup/GrabAndDisplay.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | Debug 4 | AnyCPU 5 | 8.0.50727 6 | 2.0 7 | {511CF3B4-B069-4F9B-BF5A-17EC799CA809} 8 | WinExe 9 | Properties 10 | GrabAndDisplay 11 | GrabAndDisplay 12 | 13 | 14 | 15 | 16 | true 17 | full 18 | false 19 | bin\Debug\ 20 | DEBUG;TRACE 21 | prompt 22 | 4 23 | 24 | 25 | pdbonly 26 | true 27 | bin\Release\ 28 | TRACE 29 | prompt 30 | 4 31 | 32 | 33 | 34 | False 35 | $(HALCONROOT)\bin\dotnet20\halcondotnet.dll 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | {65448F33-C957-49DF-A588-FDB0D6C25A37} 47 | HDisplayControl 48 | 49 | 50 | {39205745-A672-4B06-94EA-E857C5684808} 51 | HImageAcquisition 52 | 53 | 54 | 55 | 56 | GrabAndDisplayForm.cs 57 | Form 58 | 59 | 60 | GrabAndDisplayForm.Designer.cs 61 | GrabAndDisplayForm.cs 62 | 63 | 64 | 65 | 66 | GrabAndDisplayForm.resx 67 | GrabAndDisplayForm.cs 68 | Designer 69 | 70 | 71 | 72 | 73 | 74 | 75 | 82 | -------------------------------------------------------------------------------- /controls/examples/GrabAndDisplay/vs2005/Backup/GrabAndDisplay.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 9.00 3 | # Visual Studio 2005 4 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HImageAcquisition", "..\..\..\HImageAcquisition\vs2005\HImageAcquisition.csproj", "{39205745-A672-4B06-94EA-E857C5684808}" 5 | EndProject 6 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "GrabAndDisplay", "GrabAndDisplay.csproj", "{511CF3B4-B069-4F9B-BF5A-17EC799CA809}" 7 | EndProject 8 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HDisplayControl", "..\..\..\HDisplayControl\vs2005\HDisplayControl.csproj", "{65448F33-C957-49DF-A588-FDB0D6C25A37}" 9 | EndProject 10 | Global 11 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 12 | Debug|Any CPU = Debug|Any CPU 13 | Release|Any CPU = Release|Any CPU 14 | EndGlobalSection 15 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 16 | {39205745-A672-4B06-94EA-E857C5684808}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 17 | {39205745-A672-4B06-94EA-E857C5684808}.Debug|Any CPU.Build.0 = Debug|Any CPU 18 | {39205745-A672-4B06-94EA-E857C5684808}.Release|Any CPU.ActiveCfg = Release|Any CPU 19 | {39205745-A672-4B06-94EA-E857C5684808}.Release|Any CPU.Build.0 = Release|Any CPU 20 | {511CF3B4-B069-4F9B-BF5A-17EC799CA809}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 21 | {511CF3B4-B069-4F9B-BF5A-17EC799CA809}.Debug|Any CPU.Build.0 = Debug|Any CPU 22 | {511CF3B4-B069-4F9B-BF5A-17EC799CA809}.Release|Any CPU.ActiveCfg = Release|Any CPU 23 | {511CF3B4-B069-4F9B-BF5A-17EC799CA809}.Release|Any CPU.Build.0 = Release|Any CPU 24 | {65448F33-C957-49DF-A588-FDB0D6C25A37}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 25 | {65448F33-C957-49DF-A588-FDB0D6C25A37}.Debug|Any CPU.Build.0 = Debug|Any CPU 26 | {65448F33-C957-49DF-A588-FDB0D6C25A37}.Release|Any CPU.ActiveCfg = Release|Any CPU 27 | {65448F33-C957-49DF-A588-FDB0D6C25A37}.Release|Any CPU.Build.0 = Release|Any CPU 28 | EndGlobalSection 29 | GlobalSection(SolutionProperties) = preSolution 30 | HideSolutionNode = FALSE 31 | EndGlobalSection 32 | EndGlobal 33 | -------------------------------------------------------------------------------- /controls/examples/GrabAndDisplay/vs2005/Backup/HDisplayControl/HDisplayControl.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | Debug 4 | AnyCPU 5 | 8.0.50727 6 | 2.0 7 | {65448F33-C957-49DF-A588-FDB0D6C25A37} 8 | Library 9 | Properties 10 | HDisplayControl 11 | HDisplayControl 12 | 13 | 14 | true 15 | full 16 | false 17 | bin\Debug\ 18 | DEBUG;TRACE 19 | prompt 20 | 4 21 | 22 | 23 | pdbonly 24 | true 25 | bin\Release\ 26 | TRACE 27 | prompt 28 | 4 29 | 30 | 31 | 32 | False 33 | $(HALCONROOT)\bin\dotnet20\halcondotnet.dll 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | FunctionPlot.cs 44 | 45 | 46 | GraphicsContext.cs 47 | 48 | 49 | HDisplayControl.cs 50 | UserControl 51 | 52 | 53 | HDisplayControl.Designer.cs 54 | HDisplayControl.cs 55 | 56 | 57 | HObjectEntry.cs 58 | 59 | 60 | HWndCtrl.cs 61 | 62 | 63 | ROI.cs 64 | 65 | 66 | ROICircle.cs 67 | 68 | 69 | ROICircularArc.cs 70 | 71 | 72 | ROIController.cs 73 | 74 | 75 | ROILine.cs 76 | 77 | 78 | ROIRectangle1.cs 79 | 80 | 81 | ROIRectangle2.cs 82 | 83 | 84 | True 85 | True 86 | Resources.resx 87 | 88 | 89 | 90 | 91 | HDisplayControl.resx 92 | HDisplayControl.cs 93 | Designer 94 | 95 | 96 | Designer 97 | ResXFileCodeGenerator 98 | Resources.Designer.cs 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 115 | 116 | 117 | 118 | 119 | 120 | 121 | 122 | 123 | 124 | 125 | 126 | 133 | -------------------------------------------------------------------------------- /controls/examples/GrabAndDisplay/vs2005/Backup/HDisplayControl/HObjectEntry.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using HalconDotNet; 3 | using System.Collections; 4 | 5 | 6 | 7 | namespace HDisplayControl.ViewROI 8 | { 9 | 10 | /// 11 | /// This class is an auxiliary class, which is used to 12 | /// link a graphical context to an HALCON object. The graphical 13 | /// context is described by a hashtable, which contains a list of 14 | /// graphical modes (e.g GC_COLOR, GC_LINEWIDTH and GC_PAINT) 15 | /// and their corresponding values (e.g "blue", "4", "3D-plot"). These 16 | /// graphical states are applied to the window before displaying the 17 | /// object. 18 | /// 19 | public class HObjectEntry 20 | { 21 | /// Hashlist defining the graphical context for HObj 22 | public Hashtable gContext; 23 | 24 | /// HALCON object 25 | public HObject HObj; 26 | 27 | public bool isRegion; 28 | public int RegionID; 29 | 30 | /// Constructor 31 | /// 32 | /// HALCON object that is linked to the graphical context gc. 33 | /// 34 | /// 35 | /// Hashlist of graphical states that are applied before the object 36 | /// is displayed. 37 | /// 38 | public HObjectEntry(HObject obj, Hashtable gc) 39 | { 40 | gContext = gc; 41 | HObj = obj; 42 | isRegion = false; 43 | } 44 | 45 | /// 46 | /// Clears the entries of the class members Hobj and gContext 47 | /// 48 | public void clear() 49 | { 50 | gContext.Clear(); 51 | HObj.Dispose(); 52 | } 53 | 54 | }//end of class 55 | }//end of namespace 56 | -------------------------------------------------------------------------------- /controls/examples/GrabAndDisplay/vs2005/Backup/HDisplayControl/Properties/Resources.Designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // Runtime Version:2.0.50727.5456 5 | // 6 | // Changes to this file may cause incorrect behavior and will be lost if 7 | // the code is regenerated. 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | namespace HDisplayControl.Properties { 12 | using System; 13 | 14 | 15 | /// 16 | /// A strongly-typed resource class, for looking up localized strings, etc. 17 | /// 18 | // This class was auto-generated by the StronglyTypedResourceBuilder 19 | // class via a tool like ResGen or Visual Studio. 20 | // To add or remove a member, edit your .ResX file then rerun ResGen 21 | // with the /str option, or rebuild your VS project. 22 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "2.0.0.0")] 23 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 24 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] 25 | internal class Resources { 26 | 27 | private static global::System.Resources.ResourceManager resourceMan; 28 | 29 | private static global::System.Globalization.CultureInfo resourceCulture; 30 | 31 | [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")] 32 | internal Resources() { 33 | } 34 | 35 | /// 36 | /// Returns the cached ResourceManager instance used by this class. 37 | /// 38 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] 39 | internal static global::System.Resources.ResourceManager ResourceManager { 40 | get { 41 | if (object.ReferenceEquals(resourceMan, null)) { 42 | global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("HDisplayControl.Properties.Resources", typeof(Resources).Assembly); 43 | resourceMan = temp; 44 | } 45 | return resourceMan; 46 | } 47 | } 48 | 49 | /// 50 | /// Overrides the current thread's CurrentUICulture property for all 51 | /// resource lookups using this strongly typed resource class. 52 | /// 53 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] 54 | internal static global::System.Globalization.CultureInfo Culture { 55 | get { 56 | return resourceCulture; 57 | } 58 | set { 59 | resourceCulture = value; 60 | } 61 | } 62 | 63 | internal static System.Drawing.Bitmap clear_roi_sel { 64 | get { 65 | object obj = ResourceManager.GetObject("clear_roi_sel", resourceCulture); 66 | return ((System.Drawing.Bitmap)(obj)); 67 | } 68 | } 69 | 70 | internal static System.Drawing.Bitmap gen_circle { 71 | get { 72 | object obj = ResourceManager.GetObject("gen_circle", resourceCulture); 73 | return ((System.Drawing.Bitmap)(obj)); 74 | } 75 | } 76 | 77 | internal static System.Drawing.Bitmap gen_circular_arc { 78 | get { 79 | object obj = ResourceManager.GetObject("gen_circular_arc", resourceCulture); 80 | return ((System.Drawing.Bitmap)(obj)); 81 | } 82 | } 83 | 84 | internal static System.Drawing.Bitmap gen_line { 85 | get { 86 | object obj = ResourceManager.GetObject("gen_line", resourceCulture); 87 | return ((System.Drawing.Bitmap)(obj)); 88 | } 89 | } 90 | 91 | internal static System.Drawing.Bitmap gen_rect1 { 92 | get { 93 | object obj = ResourceManager.GetObject("gen_rect1", resourceCulture); 94 | return ((System.Drawing.Bitmap)(obj)); 95 | } 96 | } 97 | 98 | internal static System.Drawing.Bitmap gen_rect2 { 99 | get { 100 | object obj = ResourceManager.GetObject("gen_rect2", resourceCulture); 101 | return ((System.Drawing.Bitmap)(obj)); 102 | } 103 | } 104 | 105 | internal static System.Drawing.Bitmap roi_op_difference { 106 | get { 107 | object obj = ResourceManager.GetObject("roi_op_difference", resourceCulture); 108 | return ((System.Drawing.Bitmap)(obj)); 109 | } 110 | } 111 | 112 | internal static System.Drawing.Bitmap roi_op_union { 113 | get { 114 | object obj = ResourceManager.GetObject("roi_op_union", resourceCulture); 115 | return ((System.Drawing.Bitmap)(obj)); 116 | } 117 | } 118 | } 119 | } 120 | -------------------------------------------------------------------------------- /controls/examples/GrabAndDisplay/vs2005/Backup/HDisplayControl/ROI.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using HalconDotNet; 3 | 4 | 5 | namespace HDisplayControl.ViewROI 6 | { 7 | 8 | /// 9 | /// This class is a base class containing virtual methods for handling 10 | /// ROIs. Therefore, an inheriting class needs to define/override these 11 | /// methods to provide the ROIController with the necessary information on 12 | /// its (= the ROIs) shape and position. The example project provides 13 | /// derived ROI shapes for rectangles, lines, circles, and circular arcs. 14 | /// To use other shapes you must derive a new class from the base class 15 | /// ROI and implement its methods. 16 | /// 17 | public class ROI 18 | { 19 | 20 | // class members of inheriting ROI classes 21 | protected int NumHandles; 22 | protected int activeHandleIdx; 23 | 24 | /// 25 | /// Flag to define the ROI to be 'positive' or 'negative'. 26 | /// 27 | protected int OperatorFlag; 28 | 29 | /// Parameter to define the line style of the ROI. 30 | public HTuple flagLineStyle; 31 | 32 | /// Constant for a positive ROI flag. 33 | public const int POSITIVE_FLAG = ROIController.MODE_ROI_POS; 34 | 35 | /// Constant for a negative ROI flag. 36 | public const int NEGATIVE_FLAG = ROIController.MODE_ROI_NEG; 37 | 38 | public const int ROI_TYPE_LINE = 10; 39 | public const int ROI_TYPE_CIRCLE = 11; 40 | public const int ROI_TYPE_CIRCLEARC = 12; 41 | public const int ROI_TYPE_RECTANCLE1 = 13; 42 | public const int ROI_TYPE_RECTANGLE2 = 14; 43 | 44 | 45 | protected HTuple posOperation = new HTuple(); 46 | protected HTuple negOperation = new HTuple(new int[] { 2, 2 }); 47 | 48 | /// Constructor of abstract ROI class. 49 | public ROI() { } 50 | 51 | /// Creates a new ROI instance at the mouse position. 52 | /// 53 | /// x (=column) coordinate for ROI 54 | /// 55 | /// 56 | /// y (=row) coordinate for ROI 57 | /// 58 | public virtual void createROI(double midX, double midY) { } 59 | 60 | /// Paints the ROI into the supplied window. 61 | /// HALCON window 62 | public virtual void draw(HalconDotNet.HWindow window) { } 63 | 64 | /// 65 | /// Returns the distance of the ROI handle being 66 | /// closest to the image point(x,y) 67 | /// 68 | /// x (=column) coordinate 69 | /// y (=row) coordinate 70 | /// 71 | /// Distance of the closest ROI handle. 72 | /// 73 | public virtual double distToClosestHandle(double x, double y) 74 | { 75 | return 0.0; 76 | } 77 | 78 | /// 79 | /// Paints the active handle of the ROI object into the supplied window. 80 | /// 81 | /// HALCON window 82 | public virtual void displayActive(HalconDotNet.HWindow window) { } 83 | 84 | /// 85 | /// Recalculates the shape of the ROI. Translation is 86 | /// performed at the active handle of the ROI object 87 | /// for the image coordinate (x,y). 88 | /// 89 | /// x (=column) coordinate 90 | /// y (=row) coordinate 91 | public virtual void moveByHandle(double x, double y) { } 92 | 93 | /// Gets the HALCON region described by the ROI. 94 | public virtual HRegion getRegion() 95 | { 96 | return null; 97 | } 98 | 99 | public virtual double getDistanceFromStartPoint(double row, double col) 100 | { 101 | return 0.0; 102 | } 103 | /// 104 | /// Gets the model information described by 105 | /// the ROI. 106 | /// 107 | public virtual HTuple getModelData() 108 | { 109 | return null; 110 | } 111 | 112 | /// Number of handles defined for the ROI. 113 | /// Number of handles 114 | public int getNumHandles() 115 | { 116 | return NumHandles; 117 | } 118 | 119 | /// Gets the active handle of the ROI. 120 | /// Index of the active handle (from the handle list) 121 | public int getActHandleIdx() 122 | { 123 | return activeHandleIdx; 124 | } 125 | 126 | /// 127 | /// Gets the sign of the ROI object, being either 128 | /// 'positive' or 'negative'. This sign is used when creating a model 129 | /// region for matching applications from a list of ROIs. 130 | /// 131 | public int getOperatorFlag() 132 | { 133 | return OperatorFlag; 134 | } 135 | 136 | /// 137 | /// Sets the sign of a ROI object to be positive or negative. 138 | /// The sign is used when creating a model region for matching 139 | /// applications by summing up all positive and negative ROI models 140 | /// created so far. 141 | /// 142 | /// Sign of ROI object 143 | public void setOperatorFlag(int flag) 144 | { 145 | OperatorFlag = flag; 146 | 147 | switch (OperatorFlag) 148 | { 149 | case ROI.POSITIVE_FLAG: 150 | flagLineStyle = posOperation; 151 | break; 152 | case ROI.NEGATIVE_FLAG: 153 | flagLineStyle = negOperation; 154 | break; 155 | default: 156 | flagLineStyle = posOperation; 157 | break; 158 | } 159 | } 160 | }//end of class 161 | }//end of namespace 162 | -------------------------------------------------------------------------------- /controls/examples/GrabAndDisplay/vs2005/Backup/HDisplayControl/ROICircle.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using HalconDotNet; 3 | 4 | namespace HDisplayControl.ViewROI 5 | { 6 | /// 7 | /// This class demonstrates one of the possible implementations for a 8 | /// circular ROI. ROICircle inherits from the base class ROI and 9 | /// implements (besides other auxiliary methods) all virtual methods 10 | /// defined in ROI.cs. 11 | /// 12 | public class ROICircle : ROI 13 | { 14 | 15 | private double radius; 16 | private double row1, col1; // first handle 17 | private double midR, midC; // second handle 18 | 19 | 20 | public ROICircle() 21 | { 22 | NumHandles = 2; // one at corner of circle + midpoint 23 | activeHandleIdx = 1; 24 | } 25 | 26 | 27 | 28 | /// Creates a new ROI instance at the mouse position 29 | public override void createROI(double midX, double midY) 30 | { 31 | midR = midY; 32 | midC = midX; 33 | 34 | radius = 100; 35 | 36 | row1 = midR; 37 | col1 = midC + radius; 38 | } 39 | 40 | /// Paints the ROI into the supplied window 41 | /// HALCON window 42 | public override void draw(HalconDotNet.HWindow window) 43 | { 44 | window.DispCircle(midR, midC, radius); 45 | window.DispRectangle2(row1, col1, 0, 5, 5); 46 | window.DispRectangle2(midR, midC, 0, 5, 5); 47 | } 48 | 49 | /// 50 | /// Returns the distance of the ROI handle being 51 | /// closest to the image point(x,y) 52 | /// 53 | public override double distToClosestHandle(double x, double y) 54 | { 55 | double max = 10000; 56 | double [] val = new double[NumHandles]; 57 | 58 | val[0] = HMisc.DistancePp(y, x, row1, col1); // border handle 59 | val[1] = HMisc.DistancePp(y, x, midR, midC); // midpoint 60 | 61 | for (int i=0; i < NumHandles; i++) 62 | { 63 | if (val[i] < max) 64 | { 65 | max = val[i]; 66 | activeHandleIdx = i; 67 | } 68 | }// end of for 69 | return val[activeHandleIdx]; 70 | } 71 | 72 | /// 73 | /// Paints the active handle of the ROI object into the supplied window 74 | /// 75 | public override void displayActive(HalconDotNet.HWindow window) 76 | { 77 | 78 | switch (activeHandleIdx) 79 | { 80 | case 0: 81 | window.DispRectangle2(row1, col1, 0, 5, 5); 82 | break; 83 | case 1: 84 | window.DispRectangle2(midR, midC, 0, 5, 5); 85 | break; 86 | } 87 | } 88 | 89 | /// Gets the HALCON region described by the ROI 90 | public override HRegion getRegion() 91 | { 92 | HRegion region = new HRegion(); 93 | region.GenCircle(midR, midC, radius); 94 | return region; 95 | } 96 | 97 | public override double getDistanceFromStartPoint(double row, double col) 98 | { 99 | double sRow = midR; // assumption: we have an angle starting at 0.0 100 | double sCol = midC + 1 * radius; 101 | 102 | double angle = HMisc.AngleLl(midR, midC, sRow, sCol, midR, midC, row, col); 103 | 104 | if (angle < 0) 105 | angle += 2 * Math.PI; 106 | 107 | return (radius * angle); 108 | } 109 | 110 | /// 111 | /// Gets the model information described by 112 | /// the ROI 113 | /// 114 | public override HTuple getModelData() 115 | { 116 | return new HTuple(new double[] { midR, midC, radius }); 117 | } 118 | 119 | /// 120 | /// Recalculates the shape of the ROI. Translation is 121 | /// performed at the active handle of the ROI object 122 | /// for the image coordinate (x,y) 123 | /// 124 | public override void moveByHandle(double newX, double newY) 125 | { 126 | HTuple distance; 127 | double shiftX,shiftY; 128 | 129 | switch (activeHandleIdx) 130 | { 131 | case 0: // handle at circle border 132 | 133 | row1 = newY; 134 | col1 = newX; 135 | HOperatorSet.DistancePp(new HTuple(row1), new HTuple(col1), 136 | new HTuple(midR), new HTuple(midC), 137 | out distance); 138 | 139 | radius = distance[0].D; 140 | break; 141 | case 1: // midpoint 142 | 143 | shiftY = midR - newY; 144 | shiftX = midC - newX; 145 | 146 | midR = newY; 147 | midC = newX; 148 | 149 | row1 -= shiftY; 150 | col1 -= shiftX; 151 | break; 152 | } 153 | } 154 | }//end of class 155 | }//end of namespace 156 | -------------------------------------------------------------------------------- /controls/examples/GrabAndDisplay/vs2005/Backup/HDisplayControl/Resources/clear_roi_sel.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rtigithub/HALCON-12-codelets/323f337ec58c5d4845be1ae35f3238aab4e6459a/controls/examples/GrabAndDisplay/vs2005/Backup/HDisplayControl/Resources/clear_roi_sel.png -------------------------------------------------------------------------------- /controls/examples/GrabAndDisplay/vs2005/Backup/HDisplayControl/Resources/gen_circle.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rtigithub/HALCON-12-codelets/323f337ec58c5d4845be1ae35f3238aab4e6459a/controls/examples/GrabAndDisplay/vs2005/Backup/HDisplayControl/Resources/gen_circle.png -------------------------------------------------------------------------------- /controls/examples/GrabAndDisplay/vs2005/Backup/HDisplayControl/Resources/gen_circular_arc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rtigithub/HALCON-12-codelets/323f337ec58c5d4845be1ae35f3238aab4e6459a/controls/examples/GrabAndDisplay/vs2005/Backup/HDisplayControl/Resources/gen_circular_arc.png -------------------------------------------------------------------------------- /controls/examples/GrabAndDisplay/vs2005/Backup/HDisplayControl/Resources/gen_line.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rtigithub/HALCON-12-codelets/323f337ec58c5d4845be1ae35f3238aab4e6459a/controls/examples/GrabAndDisplay/vs2005/Backup/HDisplayControl/Resources/gen_line.png -------------------------------------------------------------------------------- /controls/examples/GrabAndDisplay/vs2005/Backup/HDisplayControl/Resources/gen_rect1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rtigithub/HALCON-12-codelets/323f337ec58c5d4845be1ae35f3238aab4e6459a/controls/examples/GrabAndDisplay/vs2005/Backup/HDisplayControl/Resources/gen_rect1.png -------------------------------------------------------------------------------- /controls/examples/GrabAndDisplay/vs2005/Backup/HDisplayControl/Resources/gen_rect2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rtigithub/HALCON-12-codelets/323f337ec58c5d4845be1ae35f3238aab4e6459a/controls/examples/GrabAndDisplay/vs2005/Backup/HDisplayControl/Resources/gen_rect2.png -------------------------------------------------------------------------------- /controls/examples/GrabAndDisplay/vs2005/Backup/HDisplayControl/Resources/roi_op_difference.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rtigithub/HALCON-12-codelets/323f337ec58c5d4845be1ae35f3238aab4e6459a/controls/examples/GrabAndDisplay/vs2005/Backup/HDisplayControl/Resources/roi_op_difference.png -------------------------------------------------------------------------------- /controls/examples/GrabAndDisplay/vs2005/Backup/HDisplayControl/Resources/roi_op_union.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rtigithub/HALCON-12-codelets/323f337ec58c5d4845be1ae35f3238aab4e6459a/controls/examples/GrabAndDisplay/vs2005/Backup/HDisplayControl/Resources/roi_op_union.png -------------------------------------------------------------------------------- /controls/examples/GrabAndDisplay/vs2005/GrabAndDisplay.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 12.00 3 | # Visual Studio 2013 4 | VisualStudioVersion = 12.0.31101.0 5 | MinimumVisualStudioVersion = 10.0.40219.1 6 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HImageAcquisition", "..\..\..\HImageAcquisition\vs2005\HImageAcquisition.csproj", "{39205745-A672-4B06-94EA-E857C5684808}" 7 | EndProject 8 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "GrabAndDisplay", "GrabAndDisplay.csproj", "{511CF3B4-B069-4F9B-BF5A-17EC799CA809}" 9 | EndProject 10 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HDisplayControl", "..\..\..\HDisplayControl\vs2005\HDisplayControl.csproj", "{65448F33-C957-49DF-A588-FDB0D6C25A37}" 11 | EndProject 12 | Global 13 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 14 | Debug|Any CPU = Debug|Any CPU 15 | Debug|x64 = Debug|x64 16 | Debug|x86 = Debug|x86 17 | Release|Any CPU = Release|Any CPU 18 | Release|x64 = Release|x64 19 | Release|x86 = Release|x86 20 | EndGlobalSection 21 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 22 | {39205745-A672-4B06-94EA-E857C5684808}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 23 | {39205745-A672-4B06-94EA-E857C5684808}.Debug|Any CPU.Build.0 = Debug|Any CPU 24 | {39205745-A672-4B06-94EA-E857C5684808}.Debug|x64.ActiveCfg = Debug|x64 25 | {39205745-A672-4B06-94EA-E857C5684808}.Debug|x64.Build.0 = Debug|x64 26 | {39205745-A672-4B06-94EA-E857C5684808}.Debug|x86.ActiveCfg = Debug|x86 27 | {39205745-A672-4B06-94EA-E857C5684808}.Debug|x86.Build.0 = Debug|x86 28 | {39205745-A672-4B06-94EA-E857C5684808}.Release|Any CPU.ActiveCfg = Release|Any CPU 29 | {39205745-A672-4B06-94EA-E857C5684808}.Release|Any CPU.Build.0 = Release|Any CPU 30 | {39205745-A672-4B06-94EA-E857C5684808}.Release|x64.ActiveCfg = Release|x64 31 | {39205745-A672-4B06-94EA-E857C5684808}.Release|x64.Build.0 = Release|x64 32 | {39205745-A672-4B06-94EA-E857C5684808}.Release|x86.ActiveCfg = Release|x86 33 | {39205745-A672-4B06-94EA-E857C5684808}.Release|x86.Build.0 = Release|x86 34 | {511CF3B4-B069-4F9B-BF5A-17EC799CA809}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 35 | {511CF3B4-B069-4F9B-BF5A-17EC799CA809}.Debug|Any CPU.Build.0 = Debug|Any CPU 36 | {511CF3B4-B069-4F9B-BF5A-17EC799CA809}.Debug|x64.ActiveCfg = Debug|x64 37 | {511CF3B4-B069-4F9B-BF5A-17EC799CA809}.Debug|x64.Build.0 = Debug|x64 38 | {511CF3B4-B069-4F9B-BF5A-17EC799CA809}.Debug|x86.ActiveCfg = Debug|x86 39 | {511CF3B4-B069-4F9B-BF5A-17EC799CA809}.Debug|x86.Build.0 = Debug|x86 40 | {511CF3B4-B069-4F9B-BF5A-17EC799CA809}.Release|Any CPU.ActiveCfg = Release|Any CPU 41 | {511CF3B4-B069-4F9B-BF5A-17EC799CA809}.Release|Any CPU.Build.0 = Release|Any CPU 42 | {511CF3B4-B069-4F9B-BF5A-17EC799CA809}.Release|x64.ActiveCfg = Release|x64 43 | {511CF3B4-B069-4F9B-BF5A-17EC799CA809}.Release|x64.Build.0 = Release|x64 44 | {511CF3B4-B069-4F9B-BF5A-17EC799CA809}.Release|x86.ActiveCfg = Release|x86 45 | {511CF3B4-B069-4F9B-BF5A-17EC799CA809}.Release|x86.Build.0 = Release|x86 46 | {65448F33-C957-49DF-A588-FDB0D6C25A37}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 47 | {65448F33-C957-49DF-A588-FDB0D6C25A37}.Debug|Any CPU.Build.0 = Debug|Any CPU 48 | {65448F33-C957-49DF-A588-FDB0D6C25A37}.Debug|x64.ActiveCfg = Debug|x64 49 | {65448F33-C957-49DF-A588-FDB0D6C25A37}.Debug|x64.Build.0 = Debug|x64 50 | {65448F33-C957-49DF-A588-FDB0D6C25A37}.Debug|x86.ActiveCfg = Debug|x86 51 | {65448F33-C957-49DF-A588-FDB0D6C25A37}.Debug|x86.Build.0 = Debug|x86 52 | {65448F33-C957-49DF-A588-FDB0D6C25A37}.Release|Any CPU.ActiveCfg = Release|Any CPU 53 | {65448F33-C957-49DF-A588-FDB0D6C25A37}.Release|Any CPU.Build.0 = Release|Any CPU 54 | {65448F33-C957-49DF-A588-FDB0D6C25A37}.Release|x64.ActiveCfg = Release|x64 55 | {65448F33-C957-49DF-A588-FDB0D6C25A37}.Release|x64.Build.0 = Release|x64 56 | {65448F33-C957-49DF-A588-FDB0D6C25A37}.Release|x86.ActiveCfg = Release|x86 57 | {65448F33-C957-49DF-A588-FDB0D6C25A37}.Release|x86.Build.0 = Release|x86 58 | EndGlobalSection 59 | GlobalSection(SolutionProperties) = preSolution 60 | HideSolutionNode = FALSE 61 | EndGlobalSection 62 | EndGlobal 63 | -------------------------------------------------------------------------------- /controls/examples/SimpleGrabApplication/source/Form1.Designer.vb: -------------------------------------------------------------------------------- 1 | _ 2 | Partial Class Form1 3 | Inherits System.Windows.Forms.Form 4 | 5 | 'Form overrides dispose to clean up the component list. 6 | _ 7 | Protected Overrides Sub Dispose(ByVal disposing As Boolean) 8 | Try 9 | If disposing AndAlso components IsNot Nothing Then 10 | components.Dispose() 11 | End If 12 | Finally 13 | MyBase.Dispose(disposing) 14 | End Try 15 | End Sub 16 | 17 | 'Required by the Windows Form Designer 18 | Private components As System.ComponentModel.IContainer 19 | 20 | 'NOTE: The following procedure is required by the Windows Form Designer 21 | 'It can be modified using the Windows Form Designer. 22 | 'Do not modify it using the code editor. 23 | _ 24 | Private Sub InitializeComponent() 25 | Me.components = New System.ComponentModel.Container 26 | Me.Button1 = New System.Windows.Forms.Button 27 | Me.Button2 = New System.Windows.Forms.Button 28 | Me.HImageAcquisition1 = New HImageAcquisition.HImageAcquisition(Me.components) 29 | Me.HDisplayControl1 = New HDisplayControl.HDisplayControl 30 | Me.Button3 = New System.Windows.Forms.Button 31 | Me.SuspendLayout() 32 | ' 33 | 'Button1 34 | ' 35 | Me.Button1.Location = New System.Drawing.Point(541, 28) 36 | Me.Button1.Name = "Button1" 37 | Me.Button1.Size = New System.Drawing.Size(109, 23) 38 | Me.Button1.TabIndex = 1 39 | Me.Button1.Text = "Connect" 40 | Me.Button1.UseVisualStyleBackColor = True 41 | ' 42 | 'Button2 43 | ' 44 | Me.Button2.Location = New System.Drawing.Point(541, 75) 45 | Me.Button2.Name = "Button2" 46 | Me.Button2.Size = New System.Drawing.Size(109, 23) 47 | Me.Button2.TabIndex = 2 48 | Me.Button2.Text = "Start Grab" 49 | Me.Button2.UseVisualStyleBackColor = True 50 | ' 51 | 'HImageAcquisition1 52 | ' 53 | Me.HImageAcquisition1.CameraType = "coins" 54 | Me.HImageAcquisition1.HorizontalResolution = 1 55 | Me.HImageAcquisition1.LineIn = -1 56 | Me.HImageAcquisition1.Port = -1 57 | ' 58 | 'HDisplayControl1 59 | ' 60 | Me.HDisplayControl1.AutoScroll = True 61 | Me.HDisplayControl1.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink 62 | Me.HDisplayControl1.BackColor = System.Drawing.SystemColors.Control 63 | Me.HDisplayControl1.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D 64 | Me.HDisplayControl1.CurrentROI = Nothing 65 | Me.HDisplayControl1.Image = Nothing 66 | Me.HDisplayControl1.ImageViewState = HDisplayControl.ImageViewStates.fitToWindow 67 | Me.HDisplayControl1.Location = New System.Drawing.Point(12, 28) 68 | Me.HDisplayControl1.MinimumSize = New System.Drawing.Size(344, 293) 69 | Me.HDisplayControl1.MoveOnPressedMouseButton = True 70 | Me.HDisplayControl1.Name = "HDisplayControl1" 71 | Me.HDisplayControl1.Size = New System.Drawing.Size(512, 395) 72 | Me.HDisplayControl1.TabIndex = 0 73 | Me.HDisplayControl1.WindowSize = New System.Drawing.Size(488, 342) 74 | Me.HDisplayControl1.ZoomCenter = New System.Drawing.Point(160, 120) 75 | Me.HDisplayControl1.ZoomOnMouseWheel = False 76 | ' 77 | 'Button3 78 | ' 79 | Me.Button3.Location = New System.Drawing.Point(541, 124) 80 | Me.Button3.Name = "Button3" 81 | Me.Button3.Size = New System.Drawing.Size(109, 23) 82 | Me.Button3.TabIndex = 3 83 | Me.Button3.Text = "Stop Grab" 84 | Me.Button3.UseVisualStyleBackColor = True 85 | ' 86 | 'Form1 87 | ' 88 | Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!) 89 | Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font 90 | Me.ClientSize = New System.Drawing.Size(662, 489) 91 | Me.Controls.Add(Me.Button3) 92 | Me.Controls.Add(Me.Button2) 93 | Me.Controls.Add(Me.Button1) 94 | Me.Controls.Add(Me.HDisplayControl1) 95 | Me.Name = "Form1" 96 | Me.Text = "Form1" 97 | Me.ResumeLayout(False) 98 | 99 | End Sub 100 | Friend WithEvents HImageAcquisition1 As HImageAcquisition.HImageAcquisition 101 | Friend WithEvents HDisplayControl1 As HDisplayControl.HDisplayControl 102 | Friend WithEvents Button1 As System.Windows.Forms.Button 103 | Friend WithEvents Button2 As System.Windows.Forms.Button 104 | Friend WithEvents Button3 As System.Windows.Forms.Button 105 | 106 | End Class 107 | -------------------------------------------------------------------------------- /controls/examples/SimpleGrabApplication/source/Form1.vb: -------------------------------------------------------------------------------- 1 | '***************************************************************************** 2 | 'This VB/.NET project demonstrates how to use the new Codelet controls 3 | 'in Windows Forms application only using the pre-compiled DLLs. 4 | 'To execute this project, please, rebuild on your system the following 5 | 'provided projects: 6 | ' - $(HALCONEXAMPLES)/codelets/controls/HDisplayControl 7 | ' - $(HALCONEXAMPLES)/codelets/controls/HImageAcquisition 8 | 'The build proces will generate the necessary DLLs for this project. 9 | 'After the DLLs are generated, you can build and execute this project. 10 | '*****************************************************************************/ 11 | ' 12 | ' (c) 2014 by MVTec Software GmbH 13 | ' www.mvtec.com 14 | '****************************************************************************/ 15 | 16 | Imports HalconDotNet 17 | Imports HImageAcquisition 18 | Imports HDisplayControl 19 | 20 | 21 | 22 | 23 | Public Class Form1 24 | 25 | Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click 26 | Call HImageAcquisition1.OpenDevice() 27 | End Sub 28 | 29 | 30 | Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click 31 | 32 | If HImageAcquisition1.Connected Then 33 | Call HImageAcquisition1.StartGrabThread() 34 | End If 35 | End Sub 36 | 37 | Private Sub HImageAcquisition1_OnGrabbedImage(ByVal sender As System.Object, ByVal image As HalconDotNet.HImage) Handles HImageAcquisition1.OnGrabbedImage 38 | 39 | HDisplayControl1.Image = image 40 | HDisplayControl1.Invalidate() 41 | End Sub 42 | 43 | 44 | Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click 45 | Call HImageAcquisition1.StopGrabThread() 46 | End Sub 47 | End Class 48 | -------------------------------------------------------------------------------- /controls/examples/SimpleGrabApplication/vs2005/My Project/Application.Designer.vb: -------------------------------------------------------------------------------- 1 | '------------------------------------------------------------------------------ 2 | ' 3 | ' This code was generated by a tool. 4 | ' Runtime Version:2.0.50727.5456 5 | ' 6 | ' Changes to this file may cause incorrect behavior and will be lost if 7 | ' the code is regenerated. 8 | ' 9 | '------------------------------------------------------------------------------ 10 | 11 | Option Strict On 12 | Option Explicit On 13 | 14 | 15 | Namespace My 16 | 17 | 'NOTE: This file is auto-generated; do not modify it directly. To make changes, 18 | ' or if you encounter build errors in this file, go to the Project Designer 19 | ' (go to Project Properties or double-click the My Project node in 20 | ' Solution Explorer), and make changes on the Application tab. 21 | ' 22 | Partial Friend Class MyApplication 23 | 24 | _ 25 | Public Sub New() 26 | MyBase.New(Global.Microsoft.VisualBasic.ApplicationServices.AuthenticationMode.Windows) 27 | Me.IsSingleInstance = false 28 | Me.EnableVisualStyles = true 29 | Me.SaveMySettingsOnExit = true 30 | Me.ShutDownStyle = Global.Microsoft.VisualBasic.ApplicationServices.ShutdownMode.AfterMainFormCloses 31 | End Sub 32 | 33 | _ 34 | Protected Overrides Sub OnCreateMainForm() 35 | Me.MainForm = Global.SimpleGrabApplication.Form1 36 | End Sub 37 | End Class 38 | End Namespace 39 | -------------------------------------------------------------------------------- /controls/examples/SimpleGrabApplication/vs2005/My Project/Application.myapp: -------------------------------------------------------------------------------- 1 |  2 | 3 | true 4 | Form1 5 | false 6 | 0 7 | true 8 | 0 9 | 0 10 | true 11 | 12 | -------------------------------------------------------------------------------- /controls/examples/SimpleGrabApplication/vs2005/My Project/AssemblyInfo.vb: -------------------------------------------------------------------------------- 1 | Imports System 2 | Imports System.Reflection 3 | Imports System.Runtime.InteropServices 4 | 5 | ' General Information about an assembly is controlled through the following 6 | ' set of attributes. Change these attribute values to modify the information 7 | ' associated with an assembly. 8 | 9 | ' Review the values of the assembly attributes 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 'The following GUID is for the ID of the typelib if this project is exposed to COM 21 | 22 | 23 | ' Version information for an assembly consists of the following four values: 24 | ' 25 | ' Major Version 26 | ' Minor Version 27 | ' Build Number 28 | ' Revision 29 | ' 30 | ' You can specify all the values or you can default the Build and Revision Numbers 31 | ' by using the '*' as shown below: 32 | ' 33 | 34 | 35 | 36 | -------------------------------------------------------------------------------- /controls/examples/SimpleGrabApplication/vs2005/My Project/Resources.Designer.vb: -------------------------------------------------------------------------------- 1 | '------------------------------------------------------------------------------ 2 | ' 3 | ' This code was generated by a tool. 4 | ' Runtime Version:2.0.50727.5456 5 | ' 6 | ' Changes to this file may cause incorrect behavior and will be lost if 7 | ' the code is regenerated. 8 | ' 9 | '------------------------------------------------------------------------------ 10 | 11 | Option Strict On 12 | Option Explicit On 13 | 14 | 15 | Namespace My.Resources 16 | 17 | 'This class was auto-generated by the StronglyTypedResourceBuilder 18 | 'class via a tool like ResGen or Visual Studio. 19 | 'To add or remove a member, edit your .ResX file then rerun ResGen 20 | 'with the /str option, or rebuild your VS project. 21 | ' 22 | ' A strongly-typed resource class, for looking up localized strings, etc. 23 | ' 24 | _ 28 | Friend Module Resources 29 | 30 | Private resourceMan As Global.System.Resources.ResourceManager 31 | 32 | Private resourceCulture As Global.System.Globalization.CultureInfo 33 | 34 | ' 35 | ' Returns the cached ResourceManager instance used by this class. 36 | ' 37 | _ 38 | Friend ReadOnly Property ResourceManager() As Global.System.Resources.ResourceManager 39 | Get 40 | If Object.ReferenceEquals(resourceMan, Nothing) Then 41 | Dim temp As Global.System.Resources.ResourceManager = New Global.System.Resources.ResourceManager("SimpleGrabApplication.Resources", GetType(Resources).Assembly) 42 | resourceMan = temp 43 | End If 44 | Return resourceMan 45 | End Get 46 | End Property 47 | 48 | ' 49 | ' Overrides the current thread's CurrentUICulture property for all 50 | ' resource lookups using this strongly typed resource class. 51 | ' 52 | _ 53 | Friend Property Culture() As Global.System.Globalization.CultureInfo 54 | Get 55 | Return resourceCulture 56 | End Get 57 | Set(ByVal value As Global.System.Globalization.CultureInfo) 58 | resourceCulture = value 59 | End Set 60 | End Property 61 | End Module 62 | End Namespace 63 | -------------------------------------------------------------------------------- /controls/examples/SimpleGrabApplication/vs2005/My Project/Settings.Designer.vb: -------------------------------------------------------------------------------- 1 | '------------------------------------------------------------------------------ 2 | ' 3 | ' This code was generated by a tool. 4 | ' Runtime Version:2.0.50727.5456 5 | ' 6 | ' Changes to this file may cause incorrect behavior and will be lost if 7 | ' the code is regenerated. 8 | ' 9 | '------------------------------------------------------------------------------ 10 | 11 | Option Strict On 12 | Option Explicit On 13 | 14 | 15 | Namespace My 16 | 17 | _ 20 | Partial Friend NotInheritable Class MySettings 21 | Inherits Global.System.Configuration.ApplicationSettingsBase 22 | 23 | Private Shared defaultInstance As MySettings = CType(Global.System.Configuration.ApplicationSettingsBase.Synchronized(New MySettings), MySettings) 24 | 25 | #Region "My.Settings Auto-Save Functionality" 26 | #If _MyType = "WindowsForms" Then 27 | Private Shared addedHandler As Boolean 28 | 29 | Private Shared addedHandlerLockObject As New Object 30 | 31 | _ 32 | Private Shared Sub AutoSaveSettings(ByVal sender As Global.System.Object, ByVal e As Global.System.EventArgs) 33 | If My.Application.SaveMySettingsOnExit Then 34 | My.Settings.Save() 35 | End If 36 | End Sub 37 | #End If 38 | #End Region 39 | 40 | Public Shared ReadOnly Property [Default]() As MySettings 41 | Get 42 | 43 | #If _MyType = "WindowsForms" Then 44 | If Not addedHandler Then 45 | SyncLock addedHandlerLockObject 46 | If Not addedHandler Then 47 | AddHandler My.Application.Shutdown, AddressOf AutoSaveSettings 48 | addedHandler = True 49 | End If 50 | End SyncLock 51 | End If 52 | #End If 53 | Return defaultInstance 54 | End Get 55 | End Property 56 | End Class 57 | End Namespace 58 | 59 | Namespace My 60 | 61 | _ 64 | Friend Module MySettingsProperty 65 | 66 | _ 67 | Friend ReadOnly Property Settings() As Global.SimpleGrabApplication.My.MySettings 68 | Get 69 | Return Global.SimpleGrabApplication.My.MySettings.Default 70 | End Get 71 | End Property 72 | End Module 73 | End Namespace 74 | -------------------------------------------------------------------------------- /controls/examples/SimpleGrabApplication/vs2005/My Project/Settings.settings: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /controls/examples/SimpleGrabApplication/vs2005/SimpleGrabApplication.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 9.00 3 | # Visual Studio 2005 4 | Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "SimpleGrabApplication", "SimpleGrabApplication.vbproj", "{7A617711-396A-4EFF-8704-E43E571E5E67}" 5 | EndProject 6 | Global 7 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 8 | Debug|Any CPU = Debug|Any CPU 9 | Release|Any CPU = Release|Any CPU 10 | EndGlobalSection 11 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 12 | {7A617711-396A-4EFF-8704-E43E571E5E67}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 13 | {7A617711-396A-4EFF-8704-E43E571E5E67}.Debug|Any CPU.Build.0 = Debug|Any CPU 14 | {7A617711-396A-4EFF-8704-E43E571E5E67}.Release|Any CPU.ActiveCfg = Release|Any CPU 15 | {7A617711-396A-4EFF-8704-E43E571E5E67}.Release|Any CPU.Build.0 = Release|Any CPU 16 | EndGlobalSection 17 | GlobalSection(SolutionProperties) = preSolution 18 | HideSolutionNode = FALSE 19 | EndGlobalSection 20 | EndGlobal 21 | -------------------------------------------------------------------------------- /controls/examples/SimpleGrabApplication/vs2005/SimpleGrabApplication.vbproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | Debug 5 | AnyCPU 6 | 8.0.50727 7 | 2.0 8 | {7A617711-396A-4EFF-8704-E43E571E5E67} 9 | WinExe 10 | SimpleGrabApplication.My.MyApplication 11 | SimpleGrabApplication 12 | SimpleGrabApplication 13 | WindowsForms 14 | 15 | 16 | true 17 | full 18 | true 19 | true 20 | bin\Debug\ 21 | SimpleGrabApplication.xml 22 | 42016,41999,42017,42018,42019,42032,42036,42020,42021,42022 23 | 24 | 25 | pdbonly 26 | false 27 | true 28 | true 29 | bin\Release\ 30 | SimpleGrabApplication.xml 31 | 42016,41999,42017,42018,42019,42032,42036,42020,42021,42022 32 | 33 | 34 | 35 | False 36 | $(HALCONROOT)\bin\dotnet20\halcondotnet.dll 37 | 38 | 39 | False 40 | ..\..\..\HDisplayControl\vs2005\bin\Debug\HDisplayControl.dll 41 | 42 | 43 | False 44 | ..\..\..\HImageAcquisition\vs2005\bin\Debug\HImageAcquisition.dll 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | Form1.Designer.vb 66 | Form1.vb 67 | 68 | 69 | Form1.vb 70 | Form 71 | 72 | 73 | 74 | True 75 | Application.myapp 76 | 77 | 78 | True 79 | True 80 | Resources.resx 81 | 82 | 83 | True 84 | Settings.settings 85 | True 86 | 87 | 88 | 89 | 90 | Form1.resx 91 | Form1.vb 92 | Designer 93 | 94 | 95 | VbMyResourcesResXFileCodeGenerator 96 | Resources.Designer.vb 97 | My.Resources 98 | Designer 99 | 100 | 101 | 102 | 103 | MyApplicationCodeGenerator 104 | Application.Designer.vb 105 | 106 | 107 | SettingsSingleFileGenerator 108 | My 109 | Settings.Designer.vb 110 | 111 | 112 | 113 | 120 | --------------------------------------------------------------------------------