E:/Eigene Dateien/Michi/Studium/Semester7/Vis/LU/Beispiel2/FlowVis/header/common.h File Reference

#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 Documentation

#define BOUNDARY   0.9125f

#define PI   3.14159265f


Function Documentation

template<class Type >
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

Returns:
true if successfull, false otherwise

template<class Type >
const Type fromString ( const std::string strString  )  [inline]

Converts from string to Type strString string which should be converted

Returns:
Variable as a Type

const int getNextPowerOfTwo ( const int  iNumber  ) 

Returns the next power of two of a number

Parameters:
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

Parameters:
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

Parameters:
fn Filename

int textFileWrite ( char *  fn,
char *  s 
)

writes in a text file. Returns 1 if successful, 0 if not.

Writes an ASCII File

Parameters:
fn Filename
s content of the file

template<class Type >
const std::string toString ( const Type &  tValue  )  [inline]

Converts from Type to string tValue Value which should be converted to a string

Returns:
String representation of the given value

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


Generated on Tue Jan 20 23:44:09 2009 for FlowVis by  doxygen 1.5.7.1