#include "basetype.h"Go to the source code of this file.
|
|
Definition at line 28 of file Errorlog.h. |
|
|
Definition at line 203 of file Errorlog.h. |
|
|
Definition at line 206 of file Errorlog.h. |
|
|
Definition at line 211 of file Errorlog.h. |
|
|
Definition at line 165 of file Errorlog.h. Referenced by GenVS_Error().
00166 {
00167 GE_ERR_MEMORY_RESOURCE,
00168 GE_ERR_DISPLAY_RESOURCE,
00169 GE_ERR_SOUND_RESOURCE,
00170 GE_ERR_SYSTEM_RESOURCE,
00171 GE_ERR_INTERNAL_RESOURCE,
00172
00173 GE_ERR_FILEIO_OPEN,
00174 GE_ERR_FILEIO_CLOSE,
00175 GE_ERR_FILEIO_READ,
00176 GE_ERR_FILEIO_WRITE,
00177 GE_ERR_FILEIO_FORMAT,
00178 GE_ERR_FILEIO_VERSION,
00179
00180 GE_ERR_LIST_FULL,
00181 GE_ERR_DATA_FORMAT,
00182 GE_ERR_SEARCH_FAILURE,
00183 } geErrorLog_ErrorClassType;
|
|
|
Definition at line 36 of file Errorlog.h.
00037 {
00038 GE_ERR_INVALID_DRIVER_HANDLE, // Driver not supported
00039 GE_ERR_INVALID_MODE_HANDLE, // Mode not supported
00040 GE_ERR_DRIVER_INIT_FAILED, // Could not init Driver
00041 GE_ERR_DRIVER_ALLREADY_INITIALIZED, // Driver init failure
00042 GE_ERR_DRIVER_NOT_FOUND, // File open error for driver
00043 GE_ERR_DRIVER_NOT_INITIALIZED, // Driver shutdown failure
00044 GE_ERR_INVALID_DRIVER, // Wrong driver version, or bad driver
00045 GE_ERR_DRIVER_BEGIN_SCENE_FAILED,
00046 GE_ERR_DRIVER_END_SCENE_FAILED,
00047 GE_ERR_CREATE_SOUND_MANAGER_FAILED,
00048 GE_ERR_CREATE_SOUND_BUFFER_FAILED,
00049 GE_ERR_DS_ERROR,
00050 GE_ERR_INVALID_WAV,
00051 GE_ERR_NO_PERF_FREQ,
00052 GE_ERR_FILE_OPEN_ERROR,
00053 GE_ERR_FILE_READ_ERROR,
00054 GE_ERR_FILE_WRITE_ERROR,
00055 GE_ERR_PALETTE_LOAD_FAILURE,
00056 GE_ERR_GBSP_LOAD_FAILURE,
00057 GE_ERR_INVALID_PARMS,
00058 GE_ERR_INVALID_CAMERA,
00059 GE_ERR_RENDER_WORLD_FAILED,
00060 GE_ERR_BEGIN_WORLD_FAILED,
00061 GE_ERR_END_WORLD_FAILED,
00062 GE_ERR_BEGIN_MODELS_FAILED,
00063 GE_ERR_END_MODELS_FAILED,
00064 GE_ERR_BEGIN_MESHES_FAILED,
00065 GE_ERR_END_MESHES_FAILED,
00066 GE_ERR_RENDER_MESH_FAILED,
00067 GE_ERR_BAD_LMAP_EXTENTS,
00068 GE_ERR_INVALID_TEXTURE,
00069 GE_ERR_REGISTER_WORLD_TEXTURE_FAILED,
00070 GE_ERR_REGISTER_LIGHTMAPS_FAILED,
00071 GE_ERR_REGISTER_WORLD_PALETTE_FAILED,
00072 GE_ERR_REGISTER_MISC_TEXTURE_FAILED,
00073 GE_ERR_INVALID_MESH_FILE,
00074 GE_ERR_LOAD_BITMAP_FAILED,
00075 GE_ERR_MAX_MESH_DEFS,
00076 GE_ERR_MESH_MAX_NODES,
00077 GE_ERR_INVALID_MESH_MATERIAL,
00078 GE_ERR_MAX_MESH_MATERIALS,
00079 GE_ERR_MAX_MESH_CLIP_PLANES,
00080 GE_ERR_RENDERQ_OVERFLOW,
00081 GE_ERR_INVALID_LTYPE,
00082 GE_ERR_MAX_ENTITIES,
00083 GE_ERR_GET_ENTITY_DATA_ERROR,
00084 GE_ERR_INVALID_ENTITY_FIELD_TYPE,
00085 GE_ERR_MODEL_NOT_FOUND,
00086 GE_ERR_MODEL_NOT_IN_ENTITY,
00087 GE_ERR_MAX_TEXTURES,
00088 GE_ERR_MAX_DECALS,
00089 GE_ERR_MAX_VERTS,
00090 GE_ERR_OUT_OF_MEMORY,
00091 GE_ERR_INVALID_BSP_TAG,
00092 GE_ERR_INVALID_BSP_VERSION,
00093 GE_ERR_ERROR_READING_BSP_CHUNK,
00094 ERR_PATH_CREATE_ENOMEM, // failure to create a path (memory allocation failed)
00095 ERR_PATH_INSERT_R_KEYFRAME, // failure to insert a rotation keyframe
00096 ERR_PATH_INSERT_T_KEYFRAME, // failure to insert a translation keyframe
00097 ERR_PATH_DELETE_R_KEYFRAME, // failure to delete a rotation keyframe
00098 ERR_PATH_DELETE_T_KEYFRAME, // failure to delete a translation keyframe
00099 ERR_PATH_FILE_READ, // failure to read from file
00100 ERR_PATH_FILE_VERSION, // tried to create path from file with wrong/bad version
00101 ERR_PATH_FILE_PARSE, // failure to parse file (unexpected format problem)
00102 ERR_PATH_FILE_WRITE, // failure to read from file
00103 ERR_MOTION_CREATE_ENOMEM, // failure to create (memory allocation failed)
00104 ERR_MOTION_ADDPATH_ENOMEM, // failure to add path into motion (memory allocation failed)
00105 ERR_MOTION_ADDPATH_PATH, // failure to add path into motion (path creation failed)
00106 ERR_MOTION_ADDPATH_BAD_NAME, // failure to add path into motion due to name conflict
00107 ERR_MOTION_INSERT_EVENT, // failure to insert event (memory allocation failed or duplicate key)
00108 ERR_MOTION_DELETE_EVENT, // failure to insert event
00109 ERR_MOTION_FILE_READ, // failure to read from file
00110 ERR_MOTION_FILE_WRITE, // failure to write to file
00111 ERR_MOTION_FILE_PARSE, // failure to parse file (unexpected format problem)
00112 ERR_TKARRAY_INSERT_IDENTICAL, // failure to insert into list because of existing identical key
00113 ERR_TKARRAY_INSERT_ENOMEM, // failure to insert into list because of memory allocation failure
00114 ERR_TKARRAY_DELETE_NOT_FOUND, // failure to delete from list because key was not found
00115 ERR_TKARRAY_CREATE, // failure to create TKArray object (out of memroy)
00116 ERR_TKARRAY_TOO_BIG, // TKArray object can't be added to - it's list is as big as it can get
00117 ERR_VKARRAY_INSERT, // insertion to VKArray failed
00118 ERR_QKARRAY_INSERT, // insertion to QKArray failed
00119 ERR_POSE_CREATE_ENOMEM, // Motion object failed to create (memory allocation failed)
00120 ERR_POSE_ADDJOINT_ENOMEM, // Motion_AddJoint failed to allocate/reallocate memory for new joint
00121 ERR_TKEVENTS_CREATE_ENOMEM, // failure to create TKEvents object (memory allocation failed)
00122 ERR_TKEVENTS_DELETE_NOT_FOUND, // failure to delete from list because key was not found
00123 ERR_TKEVENTS_INSERT_ENOMEM, // failure to insert into list because of memory allocation failure
00124 ERR_TKEVENTS_INSERT, // failure to insert into list
00125 ERR_TKEVENTS_FILE_READ, // failure to read from data file
00126 ERR_TKEVENTS_FILE_WRITE, // failure to write to data file
00127 ERR_TKEVENTS_FILE_VERSION, // failure to read tkevents object: file has wrong version
00128 ERR_TKEVENTS_FILE_PARSE, // failure to parse file (unexpected format problem)
00129 ERR_STRBLOCK_ENOMEM, // failure to create, insert, or append (memory allocation failed)
00130 ERR_STRBLOCK_STRLEN, // string too long to insert or append
00131 ERR_STRBLOCK_FILE_READ, // failure to read from data file
00132 ERR_STRBLOCK_FILE_WRITE, // failure to write to data file
00133 ERR_STRBLOCK_FILE_PARSE, // failure to parse reading from input file (unexpected format problem)
00134 ERR_BODY_ENOMEM, // failure to create, or add (memory allocation failed)
00135 ERR_BODY_FILE_PARSE, // failure to parse reading from input file (unexpected format problem)
00136 ERR_BODY_FILE_READ, // failure to read from data file
00137 ERR_BODY_FILE_WRITE, // failure to write to data file
00138 ERR_BODY_BONEXFARRAY, // XFArray object failed to return array, or array size doesn't match bone count
00139 ERR_XFARRAY_ENOMEM, // failure to create. (memory allocation failure)
00140 ERR_PUPPET_ENOMEM, // failure to create. (memory allocation failure)
00141 ERR_PUPPET_RENDER, // failure to render.
00142 ERR_PUPPET_NO_MATERIALS, // failure to create: associated body has no materials.
00143 ERR_PUPPET_LOAD_TEXTURE, // failure to load texture
00144 ERR_TEXPOOL_ENOMEM, // failure to create or add to. (memory allocation/reallocation failure)
00145 ERR_TEXPOOL_TOO_BIG, // failure to add to pool, pool is too large.
00146 ERR_TEXPOOL_LOAD_TEXTURE, // failure to load texture into pool
00147 ERR_TEXPOOL_TEXTURE_NOT_FREE, // texture pool destroyed without first freeing all it's shared textures
00148 ERR_ACTOR_ENOMEM, // failure to create. (memory allocation failure)
00149 ERR_ACTOR_RENDER_PREP, // failure to prepare actor for rendering (bad Body or allocation failure)
00150 ERR_ACTOR_RENDER_FAILED, // failure to render. failure to get geometry from Body
00151 ERR_ACTOR_TOO_MANY_MOTIONS, // failure to add motion. too many.
00152 ERR_ACTOR_FILE_READ, // failure to read from data file.
00153 ERR_ACTOR_FILE_PARSE, // failure to parse reading from input file(unexpected format problem)
00154 ERR_ACTOR_FILE_WRITE, // failure to write to data file.
00155 GE_ERR_INVALID_MODEL_MOTION_FILE, // Bad model motion file (for bsp files)
00156 GE_ERR_BAD_BSP_FILE_CHUNK_SIZE, // Chunk size does not match structure size of kind
00157 //MRB BEGIN
00158 //geSprite
00159 ERR_SPRITE_ENOMEM, // failure to create. (memory allocation failure)
00160 ERR_SPRITE_INVALIDBITMAP, // failure to use bitmap because bitmap was invalid
00161 //MRB END
00162 } geErrorLog_ErrorIDEnumType;
|
|
||||||||||||||||||||||||||||
|
Definition at line 65 of file ERRORLOG.C. References Error, geErrorLogType::ErrorCount, geErrorLogType::ErrorList, geErrorLog_Locals, GENESISAPI, MAX_CONTEXT_LEN, MAX_ERRORS, MAX_USER_NAME_LEN, geErrorLogType::MaxErrors, and NULL.
00071 {
00072 char *SDst;
00073 char *CDst;
00074
00075 assert( geErrorLog_Locals.ErrorCount >= 0 );
00076
00077 if (geErrorLog_Locals.ErrorCount>=MAX_ERRORS)
00078 { // scoot list down by one (lose oldest error)
00079 memmove(
00080 (char *)(&( geErrorLog_Locals.ErrorList[0] )),
00081 (char *)(&( geErrorLog_Locals.ErrorList[1] )),
00082 sizeof(geErrorType) * (geErrorLog_Locals.MaxErrors-1) );
00083 geErrorLog_Locals.ErrorCount = geErrorLog_Locals.MaxErrors-1;
00084 }
00085
00086 assert( geErrorLog_Locals.ErrorCount < geErrorLog_Locals.MaxErrors );
00087
00088 SDst = geErrorLog_Locals.ErrorList[geErrorLog_Locals.ErrorCount].String;
00089
00090 // Copy new error info
00091 if (ErrorIDString != NULL)
00092 {
00093 strncpy(SDst,ErrorIDString,MAX_USER_NAME_LEN);
00094 }
00095
00096 strncat(SDst," ",MAX_USER_NAME_LEN);
00097
00098 if (ErrorFileString!=NULL)
00099 {
00100 const char* pModule = strrchr(ErrorFileString, '\\');
00101 if(!pModule)
00102 pModule = ErrorFileString;
00103 else
00104 pModule++; // skip that backslash
00105 strncat(SDst,pModule,MAX_USER_NAME_LEN);
00106 strncat(SDst," ",MAX_USER_NAME_LEN);
00107 }
00108
00109 {
00110 char Number[20];
00111 itoa(LineNumber,Number,10);
00112 strncat(SDst,Number,MAX_USER_NAME_LEN);
00113 }
00114
00115 if (UserString != NULL)
00116 {
00117 if (UserString[0]!=0)
00118 {
00119 strncat(SDst," ",MAX_USER_NAME_LEN);
00120 strncat(SDst,UserString,MAX_USER_NAME_LEN);
00121 }
00122 }
00123
00124 CDst = geErrorLog_Locals.ErrorList[geErrorLog_Locals.ErrorCount].Context;
00125
00126 // Clear the context string in the errorlog to prepare for a new one
00127 memset(CDst, 0, sizeof(char)*MAX_CONTEXT_LEN);
00128
00129 if (Context != NULL)
00130 {
00131 if (Context[0]!=0)
00132 {
00133 //strncat(SDst," ",MAX_USER_NAME_LEN);
00134 strncat(SDst,Context,MAX_USER_NAME_LEN);
00135 }
00136 }
00137
00138 geErrorLog_Locals.ErrorCount++;
00139
00140 #ifndef NDEBUG
00141 #pragma message ("Clean up the OutputDebugStrings in geErrorLog_AddExplicit")
00142 {
00143 char buff[100];
00144 sprintf(buff, "ErrorLog: %d -", Error);
00145 OutputDebugString(buff);
00146 OutputDebugString(SDst);
00147 OutputDebugString("\r\n");
00148 }
00149 #endif
00150 }
|
|
|
Definition at line 154 of file ERRORLOG.C. References geErrorLogType::ErrorCount, geErrorLogType::ErrorList, GE_FALSE, GE_TRUE, geBoolean, geErrorLog_Locals, GENESISAPI, MAX_USER_NAME_LEN, and NULL.
00155 {
00156 char *SDst;
00157 if (String == NULL)
00158 {
00159 return GE_FALSE;
00160 }
00161
00162 if (geErrorLog_Locals.ErrorCount>0)
00163 {
00164 SDst = geErrorLog_Locals.ErrorList[geErrorLog_Locals.ErrorCount-1].String;
00165
00166 strncat(SDst,String,MAX_USER_NAME_LEN);
00167 return GE_TRUE;
00168 }
00169 else
00170 {
00171 return GE_FALSE;
00172 }
00173 }
|
|
|
Definition at line 52 of file ERRORLOG.C. References geErrorLogType::ErrorCount, geErrorLog_Locals, and GENESISAPI.
00054 {
00055 geErrorLog_Locals.ErrorCount = 0;
00056 }
|
|
|
Definition at line 58 of file ERRORLOG.C. References geErrorLogType::ErrorCount, geErrorLog_Locals, and GENESISAPI. Referenced by GenVS_Error().
00060 {
00061 return geErrorLog_Locals.ErrorCount;
00062 }
|
|
||||||||||||||||
|
Definition at line 175 of file ERRORLOG.C. References geErrorLogType::ErrorCount, geErrorType::ErrorID, geErrorLogType::ErrorList, GE_FALSE, GE_TRUE, geBoolean, geErrorLog_Locals, GENESISAPI, NULL, and geErrorType::String. Referenced by GenVS_Error().
00176 {
00177 assert( error != NULL );
00178
00179 if ( (history > geErrorLog_Locals.ErrorCount) || (history < 0))
00180 {
00181 return GE_FALSE;
00182 }
00183
00184
00185 *error = geErrorLog_Locals.ErrorList[history].ErrorID;
00186 *UserString = geErrorLog_Locals.ErrorList[history].String;
00187 return GE_TRUE;
00188 }
|
1.3.2