/*
Main.h
Written by Matthew Fisher

Main.h is included by all source files and includes every header file in the correct order.
*/

//commenting out the following lines will disable code involving the corresponding API.
//This can be useful if you lack some of the libraries involved with either API.
//Software rendering is always supported
#define USE_DIRECTX
#define USE_OPENGL

#define VECTOR_DEBUG

//OpenGL textures use glaux.lib to load textures.  As this is not OpenGL standard, you might
//not have the library or want ot get it (it has, apparently, known memory leaks and a few
//other problems, and is very old and no longer used.)  Eventually I will use another library
//like BMGLib (http://members.cox.net/scottheiman/bmglib.htm) to load files into OpenGL.
//If you want to compile without glaux (and thus OpenGL textures,) comment out the following line.
#define USE_OPENGL_TEXTURES

//Using a video as a texture involves a lot of libraries you may have problems loading,
//so commenting out this line disables loading them.  Note that if USE_DIRECTX is not defined,
//loading video textures is automatically disabled.
//#define USE_VIDEO_TEXTURES

//EngineInterface.h includes everything that rarely changes between applications, such as vector/matrix libraries,
//OpenGL/DirectX graphics devices, software rasterizers, etc.
#include "Engine.h"

//MainControl.h includes everything that changes often between applications, such as what meshes to load,
//and also determines what is rendered each frame.
#include "MainControl.h"

//AppInterface serves as a go-between for the God class and the MainControl class.  Very straightforward
//and rarely needs to be changed; more useful if there are multiple MainControl types of classes.
#include "AppInterface.h"

//The God class glues the operating system, the graphics device, the application interface,
//and the window manager together.  It is essentially the first and the last code that is executed.
#include "God.h"

//#pragma comment( lib, "opengl32.lib" )                            // Search For OpenGL32.lib While Linking

/****************************/
/*        Libraries         */
/****************************/
/*
This is a list of every library included in this project and what category/API they fall under.
All of this applies only to Visual Studio .NET.

**** OpenGL Libraries               ****
opengl32.lib (comes with VC++)

**** OpenGL Textures                **** (for loading bitmap data from files)
glaux.lib   (I host this online.  Can probably be found other places as well.)

**** DirectX Textures               ****
d3d9.lib    
d3dx9dt.lib (both come with the DirectX SDK)

**** Timer Libraries                ****
winmm.lib   (comes with VC++)

**** Video Texture Libraries        ****
dshow.lib   (comes with an older version of the DirectX SDK.  I host this online as well.)

**** Screen AVI Capture Libraries   ****
vfw32.lib   (Video For Windows, comes with VC++)

The following is a list of libraries that you need depending on what type of files you want to load.
In VC++ .NET, you set these under File -> Properties -> Linker -> Input -> Additional Dependencies...

Everything:
opengl32.lib glaux.lib d3d9.lib d3dx9dt.lib winmm.lib vfw32.lib dshow.lib

DirectX only:
d3d9.lib d3dx9dt.lib winmm.lib vfw32.lib

DirectX with Video Textures:
d3d9.lib d3dx9dt.lib winmm.lib vfw32.lib dshow.lib

OpenGL only:
opengl32.lib glaux.lib winmm.lib vfw32.lib

OpenGL only without textures:
opengl32.lib winmm.lib vfw32.lib

For Visual Studio 6.0, everything is the same except you'll need gdi32.lib in every build,
and d3dx9dt.lib should be switched to d3dx9.lib, and dshow.lib (and thus Video Textures)
will not run.  So the library line in project->settings->Link Object/library modules is
opengl32.lib glaux.lib d3dx9.lib d3d9.lib winmm.lib gdi32.lib vfw32.lib 
for everything except video textures.
*/

Top