HALCON and package directories🔗
Directory structure of a HALCON package🔗
A HALCON package resides in a directory with the same name as the package itself.
In our example, this is the directory halconuser in %HALCONEXAMPLES%\extension_package.
This directory must at least contain the following subdirectories:
bin\%HALCONARCH%- This subdirectory has to contain the DLLs
package.dll,packagec.dll, andpackagecpp.dll, corresponding to the above libraries (and their HALCON XL versions). We also recommend placing compiled example programs or additional utilities of a package in this subdirectory. lib\%HALCONARCH%-
In this subdirectory, the libraries encapsulating the new operators (
package) and the corresponding C and C++ language interfaces (packagec,packagecpp) reside, together with their HALCON XL versions.Important
Neither the name of these libraries nor their position within the package should be changed. Otherwise, the HALCON system cannot load the package.
The environment variable
HALCONARCHis set during the installation of HALCON; it describes the platform HALCON is running on. For more information, see the Installation reference. bin\dotnet- This subdirectory has to contain the extension package’s .NET assembly
packagedotnet.dll(and its HALCON XL version,packagedotnetxl.dll). help- This subdirectory contains files with data for the online access to the knowledge base.
They must be generated and placed in this directory in order to use a package inside of HDevelop. Without these files, HDevelop cannot retrieve the information needed to access the operators of a package.
lib/%HALCONARCH%-
In this subdirectory, the libraries encapsulating the new operators (
libpackage) and the corresponding C and C++ language interfaces (libpackagec, andlibpackagecpp) reside, together with their HALCON XL versions.Important
Neither the name of these libraries nor their position within the package should be changed. Otherwise, the HALCON system cannot load the package.
The environment variable
HALCONARCHis set during the installation of HALCON; it describes the platform HALCON is running on. See the Installation reference for details. help- This subdirectory contains files with data for the online access to the knowledge base.
They must be generated and placed in this directory in order to use a package inside of HDevelop. Without these files, HDevelop cannot retrieve the information needed to access the operators of a package.
We also recommend providing additional subdirectories:
def- In this directory, the DEF file(s) with the description of the operators of a package should be placed.
include- In this directory, the generated include files containing the prototypes for the operators of a package should be placed.
doc- In this directory, the documentation of the package should be placed (see also
%HALCONROOT%\docfor comparison). Especially, it is necessary to put the generated HTML files indoc\html\referenceto be able to access the online help from the operator window of HDevelop. examples- This directory may contain some typical example programs (for example, HDEV files) demonstrating the use of the new operators.
images- If the provided examples need specific images, they should be placed in this directory.
In that case, we recommend including the path to this subdirectory in the environment variable
HALCONIMAGESto allow access to these images without using an absolute file path in the programs.
HALCON directories🔗
HALCON always presumes that the environment variable HALCONROOT contains the path of the HALCON installation directory.
The following subdirectories are important for creating a new system:
include- HALCON include files for compiling
lib\%HALCONARCH%- HALCON libraries
dotnet20,dotnet35- HALCON/.NET assemblies for the different versions of the .NET Framework. For more information, see Environments and prerequisites.
bin\%HALCONARCH%- HALCON compiler
hcomp, under Windows also the HALCON DLLs doc\macros- LaTeX files for generating PDF reference files or manuals
The environment variable HALCONEXAMPLES contains the path of the HALCON programming examples.
The following subdirectory is useful for creating a new system:
extension_package\halconuser- Example for a HALCON extension package