#include <windows.h>
#include <glew.h>
#include <glut.h>
#include <commdlg.h>
#include <stdlib.h>
#include <io.h>
#include <GL/glu.h>
#include <iostream>
#include <sstream>
#include <string>
Classes | |
class | eat |
Defines | |
#define | PI 3.14159265f |
#define | BOUNDARY 0.9125f |
Functions | |
template<class Type > | |
const Type | fromString (const std::string &strString) |
template<class Type > | |
const bool | fromString (Type &tValue, const std::string &strString) |
template<class Type > | |
const std::string | toString (const Type &tValue) |
const std::string | trimLeft (const std::string &str, const std::string &strWhitespace="\n\r\t ") |
const std::string | trimRight (const std::string &str, const std::string &strWhitespace="\n\r\t ") |
const std::string | trim (const std::string &str, const std::string &strWhitespace="\n\r\t ") |
std::istream & | operator>> (std::istream &is, eat &e) |
void | renderString (void *font, const std::string input) |
void | printGLErrors () |
char * | textFileRead (char *fn) |
reads a text file. Returns zero length array if not successful. /////////////////////////////////////////////////////////////////// | |
int | textFileWrite (char *fn, char *s) |
writes in a text file. Returns 1 if successful, 0 if not. | |
const int | getNextPowerOfTwo (const int iNumber) |
#define BOUNDARY 0.9125f |
#define PI 3.14159265f |
const bool fromString | ( | Type & | tValue, | |
const std::string & | strString | |||
) | [inline] |
converts from string to Type, returns true if successful strString strString string which should be converted
const Type fromString | ( | const std::string & | strString | ) | [inline] |
Converts from string to Type strString string which should be converted
const int getNextPowerOfTwo | ( | const int | iNumber | ) |
Returns the next power of two of a number
iNumber | Number |
std::istream& operator>> | ( | std::istream & | is, | |
eat & | e | |||
) | [inline] |
void printGLErrors | ( | ) |
Prints the OpenGL erros on the screen.
void renderString | ( | void * | font, | |
const std::string | input | |||
) |
renders a string on the screen with GLUT
font | Font which should be used | |
input | String to draw |
char* textFileRead | ( | char * | fn | ) |
reads a text file. Returns zero length array if not successful. ///////////////////////////////////////////////////////////////////
Reads an ASCII File
fn | Filename |
int textFileWrite | ( | char * | fn, | |
char * | s | |||
) |
writes in a text file. Returns 1 if successful, 0 if not.
Writes an ASCII File
fn | Filename | |
s | content of the file |
const std::string toString | ( | const Type & | tValue | ) | [inline] |
Converts from Type to string tValue Value which should be converted to a string
const std::string trim | ( | const std::string & | str, | |
const std::string & | strWhitespace = "\n\r\t " | |||
) | [inline] |
Trims whitespace form the beginning and the end of the string str String strWhitespace Whitespaces
const std::string trimLeft | ( | const std::string & | str, | |
const std::string & | strWhitespace = "\n\r\t " | |||
) | [inline] |
Trims whitespace form the beginning of the string str String strWhitespace Whitespaces
const std::string trimRight | ( | const std::string & | str, | |
const std::string & | strWhitespace = "\n\r\t " | |||
) | [inline] |
Trims whitespace form the end of the string str String strWhitespace Whitespaces