MATLAB COM Builder    

Creating a Project

To begin project creation, enter the MATLAB command comtool at the command line. The MATLAB COM Builder main window appears.

Figure 1-1: MATLAB COM Builder Main Window

For a complete description of the features available from this window, see Graphical User Interface Menus.

Select File -> New Project on this window to view the New Project Settings dialog box.

Figure 1-2: New Project Settings Dialog Box

Component name denotes the name of the DLL created later in the build process. After you enter the component name, the GUI automatically enters a Class name identical to the component name. You can change the class name to something more descriptive. Although the component name and class name can be the same, the component name cannot match the name of any M- or MEX-files added to the project later.

To add a class to your component, enter the class name in the Class name field and click Add>>. The added class now appears in the Classes list. .

The Project version default value is 1.0. See Versions for additional information about Project version.

Project directory specifies where any project and build files are written when compiling and packaging your models. The project directory is automatically generated from the name of your current directory and the component name.

You can choose to generate C or C++ code. Components written in C give better performance, while C++ components are more readable, allowing easier modification of the generated code if needed. The files generated pertaining to the COM interface are always C++ files regardless of which option you choose.

If your models contain MATLAB Handle Graphics® calls, include the MATLAB C/C++ Graphics library in your project by selecting Use Handle Graphics library.

You can also create a debug version of your compiled models and can specify verbose output when you invoke the MATLAB Compiler. A debug version of your component:

Once you accept these settings on the New Project Settings dialog box by clicking OK, they become part of your project workspace and are saved to the project file along with the names of any M- or MEX- files you subsequently add to the project. A project file of the name <component_name>.cbl is automatically saved to the project directory.


  Building a Deployable Application Managing M-Files and MEX-Files