reman3/Rayman_X/cpa/public/GAM/LSerm.h

124 lines
3.9 KiB
C

#ifndef __LSYERM_H__
#define __LSYERM_H__
#ifdef D_USE_LIPSYNC
/*#include "CPA_Expt.h"*/
#ifdef __cplusplus
extern "C" {
#endif
#pragma warning( disable : 4201 4214 4115 )
#define C_szLipsSynchVersion "LSY V1.0.0" /* The format is XXX Va.b.c with Xxx is the Tag of the module */
#define C_szLipsSynchFullName "LipsSynchs module"/* the complete and clear name of the module */
#define C_szLipsSynchDate __DATE__ /*The format is "Mmm dd yyyy".You can use __DATE__ but be careful that you have the control of the compilation*/
#include "ERM.h"
#undef EXTERN
#if !defined(LSY_MainFile)
#define EXTERN extern
#else /* !LSY_MainFile */
#define EXTERN
#endif /* !LSY_MainFile */
#define __FATAL_ERR_LipsSynch__
#define __WARNING1_ERR_LipsSynch__
/* error of the LipsSynch Module*/
enum e_uwLipsSynchErrNumber{
E_uwLipsSynchFatalErr,
#ifdef __FATAL_ERR_LipsSynch__
/* Fatals error :*/
E_uwLipsSynchFatalNotAFatalError,
E_uwLipsSynchWarningErrorIsNotAWarningError,
E_uwLipsSynchMemoryPlace,
#endif /*__FATAL_ERR_LipsSynch__*/
E_uwLipsSynchStartOfWarning,/* important constant, it allows to recognize if an error is fatal or not.*/
#ifdef __WARNING1_ERR_LipsSynch__
E_uwLipsSynchWarningShouldNotHappen,/* should never happen, but....*/
#endif /*__WARNING1_ERR_LipsSynch__*/
E_uwLipsSynchErrNumber
};
EXTERN unsigned char g_ucLipsSynchModuleId /*number of identification of the Erm module*/
#ifdef LSY_MainFile
= C_ucModuleNotInitialized
#endif /*LSY_MainFile*/
;
#ifndef _FIRE_DEADCODE_U64_ /* Added by RUC */
EXTERN CPA_EXPORT char * g_a_szLipsSynchInformationModule []
#if defined(LSY_MainFile) && !defined(CPA_WANTS_IMPORT)
= {C_szLipsSynchVersion, C_szLipsSynchFullName, C_szLipsSynchDate}
#endif /*LSY_MainFile && CPA_WANTS_IMPORT*/
;
#endif /* _FIRE_DEADCODE_U64_ */ /* Added by RUC */
#ifndef _FIRE_DEADCODE_U64_ /* Added by RUC */
EXTERN char * g_szLipsSynchModuleName /* Obliged syntax 'g_sz'+[Abbreviation of ModuleName]+'ModuleName'*/
#ifdef LSY_MainFile
= "Module LipsSynch"
#endif /*LSY_MainFile*/
;
#endif /* _FIRE_DEADCODE_U64_ */ /* Added by RUC */
#if defined(__ERROR_STRINGS__)
EXTERN tdstErrorMsg g_a_stLipsSynchTabErr [] /* Obliged syntax 'g_a_st'+[Abbreviation of ModuleName]+'TabErr'*/
#ifdef LSY_MainFile
={
#ifdef __FATAL_ERR_LipsSynch__
E_uwLipsSynchFatalNotAFatalError, "This is not a valide LSY Debug fatal error",
E_uwLipsSynchWarningErrorIsNotAWarningError,"M_LipsSynchWarningError : Try to raise a fatal or a information",
E_uwLipsSynchMemoryPlace,"Not enough memory.",
#endif /*__FATAL_ERR_LipsSynch__*/
E_uwLipsSynchStartOfWarning,"This is a strange LSY Debug Warning",
#ifdef __WARNING1_ERR_LipsSynch__
E_uwLipsSynchWarningShouldNotHappen,"This error should never happen!!!!",
#endif /*__WARNING1_ERR_LipsSynch__*/
0xFFFF, "\0"/*fin*/
}
#endif /*LSY_MainFile*/
;
#endif /*__ERROR_STRINGS__*/
#define M_LipsSynchFatalError(ErrorNum) \
{ \
if (ErrorNum>E_uwLipsSynchFatalErr&&ErrorNum<E_uwLipsSynchStartOfWarning) \
{ \
Erm_M_ClearLastError(C_ucErmDefaultChannel);\
Erm_M_UpdateLastError(LipsSynch,C_ucErmDefaultChannel,(unsigned short)ErrorNum,C_lErmNoDebugData,C_ucErmOpenInfoWindow,C_ucAllowStopForDebug, NULL);\
} \
else \
{ \
Erm_M_ClearLastError((unsigned short)C_ucErmDefaultChannel);\
Erm_M_UpdateLastError(LipsSynch,C_ucErmDefaultChannel,(unsigned short)E_uwLipsSynchFatalNotAFatalError,C_lErmNoDebugData,C_ucErmOpenInfoWindow,C_ucAllowStopForDebug, NULL);\
} \
}
#define M_LipsSynchWarningError(ErrorNum) \
{ \
if (ErrorNum>E_uwLipsSynchStartOfWarning&&ErrorNum<E_uwLipsSynchErrNumber) \
{ \
Erm_M_UpdateLastError(LipsSynch,C_ucErmDefaultChannel,(unsigned short)ErrorNum,C_lErmNoDebugData,C_ucErmOpenInfoWindow,C_ucAllowStopForDebug, NULL);\
} \
else \
{ \
M_LipsSynchFatalError(E_uwLipsSynchWarningErrorIsNotAWarningError); \
} \
}
#ifdef __cplusplus
}/* extern "C" */
#endif
#endif /* D_USE_LIPSYNC*/
#endif /* __LSYITEM_H__*/