Namespaces | Functions
Utils.h File Reference
#include <cstring>
#include <sys/time.h>
Include dependency graph for Utils.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

namespace  motld

Functions

int motld::getTime ()
 returns time value in milliseconds
float motld::randFloat (float min, float max)
 returns random float x with min <= x <= max
int motld::randInt (int min, int max)
 returns random integer n with min <= n <= max
template<class T >
Tmotld::readFromPGM (const char *filename, int &xSize, int &ySize)
 reads from PGM file into array of something
template<class T >
Tmotld::readFromPPM (const char *aFilename, int &xSize, int &ySize, int &zSize)
 reads from PPM file into array of something
template<class T >
Tmotld::toGray (T *rgb, int size)
 reduces array with 3 sequential color channels to 1 channel array
template<class T >
void motld::writeToPGM (const char *filename, T *data, int xSize, int ySize)
 writes from array of something into PGM file
template<class T >
void motld::writeToPPM (const char *aFilename, T *data, int xSize, int ySize)
 writes from array of something into PPM file
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Defines


motld
Author(s): Jost Tobias Springenberg, Jan Wuelfing
autogenerated on Wed Dec 26 2012 16:24:49