Microsoft Visual C++

You can compile and link Visual C++ programs from the DOS command line or from Microsoft Visual Studio. The following Fastgraph libraries are compatible with Visual C++:

FGWVC32.LIB

Win32 library

FGWVC32D.LIB

Win32 library with DirectX support

To build Fastgraph applications in Microsoft Visual Studio, you must create a workspace that includes the name of each C and CPP source file comprising your application. The workspace must also include the name of the Fastgraph library for the selected platform. Refer to your Visual C++ manuals or on-line help for complete information about workspaces.

For Visual C++, the Fastgraph SETUP program normally installs MFC versions of the Fastgraph examples (created with Fastgraph's MFC AppWizard) and traditional C/C++ versions. The MFC versions are supplied as complete workspaces that you can load directly into Visual Studio, but you must manually create workspaces for the C/C++ versions.

To create a workspace for one of Fastgraph's C/C++ examples, start Visual Studio and select File|New. On the Projects tab, select "Win32 Application" and fill in the project name and location fields as desired. We'll create a workspace for the First.c example, so enter \FGW60\Examples\C for the location (this is where Fastgraph's SETUP program normally installs the C/C++ examples) and First for the project name. If you're using Visual C++ 6.0, you'll now be asked what type of Windows application you want to create; select "An empty project" and click Finish. Now we must add files to the workspace. Start by copying the C/C++ source code (the C or CPP file) and the resource script file if present (the RC file) into the workspace directory. For First.c, you would copy First.c from \FGW60\Examples\C to \FGW60\Examples\C\First (there is no resource script file for the First example). Back in Visual Studio, select Project|Add To Project|Files, and select First.c. If there is a resource script file, add it to the workspace too. Finally, add the Fastgraph library FGWVC32.LIB (or FGWVC32D.LIB if creating a DirectX application) to the workspace. By default, Fastgraph's SETUP program installs these libraries in the Visual C++ Lib directory, so you'll need to reference the library file name from that directory when adding it to the workspace.

To compile and link from the DOS command line, use the CL command:

CL -c -Gs -Ow -W3 -Zp -Tp <file>
LINK <file> GDI32.LIB COMDLG32.LIB USER32.LIB VFW32.LIB WINSPOOL.LIB
   {FGWVC32.LIB|FGWVC32D.LIB}

For more information about compiling and linking Visual C++ programs, please refer to your Visual C++ manuals or on-line help.

<< Prev

Next >>

Contents
Fastgraph Home Page

 

copyright 2001 Ted Gruber Software, Inc.