Skip to content

Recipe Code Generator#

The Recipe Code Generator of the pylon Viewer allows you to generate sample code to use your vTool recipe in your development environment.

How It Works#

Using the Recipe Code Generator does the following:

  • The tool saves the currently opened recipe as a .precipe file in a specified folder.
  • The tool generates C++ sample code that allows you to load, start, and process the recipe. The sample code files are saved in the same folder as the recipe file.

Generating Recipe Code#

To generate recipe code for your application:

  1. Create a recipe or open an existing one.
  2. Open the Recipe Code Generator by clicking its icon in the Workbench toolbar or by clicking Workbench > Recipe Code Generator.
    Workbench Toolbar Screen
    The Recipe Code Generator window opens:
    Recipe Code Generator Window
  3. Adjust the settings:
    • Name: Enter the desired name for the recipe.
      The name will be used as the recipe file name (<name>.precipe). Also, the name is used in the generated code.
    • Destination Folder: Choose the folder in which you want to save the generated files. If the folder doesn't exist, it will be created.
  4. Click Generate.
    The generated files are placed in the destination folder specified.