BVB Source Codes

CRYENGINE Show ICryMannequinEditor.h Source code

Return Download CRYENGINE: download ICryMannequinEditor.h Source code - Download CRYENGINE Source code - Type:.h
  1. // Copyright 2001-2016 Crytek GmbH / Crytek Group. All rights reserved.
  2.  
  3. //
  4. ////////////////////////////////////////////////////////////////////////////
  5. #ifndef __I_CRY_MANNEQUIN_EDITOR_H__
  6. #define __I_CRY_MANNEQUIN_EDITOR_H__
  7.  
  8. #include "ICryMannequin.h"
  9.  
  10. enum EFileEntryType { eFET_Database, eFET_ControllerDef, eFET_TagDef };
  11.  
  12. struct IMannequinWriter
  13. {
  14.         virtual ~IMannequinWriter() {}
  15.         virtual void SaveFile(const char* szFilename, XmlNodeRef xmlNode, EFileEntryType fileEntryType) = 0;
  16. };
  17.  
  18. struct IMannequinEditorListener
  19. {
  20.         virtual ~IMannequinEditorListener() {}
  21.         virtual void OnMannequinTagDefInvalidated(const CTagDefinition& tagDefinition) = 0;
  22. };
  23.  
  24. struct SAnimDBSnapshot
  25. {
  26.         IAnimationDatabase* pDatabase;
  27.         XmlNodeRef          xmlData;
  28. };
  29.  
  30. struct SAnimControllerDefSnapshot
  31. {
  32.         SControllerDef* pControllerDef;
  33.         XmlNodeRef      xmlData;
  34. };
  35.  
  36. typedef DynArray<SAnimDBSnapshot>            TAnimDBSnapshotCollection;
  37. typedef DynArray<SAnimControllerDefSnapshot> TAnimControllerDefSnapshotCollection;
  38.  
  39. struct SSnapshotCollection
  40. {
  41.         TAnimDBSnapshotCollection            m_databases;
  42.         TAnimControllerDefSnapshotCollection m_controllerDefs;
  43. };
  44.  
  45. enum EModifyFragmentIdResult
  46. {
  47.         eMFIR_Success,
  48.         eMFIR_DuplicateName,
  49.         eMFIR_InvalidNameIdentifier,
  50.         eMFIR_UnknownInputTagDefinition,
  51.         eMFIR_InvalidFragmentId,
  52. };
  53.  
  54. struct SEditorFragmentBlendID
  55. {
  56.         FragmentID fragFrom;
  57.         FragmentID fragTo;
  58.         typedef DynArray<SEditorFragmentBlendID> TEditorFragmentBlendIDArray;
  59. };
  60.  
  61. struct SEditorFragmentBlendVariant
  62. {
  63.         SFragTagState tagsFrom;
  64.         SFragTagState tagsTo;
  65.         typedef DynArray<SEditorFragmentBlendVariant> TEditorFragmentBlendVariantArray;
  66. };
  67.  
  68. struct IMannequinEditorManager
  69. {
  70.         virtual ~IMannequinEditorManager() {}
  71.  
  72.         virtual EModifyFragmentIdResult CreateFragmentID(const CTagDefinition& fragmentIds, const char* szFragmentIdName) = 0;
  73.         virtual EModifyFragmentIdResult RenameFragmentID(const CTagDefinition& fragmentIds, FragmentID fragmentID, const char* szFragmentIdName) = 0;
  74.         virtual EModifyFragmentIdResult DeleteFragmentID(const CTagDefinition& fragmentIds, FragmentID fragmentID) = 0;
  75.  
  76.         virtual bool                    SetFragmentTagDef(const CTagDefinition& fragmentIds, FragmentID fragmentID, const CTagDefinition* pFragTagDefs) = 0;
  77.         virtual void                    SetFragmentDef(const SControllerDef& controllerDef, FragmentID fragmentID, const SFragmentDef& fragmentDef) = 0;
  78.  
  79.         virtual void                    SaveDatabasesSnapshot(SSnapshotCollection& snapshotCollection) const = 0;
  80.         virtual void                    LoadDatabasesSnapshot(const SSnapshotCollection& snapshotCollection) = 0;
  81.  
  82.         virtual void                    GetLoadedTagDefs(DynArray<const CTagDefinition*>& tagDefs) = 0;
  83.         virtual void                    GetLoadedDatabases(DynArray<const IAnimationDatabase*>& animDatabases) const = 0;
  84.         virtual void                    GetLoadedControllerDefs(DynArray<const SControllerDef*>& controllerDefs) const = 0;
  85.  
  86.         virtual void                    SaveAll(IMannequinWriter* pWriter) const = 0;
  87.         virtual void                    SaveControllerDef(IMannequinWriter* pWriter, const SControllerDef* controllerDef) const = 0;
  88.         virtual void                    SaveDatabase(IMannequinWriter* pWriter, const IAnimationDatabase* database) const = 0;
  89.         virtual void                    SaveTagDefinition(IMannequinWriter* pWriter, const CTagDefinition* tagDef) const = 0;
  90.         virtual void                    RevertDatabase(const char* szFilename) = 0;
  91.         virtual void                    RevertControllerDef(const char* szFilename) = 0;
  92.         virtual void                    RevertTagDef(const char* szFilename) = 0;
  93.  
  94.         virtual bool                    DeleteFragmentEntry(IAnimationDatabase* pDatabase, FragmentID fragmentID, const SFragTagState& tagState, uint32 optionIdx, bool logWarning = true) = 0;
  95.         virtual uint32                  AddFragmentEntry(IAnimationDatabase* pDatabase, FragmentID fragmentID, const SFragTagState& tagState, const CFragment& fragment) = 0;
  96.         virtual void                    SetFragmentEntry(IAnimationDatabase* pDatabase, FragmentID fragmentID, const SFragTagState& tagState, uint32 optionIdx, const CFragment& fragment) = 0;
  97.  
  98.         virtual bool                    IsFileUsedByControllerDef(const SControllerDef& controllerDef, const char* szFilename) const = 0;
  99.  
  100.         virtual void                    GetAffectedFragmentsString(const CTagDefinition* pQueryTagDef, TagID tagID, char* buffer, int bufferSize) = 0;
  101.         virtual void                    ApplyTagDefChanges(const CTagDefinition* pOriginal, CTagDefinition* pModified) = 0;
  102.         virtual void                    RenameTag(const CTagDefinition* pOriginal, int32 tagCRC, const char* newName) = 0;
  103.         virtual void                    RenameTagGroup(const CTagDefinition* pOriginal, int32 tagGroupCRC, const char* newName) = 0;
  104.  
  105.         // Returns all tagdefinitions that this tagdefinition includes (recursively).
  106.         // Notes:
  107.         // - Does not include the pQueriedTagDef
  108.         // - Only includes tagdefinitions that are currently loaded
  109.         // - Clears tagDefs list when pQueriedTagDef is nullptr
  110.         virtual void              GetIncludedTagDefs(const CTagDefinition* pQueriedTagDef, DynArray<CTagDefinition*>& tagDefs) const = 0;
  111.  
  112.         virtual void              RegisterListener(IMannequinEditorListener* pListener) = 0;
  113.         virtual void              UnregisterListener(IMannequinEditorListener* pListener) = 0;
  114.  
  115.         virtual void              AddSubADBFragmentFilter(IAnimationDatabase* pDatabase, const char* szSubADBFilename, FragmentID fragmentID) = 0;
  116.         virtual void              RemoveSubADBFragmentFilter(IAnimationDatabase* pDatabase, const char* szSubADBFilename, FragmentID fragmentID) = 0;
  117.         virtual uint32            GetSubADBFragmentFilterCount(const IAnimationDatabase* pDatabase, const char* szSubADBFilename) const = 0;
  118.         virtual FragmentID        GetSubADBFragmentFilter(const IAnimationDatabase* pDatabase, const char* szSubADBFilename, uint32 index) const = 0;
  119.  
  120.         virtual void              SetSubADBTagFilter(IAnimationDatabase* pDatabase, const char* szSubADBFilename, TagState tagState) = 0;
  121.         virtual TagState          GetSubADBTagFilter(const IAnimationDatabase* pDatabase, const char* szSubADBFilename) const = 0;
  122.  
  123.         virtual void              SetBlend(IAnimationDatabase* pDatabase, FragmentID fragmentIDFrom, FragmentID fragmentIDTo, const SFragTagState& tagFrom, const SFragTagState& tagTo, SFragmentBlendUid blendUid, const SFragmentBlend& fragBlend) = 0;
  124.         virtual SFragmentBlendUid AddBlend(IAnimationDatabase* pDatabase, FragmentID fragmentIDFrom, FragmentID fragmentIDTo, const SFragTagState& tagFrom, const SFragTagState& tagTo, const SFragmentBlend& fragBlend) = 0;
  125.         virtual void              DeleteBlend(IAnimationDatabase* pDatabase, FragmentID fragmentIDFrom, FragmentID fragmentIDTo, const SFragTagState& tagFrom, const SFragTagState& tagTo, SFragmentBlendUid blendUid) = 0;
  126.         virtual void              GetFragmentBlends(const IAnimationDatabase* pDatabase, SEditorFragmentBlendID::TEditorFragmentBlendIDArray& outBlendIDs) const = 0;
  127.         virtual void              GetFragmentBlendVariants(const IAnimationDatabase* pDatabase, const FragmentID fragmentIDFrom, const FragmentID fragmentIDTo, SEditorFragmentBlendVariant::TEditorFragmentBlendVariantArray& outVariants) const = 0;
  128.         virtual void              GetFragmentBlend(const IAnimationDatabase* pIDatabase, const FragmentID fragmentIDFrom, const FragmentID fragmentIDTo, const SFragTagState& tagFrom, const SFragTagState& tagTo, const SFragmentBlendUid& blendUid, SFragmentBlend& outFragmentBlend) const = 0;
  129. };
  130.  
  131. struct IMannequinGameListener
  132. {
  133.         virtual ~IMannequinGameListener(){}
  134.  
  135.         virtual void OnSpawnParticleEmitter(struct IParticleEmitter* pEffect, IActionController& actionController) = 0;
  136. };
  137.  
  138. #endif
  139.  
downloadICryMannequinEditor.h Source code - Download CRYENGINE Source code
Related Source Codes/Software:
postal - 2017-06-11
reactide - Reactide is the first dedicated IDE for React web ... 2017-06-11
rkt - rkt is a pod-native container engine for Linux. It... 2017-06-11
uWebSockets - Tiny WebSockets https://for... 2017-06-11
realworld - TodoMVC for the RealWorld - Exemplary fullstack Me... 2017-06-11
CRYENGINE - CRYENGINE is a powerful real-time game development... 2017-06-11
goreplay - GoReplay is an open-source tool for capturing and ... 2017-06-10
pyenv - Simple Python version management 2017-06-10
redux-saga - An alternative side effect model for Redux apps ... 2017-06-10
angular-starter - 2017-06-10

 Back to top