BambooIsland: C:/Users/easterbunny/Desktop/Echtzeitgraphik-LU/trunk/src/definitions.h Source File

BambooIsland Abgabe 2

- Main Page
- Related Pages
- Classes
- Files

- File List

# C:/Users/easterbunny/Desktop/Echtzeitgraphik-LU/trunk/src/definitions.h

    00001 #ifndef N_DEPRECATED_DEFINITIONS
    00002 #define N_DEPRECATED_DEFINITIONS
    00003
    00004 // Allgemeine Makros und Definitionen
    00005
    00006 #define SAFEDEL(x)              {if((x) != NULL) {delete (x); (x) = NULL;}} // Sicheres Löschen
    00007 #define SAFEDELARR(x)   {if((x) != NULL) {delete[] (x); (x) = NULL;}} // Sicheres Löschen eines Arrays
    00008 #define SAFEREL(x)              {if((x) != NULL) {(x)->Release(); (x) = NULL;}} // Sicheres Releasen eines COM-Objekts
    00009 #define SAFEMEMFREE(x)          {if((x) != NULL) {tbMemFree((x)); (x) = NULL;}} // Sicheres Freigeben von Speicher
    00010
    00011 #define MIN(a, b)                       ((a) < (b) ? (a) : (b))                                                 // Minimum
    00012 #define MAX(a, b)                       ((a) > (b) ? (a) : (b))                                                 // Maximum
    00013 #define PI                                      (3.1415926535897932384626433832795f)                    // Pi
    00014 #define DEG_TO_RAD(x)           ((x) * 0.0174532925199432957692369076848f)              //Grad -> Bogenmaß
    00015 #define RAD_TO_DEG(x)           ((x) * 57.295779513082320876798154814105f)              //Bogenmaß -> Grad
    00016
    00018 inline int signum(int number)    { return (number > 0) - (number < 0); }
    00019 inline int signum(long number)   { return (number > 0) - (number < 0); }
    00020 inline int signum(float number)  { return (number > 0) - (number < 0); }
    00021 inline int signum(double number) { return (number > 0) - (number < 0); }
    00022
    00024 inline int heavyside(int number)        { return (number >= 0); }
    00025 inline int heavyside(long number)       { return (number >= 0); }
    00026 inline int heavyside(float number)      { return (number >= 0); }
    00027 inline int heavyside(double number) { return (number >= 0); }
    00028
    00029 #endif

All Classes Functions Variables Enumerations Enumerator