geAssert

Description: Replacement for assert interface

Source file: …\genesis3d\OpenSource\Source\Support\geAssert

Contents:

Functions: geAssertSetCallback, SetCriticalShutdownCallback

Overview: view

Types: geAssertCallbackFn, geAssert_CriticalShutdownCallback

Macros: view

Additions for Genesis3D v1.6: None

 

Overview:

You should use geAssert() anywhere in the Genesis engine that you would normally use assert(). If you wish to be called back when asserts happen, use the routine geAssertSetCallback(). It returns the address of the callback routine that you're replacing.

Return to Contents

 

Macros:

  #ifdef NDEBUG
      #define geAssert(exp)
 #else
      extern void geAssertEntryPoint(void * , void * , unsigned );
      #define geAssert(exp) (void)( (exp) || (geAssertEntryPoint(#exp, __FILE__, __LINE__), 0) )
 #endif
Return to Contents

 

Types:

typedef void geAssertCallbackFn(void * exp, void * file, unsigned line );

typedef void (*geAssert_CriticalShutdownCallback) (void * Context);

 

Return to Contents

Functions:

geAssertCallbackFn* geAssertSetCallback( geAssertCallbackFn* newAssertCallback );

 

Return to Contents

extern void geAssert_SetCriticalShutdownCallback( geAssert_CriticalShutdownCallback CB , void * Context);

 
Return to Contents