R:/projects/actioncube/_svn/trunk/ac/source/src/tools.cpp File Reference

#include "pch.h"
#include "cube.h"
#include <unistd.h>
#include <sys/stat.h>
#include <sys/types.h>
#include <dirent.h>

Include dependency graph for tools.cpp:


Functions

char * path (char *s)
char * path (const char *s, bool copy)
const char * behindpath (const char *s)
const char * parentdir (const char *directory)
bool fileexists (const char *path, const char *mode)
bool createdir (const char *path)
static void fixdir (char *dir)
void sethomedir (const char *dir)
void addpackagedir (const char *dir)
const char * findfile (const char *filename, const char *mode)
int getfilesize (const char *filename)
FILE * openfile (const char *filename, const char *mode)
gzFile opengzfile (const char *filename, const char *mode)
char * loadfile (const char *fn, int *size, const char *mode)
bool listdir (const char *dir, const char *ext, vector< char * > &files)
int listfiles (const char *dir, const char *ext, vector< char * > &files)
bool delfile (const char *path)
bool cmpb (void *b, int n, enet_uint32 c)
bool cmpf (char *fn, enet_uint32 c)
void endianswap (void *memory, int stride, int length)
bool isbigendian ()
static float det2x2 (float a, float b, float c, float d)
static float det3x3 (float a1, float a2, float a3, float b1, float b2, float b3, float c1, float c2, float c3)

Variables

string homedir = ""
vector< char * > packagedirs

Function Documentation

void addpackagedir ( const char *  dir  ) 

const char* behindpath ( const char *  s  ) 

bool cmpb ( void *  b,
int  n,
enet_uint32  c 
)

bool cmpf ( char *  fn,
enet_uint32  c 
)

bool createdir ( const char *  path  ) 

bool delfile ( const char *  path  ) 

static float det2x2 ( float  a,
float  b,
float  c,
float  d 
) [inline, static]

static float det3x3 ( float  a1,
float  a2,
float  a3,
float  b1,
float  b2,
float  b3,
float  c1,
float  c2,
float  c3 
) [inline, static]

void endianswap ( void *  memory,
int  stride,
int  length 
)

bool fileexists ( const char *  path,
const char *  mode 
)

const char* findfile ( const char *  filename,
const char *  mode 
)

static void fixdir ( char *  dir  )  [static]

int getfilesize ( const char *  filename  ) 

bool isbigendian (  ) 

bool listdir ( const char *  dir,
const char *  ext,
vector< char * > &  files 
)

int listfiles ( const char *  dir,
const char *  ext,
vector< char * > &  files 
)

char* loadfile ( const char *  fn,
int *  size,
const char *  mode 
)

FILE* openfile ( const char *  filename,
const char *  mode 
)

gzFile opengzfile ( const char *  filename,
const char *  mode 
)

const char* parentdir ( const char *  directory  ) 

char* path ( const char *  s,
bool  copy 
)

char* path ( char *  s  ) 

void sethomedir ( const char *  dir  ) 


Variable Documentation


Generated on Mon Dec 8 21:41:33 2008 for AssaultCube by  doxygen 1.5.7.1