/*---------------------------------------------------------------------------*/ /* Strintel.h : data structures for intelligency engine*/ /* auteur : Olivier Didelot.*/ /* date : 08/08/1996*/ /* modifications majeures : * 12/1996 O.C.*/ /* 970115 : Vector management (Fabien Morales)*/ /* 970120 : minor changes (O.C.)*/ /* January 28,1997 Adding Way and Waypoints management*/ /* 970212 : Module & DsgVarId node types (Fabien Morales)*/ /* modify : Olivier Couvreur 18/02/97 CPA_EXPORT + new functions for editor*/ /* modify : Olivier Couvreur 05/03/97 Model can be gathered between several perso + Alloc and Free functions rewritten*/ /* modify : Olivier Couvreur 25/03/97 NbNode is not an unsigned char anymore + NoComportInit support*/ /* modify : Olivier Couvreur 25/05/97 ZDD + ZDD stuff*/ /*---------------------------------------------------------------------------*/ #if !defined(__STRINTEL_H__) #define __STRINTEL_H__ #include "GSParam.h" #ifdef USE_IPT_DX5 #include "IPT_DX5.h" /* InPuT (absolutely before GAM.h)*/ #else /* USE_IPT_WIN */ #include "IPT.h" /* InPuT (absolutely before GAM.h)*/ #endif /* USE_IPT_WIN */ #include "specif/AIOption.h" #if defined(U64) #include "AIGame/EnumAct.h" /* tables of action names*/ #include "AIGame/EnumCond.h" /* tables of conditions names*/ #include "AIGame/EnumKey.h" /* tables of keywords names*/ #include "AIGame/EnumFunc.h" /* tables of functions names*/ #include "AIGame/EnumOper.h" /* tables of operator*/ #include "AIGame/EnumProc.h" /* tables of Procedure.*/ #include "AIGame/EnumFild.h" /* tables of fields*/ #endif #if defined(REVERSE_RULES) #pragma message("*** REVERSE_RULES is defined ***"); #endif #if defined(__cplusplus) /*#pragma message("*** Compiling in C++ for debug only ***")*/ /*#pragma message("*** Remove /Tp in Settings (C/C++ Project Options) to compile in C ***")*/ #endif /**************************************/ #if !defined(CPA_EXPORT) #if defined(CPA_WANTS_IMPORT) #define CPA_EXPORT __declspec(dllimport) #elif defined(CPA_WANTS_EXPORT) #define CPA_EXPORT __declspec(dllexport) #else #define CPA_EXPORT #endif /*CPA_WANTS_IMPORT || CPA_WANTS_EXPORT*/ #endif /*CPA_EXPORT*/ /**************************************/ #undef extern #define EXTERN_AI_DLL extern /*******************************************************************************/ /*---------------------------------------------------------------------------*/ /* Macros for access to field of struct tdstTreeInterpret*/ /*---------------------------------------------------------------------------*/ #if defined(OPTIMIZE_NB_NODES) #define M_GetNbNodeInterpret(p_Tree) fn_uwGetNbNodeInterpret((p_Tree)) #define M_SetNbNodeInterpret(p_Tree, NNode) #define M_GetNodeInterpret(p_Tree) ((p_Tree)->p_stNodeInterpret) #else #define M_GetNbNodeInterpret(p_Tree) ((p_Tree)->uwNbNode) #define M_SetNbNodeInterpret(p_Tree, NNode) (M_GetNbNodeInterpret(p_Tree)=(NNode)) #define M_GetNodeInterpret(p_Tree) ((p_Tree)->p_stNodeInterpret) #endif #define M_GetNodeInterpretN(p_Tree, NNode) (&(M_GetNodeInterpret(p_Tree)[NNode])) /*---------------------------------------------------------------------------*/ /* Macros for access to field of struct tdstMacro*/ /*---------------------------------------------------------------------------*/ #define M_GetMacroInitTree(p_stMacro) ((p_stMacro)->p_stInitTree) #define M_GetMacroCurrentTree(p_stMacro) ((p_stMacro)->p_stCurrentTree) /*---------------------------------------------------------------------------*/ /* Macros for access to field of struct tdstListOfMacro*/ /*---------------------------------------------------------------------------*/ #define M_GetNameMacro(p_stMacro) ((p_stMacro)->szName) #define M_GetMacro(p_stListMacro) ((p_stListMacro)->p_stMacro) #define M_GetMacroN(p_stListMacro, N) (M_GetMacro(p_stListMacro)+N) #define M_GetNbMacro(p_stListMacro) (p_stListMacro->ucNbMacro) /*---------------------------------------------------------------------------*/ /* Macros for access to field of struct tdstComport*/ /*---------------------------------------------------------------------------*/ #define M_GetNameComport(p_stComp) ((p_stComp)->szName) #define M_GetComportSchedule(p_stComp) ((p_stComp)->p_stSchedule) #define M_GetTreeComportSchedule(p_stComp) (M_GetNodeInterpret(M_GetComportSchedule(p_stComp))) #define M_GetComportRules(p_stComp) ((p_stComp)->p_stRules) #define M_GetComportRuleN(p_stComp, NRule) (&(M_GetComportRules(p_stComp)[NRule])) #define M_GetComportNbRules(p_stComp) ((p_stComp)->ucNbRules) #define M_GetComportNRules(p_stComp, N) ((p_stComp)[N].p_stRules) /*---------------------------------------------------------------------------*/ /* Macros for access to field of struct tdstScriptAI*/ /*---------------------------------------------------------------------------*/ #define M_GetScriptAINbComport(p_stScr) ((p_stScr)->ulNbComport) #define M_GetScriptAIComport(p_stScr) ((p_stScr)->p_stComport) #define M_GetScriptAIComportN(p_stScr, N) (&(M_GetScriptAIComport(p_stScr)[N])) #define M_GetScriptAIActionTableNbEntry(p_stScr) ((p_stScr)->ucActionTableNbEntry) #define M_GetScriptAINoComportInitDefault(p_stScr) ((p_stScr)->ulNoComportInitDefault) /*---------------------------------------------------------------------------*/ /* Macros for access to field of struct tdstIntelligence*/ /*---------------------------------------------------------------------------*/ #define M_GetCurrentComport(p_stInt) ((p_stInt)->p_stCurrentComport) #define M_GetPrevComport(p_stInt) ((p_stInt)->p_stPrevComport) #define M_GetRules(p_stInt) (M_GetComportRules(M_GetCurrentComport(p_stInt))) #define M_GetRuleN(p_stInt, NRule) (&(M_GetRules(p_stInt)[(NRule)])) #define M_GetNbRules(p_stInt) (M_GetComportNbRules(M_GetCurrentComport(p_stInt))) #define M_GetScriptAI(p_stInt) (*((p_stInt)->p_p_stScriptAI)) #define M_GetNbComport(p_stInt) (M_GetScriptAINbComport(M_GetScriptAI(p_stInt))) #define M_GetComport(p_stInt) (M_GetScriptAIComport(M_GetScriptAI(p_stInt))) #define M_GetComportN(p_stInt, N) (M_GetScriptAIComportN(M_GetScriptAI(p_stInt), N)) #define M_GetCurrentSchedule(p_stInt) ((p_stInt)->p_stCurrentSchedule) #define M_GetNoComportInit(p_stInt) ((p_stInt)->ulNoComportInit) /*---------------------------------------------------------------------------*/ /* Macros for access to field of struct tdstNodeInterpret*/ /*---------------------------------------------------------------------------*/ #define M_DepthInterpret(p_Tree) ((p_Tree)->ucDepth) #if defined(__DEBUG_AI__) #define M_GetTypeInterpret(p_Tree) ((p_Tree)->eType) #define M_SetTypeInterpret(p_Tree,n) ((p_Tree)->eType)=(enum tdeTypeInterpret_) (n) #else #define M_GetTypeInterpret(p_Tree) (enum tdeTypeInterpret_) ((p_Tree)->eType) #define M_SetTypeInterpret(p_Tree,n) ((p_Tree)->eType)=(unsigned char) (n) #endif /* __DEBUG_AI__*/ #if defined(OPTIMIZE_SWAP_PARAMETER) #define M_NodeToSkip(p_Tree) ((p_Tree)->uwNodeToSkip) #endif /* OPTIMIZE_SWAP_PARAMETER*/ #if defined(U64) #define M_TypeUnionInterpret(p_Tree) (&((p_Tree)->uDummy.uId)) #else #define M_TypeUnionInterpret(p_Tree) (&((p_Tree)->uId)) #endif /* U64*/ #if defined(ACTIVE_AIDEBUG) /**** DR ****/ #define M_GetBreakPoint(p_Tree) ((p_Tree)->bBreakPoint) #define M_SetBreakPoint(p_Tree,n) ((p_Tree)->bBreakPoint = (ACP_tdxBool)(n)) #endif /*ACTIVE_AIDEBUG*/ #define M_eCondIdInterpret(p_Tree) (M_TypeUnionInterpret(p_Tree)->eCondId) #define M_eKeyWordIdInterpret(p_Tree) (M_TypeUnionInterpret(p_Tree)->eKeyWordId) #define M_eOperatorIdInterpret(p_Tree) (M_TypeUnionInterpret(p_Tree)->eOperatorId) #define M_eFuncIdInterpret(p_Tree) (M_TypeUnionInterpret(p_Tree)->eFuncId) #define M_eFieldIdInterpret(p_Tree) (M_TypeUnionInterpret(p_Tree)->eFieldId) #define M_eMetaActionIdInterpret(p_Tree) (M_TypeUnionInterpret(p_Tree)->eMetaActionId) #define M_hInputHandleIdInterpret(p_Tree) (M_TypeUnionInterpret(p_Tree)->hInputAction) #define M_eProcedureIdInterpret(p_Tree) (M_TypeUnionInterpret(p_Tree)->eProcedureId) #define M_szStringInterpret(p_Tree) (M_GetSetParam_szString(p_Tree)) #define M_lValueInterpret(p_Tree) (M_GetSetParam_lValue(p_Tree)) #define M_xValueInterpret(p_Tree) (M_GetSetParam_xValue(p_Tree)) #define M_lPersoIdInterpret(p_Tree) (M_GetSetParam_lPersoId(p_Tree)) #define M_lKeyLinkInterpret(p_Tree) (M_GetSetParam_lValue(p_Tree)) #define M_p_stPersoRefInterpret(p_Tree) (M_GetSetParam_p_stEngineObjValue(p_Tree)) #define M_ucVarIdInterpret(p_Tree) (M_GetSetParam_lValue(p_Tree)) #define M_lZdxIdInterpret(p_Tree) (M_GetSetParam_lZdxId(p_Tree)) #define M_p_stVectorInterpret(p_Tree) (M_GetSetParam_p_stVectorValue(p_Tree)) #define M_lWayPointInterpret(p_Tree) (M_GetSetParam_WayPointValue(p_Tree)) #define M_lModuleInterpret(p_Tree) (M_GetSetParam_lModuleValue(p_Tree)) #define M_lDsgVarIdInterpret(p_Tree) (M_GetSetParam_lDsgVarIdValue(p_Tree)) #define M_ActionInterpret(p_Tree) (M_GetSetParam_ActionValue(p_Tree)) #define M_xMaskInterpret(p_Tree) (M_GetSetParam_xMaskValue(p_Tree)) #define M_hLipSynchroHandleIdInterpret(p_Tree) (M_GetSetParam_hLipsSynchro(p_Tree)) #define M_hFamilyHandleIdInterpret(p_Tree) (M_GetSetParam_hFamily(p_Tree)) #define M_SuperObjectInterpret(p_Tree) (M_GetSetParam_SuperObjectValue(p_Tree)) #define M_lChannelInterpret(p_Tree) (M_GetSetParam_lChannelValue(p_Tree)) #define M_SoundEventInterpret(p_Tree) (M_GetSetParam_SoundEvent(p_Tree)) #define M_ComportInterpret(p_Tree) (M_GetSetParam_pComport(p_Tree)) #define M_TextInterpret(p_Tree) (M_GetSetParam_hText(p_Tree)) #define M_ParticleGeneratorInterpret(p_Tree) (M_GetSetParam_hParticleGenerator(p_Tree)) #define M_GameMaterialInterpret(p_Tree) (M_GetSetParam_hGameMaterial(p_Tree)) #define M_ObjectTableInterpret(p_Tree) (M_GetSetParam_hObjectTable(p_Tree)) #define M_ColorValueInterpret(p_Tree) (M_GetSetParam_ColorValue(p_Tree)) #define M_p_stModelInterpret(p_Tree) (M_GetSetParam_p_stModel(p_Tree)) #define M_ClearNodeInterpret(p_Tree) memset((void*) (p_Tree),0,sizeof(struct tdstNodeInterpret_)); #define M_IsTheEndOfTree(p_Tree) (M_GetTypeInterpret(p_Tree) == E_ti_EndTree) #define M_p_stLightInterpret(p_Tree) (M_GetSetParam_LightValue(p_Tree)) #define M_ulCapsInterpret(p_Tree) (M_GetSetParam_CapsValue(p_Tree)) #define M_p_stGraphInterpret(p_Tree) (M_GetSetParam_GraphValue(p_Tree)) #define M_p_stMacroInterpret(p_Tree) (M_GetSetParam_p_stMacroValue(p_Tree)) /*---------------------------------------------------------------------------*/ /* Usefull misc. definitions */ /*---------------------------------------------------------------------------*/ #if defined(__DEBUG_AI__) #define M_VerifyNbParamAction(p_stTree, NParam) \ if (fn_ucGetTreeNbParam((p_stTree)) != NParam) \ { \ M_AIFatalError(E_uwAIFatalWrongParamAction); \ } #define M_VerifyTypeOfParamAction(p_stParam, eType) \ if (M_GetSetParam_Type(p_stParam) != eType) \ { \ M_AIFatalError(E_uwAIFatalWrongTypeParamAction); \ } #define M_Verify2TypesOfParamAction(p_stParam, eType1, eType2) \ if ( (M_GetSetParam_Type(p_stParam) != eType1) && (M_GetSetParam_Type(p_stParam) != eType2) ) \ { \ M_AIFatalError(E_uwAIFatalWrongTypeParamAction); \ } #else #define M_VerifyNbParamAction(p_stTree, NParam) #define M_VerifyTypeOfParamAction(p_stParam, eType) #define M_Verify2TypesOfParamAction(p_stParam, eType1, eType2) #endif /* __DEBUG_AI__*/ /*---------------------------------------------------------------------------*/ /* Structures definitions */ /*---------------------------------------------------------------------------*/ #include "EnumType.h" typedef union tduIdInterpret_ { enum tdeCondId_ eCondId; enum tdeKeyWordId_ eKeyWordId; enum tdeOperatorId_ eOperatorId; enum tdeFuncId_ eFuncId; enum tdeProcedureId_ eProcedureId; enum tdeFieldId_ eFieldId; enum tdeMetaActionId_ eMetaActionId; IPT_tdxHandleToEntryElement hInputAction; } tduIdInterpret; typedef struct tdstNodeInterpret_ { union { union tduIdInterpret_ uId; union tduGetSetParamForNode_ uParam; /*this trick allow us to have sizeof(uParam)=4 instead of 12 : great for U64*/ } #if defined(U64) uDummy #endif ; /* this trick allow us to have sizeof(eType)=1 instead of 4 : it is benefit if we respect alignment : great for U64*/ #if defined(__DEBUG_AI__) enum tdeTypeInterpret_ eType; #endif /* __DEBUG_AI__*/ #if defined(OPTIMIZE_SWAP_PARAMETER) unsigned short uwNodeToSkip; #endif /* OPTIMIZE_SWAP_PARAMETER*/ unsigned char ucDepth; #if !defined(__DEBUG_AI__) unsigned char eType; #endif #if defined(ACTIVE_AIDEBUG) ACP_tdxBool bBreakPoint; /**** DR ****/ #endif /*ACTIVE_AIDEBUG*/ } tdstNodeInterpret; typedef struct tdstTreeInterpret_ { struct tdstNodeInterpret_ *p_stNodeInterpret; #if !defined(OPTIMIZE_NB_NODES) unsigned short uwNbNode; /* For debug*/ #endif } tdstTreeInterpret; typedef struct tdstMacro_ { #if defined(__DEBUG_AI__) char szName[256]; #endif struct tdstTreeInterpret_ *p_stInitTree; struct tdstTreeInterpret_ *p_stCurrentTree; } tdstMacro; typedef struct tdstListOfMacro_ { struct tdstMacro_ *p_stMacro; unsigned char ucNbMacro; /* For second pass.*/ } tdstListOfMacro; typedef struct tdstComport_ { #if defined(__DEBUG_AI__) char szName[256]; #endif struct tdstTreeInterpret_ *p_stRules; /* For Schedule.*/ struct tdstTreeInterpret_ *p_stSchedule; //XB 05/08/99 #ifndef D_THROW_CFAST_AI //End XB long CFast_lMyIndex; //XB 05/08/99 #endif /* D_THROW_CFAST_AI */ //End XB unsigned char ucNbRules; } tdstComport; typedef struct tdstScriptAI_ { struct tdstComport_ *p_stComport; unsigned long ulNbComport; unsigned long ulNoComportInitDefault; unsigned char ucActionTableNbEntry; } tdstScriptAI; typedef struct tdstIntelligence_ { struct tdstScriptAI_ **p_p_stScriptAI; struct tdstNodeInterpret_ *p_stCurrentSchedule; struct tdstComport_ *p_stCurrentComport; /* Current comport when we execute the last ChangeComport.*/ struct tdstComport_ *p_stPrevComport; struct tdstActionTable_ *p_stActionTable; unsigned long ulNoComportInit; } tdstIntelligence; /*---------------------------------------------------------------------------*/ /* Strintel.c functions*/ /*---------------------------------------------------------------------------*/ /*EXTERN_AI_DLL CPA_EXPORT */ void fn_vReinitComport(struct tdstIntelligence_ *p_stIntelligence); unsigned char fn_ucChangeComportIntell(struct tdstIntelligence_ *p_stIntelligence, struct tdstComport_ *p_stComport); unsigned char fn_ucGetTreeNbParam(struct tdstNodeInterpret_ *p_stTree); #if defined(OPTIMIZE_NB_NODES) EXTERN_AI_DLL CPA_EXPORT unsigned short fn_uwGetNbNodeInterpret(struct tdstTreeInterpret_ *p_stTree); #endif /* OPTIMIZE_NB_NODES*/ /**************************************************************/ /* AI init functions used by allocations */ /**************************************************************/ /* EXTERN_AI_DLL CPA_EXPORT void fn_vInitComport(struct tdstComport_ *p_stComport); EXTERN_AI_DLL CPA_EXPORT void fn_vInitRule(struct tdstTreeInterpret_ *p_stRule); */ EXTERN_AI_DLL CPA_EXPORT void fn_vInitNodeInterpret(struct tdstNodeInterpret_ *p_stNode, long lVal, enum tdeTypeInterpret_ eTypeInterpret, unsigned char ucDepth); /* EXTERN_AI_DLL CPA_EXPORT void fn_vFullInitNodeInterpret(struct tdstIntelligence_ *p_stIntelligence, unsigned long ulNbComport, unsigned char ucNbRules, unsigned short uwNbNode, long lVal, enum tdeTypeInterpret_ eTypeInterpret, unsigned char ucDepth); */ /**************************************************************/ /* AI allocation functions for macros : */ /**************************************************************/ EXTERN_AI_DLL CPA_EXPORT void fn_vAllocListOfMacro(struct AI_tdstMind_ *p_stMind, unsigned char ucNbMacro); EXTERN_AI_DLL CPA_EXPORT void fn_vAllocNodeMacro(tdstMacro *p_stMacro, unsigned short ucNbNode); EXTERN_AI_DLL CPA_EXPORT struct tdstListOfMacro_ *fn_p_stAllocListOfMacro(unsigned char ucNbMacro); /**************************************************************/ /* AI allocation functions : */ /**************************************************************/ EXTERN_AI_DLL CPA_EXPORT struct AI_tdstAIModel_ *fn_p_stAllocAIModel(); EXTERN_AI_DLL CPA_EXPORT struct tdstScriptAI_ *fn_p_stAllocScriptAI(unsigned char ucActionTableNbEntry); EXTERN_AI_DLL CPA_EXPORT struct tdstIntelligence_ *fn_p_stAllocIntelligence(struct tdstScriptAI_ **p_p_stScriptAI,unsigned char ucActionTableNbEntry); EXTERN_AI_DLL CPA_EXPORT struct tdstActionTableEntry_ *fn_p_stAllocActionTableEntry(unsigned char ucActionTableEntry); EXTERN_AI_DLL CPA_EXPORT struct tdstActionTable_ *fn_p_stAllocActionTable(unsigned char ucActionTableNbEntry); EXTERN_AI_DLL CPA_EXPORT struct tdstComport_ *fn_p_stAllocComport(unsigned long ulNbComport); EXTERN_AI_DLL CPA_EXPORT struct tdstTreeInterpret_ *fn_p_stAllocRule(unsigned char ucNbRules); EXTERN_AI_DLL CPA_EXPORT struct tdstNodeInterpret_ *fn_p_stAllocNodeInterpret(unsigned short uwNbNode); EXTERN_AI_DLL CPA_EXPORT struct tdstTreeInterpret_ *fn_p_stAllocSchedule(unsigned short uwNbNode); EXTERN_AI_DLL CPA_EXPORT void fn_vCreateNodeString(struct tdstNodeInterpret_ *p_stNode, char *szString); EXTERN_AI_DLL CPA_EXPORT void fn_vCreateNodeVector(struct tdstNodeInterpret_ *p_stNode); #ifdef ACTIVE_EDITOR /**************************************************************/ /* AI deallocation functions : */ /**************************************************************/ EXTERN_AI_DLL CPA_EXPORT void fn_vFreeNodeContent(struct tdstNodeInterpret_ *p_stNode); EXTERN_AI_DLL CPA_EXPORT void fn_vFreeNodeInterpretAll(struct tdstNodeInterpret_ **p_p_stNode,unsigned short uwNbNodes); EXTERN_AI_DLL CPA_EXPORT void fn_vFreeRuleContent(struct tdstTreeInterpret_ *p_stRules); EXTERN_AI_DLL CPA_EXPORT void fn_vFreeRuleAll(struct tdstTreeInterpret_ **p_p_stRules,unsigned char ucNbRules); EXTERN_AI_DLL CPA_EXPORT void fn_vFreeScheduleContent(struct tdstTreeInterpret_ *p_stSchedule); EXTERN_AI_DLL CPA_EXPORT void fn_vFreeScheduleAll(struct tdstTreeInterpret_ **p_p_stSchedule); EXTERN_AI_DLL CPA_EXPORT void fn_vFreeComportContent(struct tdstComport_ *p_stComport); EXTERN_AI_DLL CPA_EXPORT void fn_vFreeComportAll(struct tdstComport_ **p_p_stComport,unsigned long ulNbComport); EXTERN_AI_DLL CPA_EXPORT void fn_vFreeScriptAIContent(struct tdstScriptAI_ *p_stScriptAI); EXTERN_AI_DLL CPA_EXPORT void fn_vFreeScriptAIAll(struct tdstScriptAI_ **p_p_stScriptAI); EXTERN_AI_DLL CPA_EXPORT void fn_vFreeAIModelContent(struct AI_tdstAIModel_ *p_stAIModel); EXTERN_AI_DLL CPA_EXPORT void fn_vFreeAIModelAll(struct AI_tdstAIModel_ **p_p_stAIModel); EXTERN_AI_DLL CPA_EXPORT void fn_vFreeActionTableEntryContent(struct tdstActionTableEntry_ *p_stActionTableEntry); EXTERN_AI_DLL CPA_EXPORT void fn_vFreeActionTableEntryAll(struct tdstActionTableEntry_ **p_p_stActionTableEntry,unsigned ucActionTableNbEntry); EXTERN_AI_DLL CPA_EXPORT void fn_vFreeActionTableContent(struct tdstActionTable_ *p_stActionTable); EXTERN_AI_DLL CPA_EXPORT void fn_vFreeActionTableAll(struct tdstActionTable_ **p_p_stActionTable); EXTERN_AI_DLL CPA_EXPORT void fn_vFreeIntelligenceContent(struct tdstIntelligence_ *p_stIntelligence); EXTERN_AI_DLL CPA_EXPORT void fn_vFreeIntelligenceAll(struct tdstIntelligence_ **p_p_stIntelligence); EXTERN_AI_DLL CPA_EXPORT void fn_vFreeReflexAll(struct tdstIntelligence_ **p_p_stReflex); EXTERN_AI_DLL CPA_EXPORT void fn_vFreeMindContent(struct AI_tdstMind_ *p_stMind); EXTERN_AI_DLL CPA_EXPORT void fn_vFreeMindAll(struct AI_tdstMind_ **p_p_stMind); #endif /* ACTIVE_EDITOR*/ /*******************************************************************/ /* AI allocation and deallocation functions for variable designer: */ /*******************************************************************/ /* allocations*/ EXTERN_AI_DLL CPA_EXPORT void fn_vAllocVariableDesigner(struct AI_tdstMind_ *p_stMind,unsigned long ulSizeDsgMem,unsigned char ucNbParam); EXTERN_AI_DLL CPA_EXPORT struct tdstDsgVarInfo_ *fn_p_stAllocDsgVarInfo(unsigned char ucNbDsgVar); EXTERN_AI_DLL CPA_EXPORT struct tdstDsgVar_ *fn_p_stAllocDsgVar(unsigned long ulSize,unsigned char ucNbDsgVar); EXTERN_AI_DLL CPA_EXPORT char *fn_p_cAllocDsgMemBuffer(unsigned long ulSize); EXTERN_AI_DLL CPA_EXPORT struct tdstDsgMem_ *fn_p_stAllocDsgMem(struct tdstDsgVar_ **p_p_stDsgVar,unsigned long ulSize); #ifdef ACTIVE_EDITOR /* deallocations*/ EXTERN_AI_DLL CPA_EXPORT void fn_vFreeDesignerVariable(struct AI_tdstMind_ *p_stMind); EXTERN_AI_DLL CPA_EXPORT void fn_vFreeDsgVarInfoContent(struct tdstDsgVarInfo_ *p_stDsgVarInfo); EXTERN_AI_DLL CPA_EXPORT void fn_vFreeDsgVarInfoAll(struct tdstDsgVarInfo_ **p_p_stDsgVarInfo,unsigned char ucNbDsgVar); EXTERN_AI_DLL CPA_EXPORT void fn_vFreeDsgVarContent(struct tdstDsgVar_ *p_stDsgVar); EXTERN_AI_DLL CPA_EXPORT void fn_vFreeDsgVarAll(struct tdstDsgVar_ **p_p_stDsgVar); EXTERN_AI_DLL CPA_EXPORT void fn_vFreeDsgMemBuffer(char **p_p_cDsgMemBuffer); EXTERN_AI_DLL CPA_EXPORT void fn_vFreeDsgMemContent(struct tdstDsgMem_ *p_stDsgMem); EXTERN_AI_DLL CPA_EXPORT void fn_vFreeDsgMemAll(struct tdstDsgMem_ **p_p_stDsgMem); #endif /* ACTIVE_EDITOR*/ /*******************************************************************************/ #undef EXTERN_AI_DLL #endif /* __STRINTEL_H__*/