
Defines.h
By: a guest on
Jan 21st, 2011 | syntax:
C++ | size: 0.89 KB | views:
50 | expires: Never
//global defines
#ifndef DEFINES_CNST
#define DEFINES_CNST
#define build 0.02
#define w_width 800
#define w_height 800
#define pi 3.14159265358979323
//Standard includes
#ifdef __cplusplus
#include <cstdlib>
#else
#include <stdlib.h>
#endif
#include <stdio.h>
#include <string>
#include <vector>
#include <math.h>
#include <iostream>
#include <sstream>
//OpenGL stuff
#ifdef __APPLE__
#include <SDL/SDL.h>
#else
#include <SDL.h>
#endif
//#include <GL/glee.h>
#include <SDL_opengl.h>
#include <GL/gl.h>
#include <GL/glu.h>
#include <GL/glext.h>
//global functions (useful?)
#define RADTODEG(x) (x * 180 / pi)
#define DEGTORAD(x) (x * pi / 180)
#define DFABS(x) ((x)<(0)?(x*-1):(x))//gets the absoloute value of any number
#define RANDOM_NUM(max,min) ((min)+(rand()%((max)-(min))))
#endif