![]() |
ezEngine Release 25.08
|
Classes | |
class | ThumbnailInfo |
The thumbnail info containing the hash of the file is appended to assets. The serialized size of this class can't change since it is found by seeking to the end of the file. More... | |
Public Member Functions | |
ezAssetDocument (ezStringView sDocumentPath, ezDocumentObjectManager *pObjectManager, ezAssetDocEngineConnection engineConnectionType) | |
![]() | |
ezDocument (ezStringView sPath, ezDocumentObjectManager *pDocumentObjectManagerImpl) | |
bool | IsModified () const |
bool | IsReadOnly () const |
const ezUuid | GetGuid () const |
const ezDocumentObjectManager * | GetObjectManager () const |
ezDocumentObjectManager * | GetObjectManager () |
ezSelectionManager * | GetSelectionManager () const |
ezCommandHistory * | GetCommandHistory () const |
virtual ezObjectAccessorBase * | GetObjectAccessor () const |
virtual void | GetSupportedMimeTypesForPasting (ezHybridArray< ezString, 4 > &out_mimeTypes) const |
Whether this document supports pasting the given mime format into it. | |
virtual bool | CopySelectedObjects (ezAbstractObjectGraph &out_objectGraph, ezStringBuilder &out_sMimeType) const |
Creates the abstract graph of data to be copied and returns the mime type for the clipboard to identify the data. | |
virtual bool | Paste (const ezArrayPtr< PasteInfo > &info, const ezAbstractObjectGraph &objectGraph, bool bAllowPickedPosition, ezStringView sMimeType) |
Pastes objects from the given object graph into the document. | |
void | BroadcastInterDocumentMessage (ezReflectedClass *pMessage, ezDocument *pSender) |
This will deliver the message to all open documents. The documents may respond, e.g. by modifying the content of the message. | |
virtual void | OnInterDocumentMessage (ezReflectedClass *pMessage, ezDocument *pSender) |
Called on all documents when BroadcastInterDocumentMessage() is called. | |
virtual ezEditorInputContext * | GetEditorInputContextOverride () |
Allows to return a single input context that currently overrides all others (in priority). | |
virtual void | DeleteSelectedObjects () const |
Deletes all currently selected objects in the document. | |
const ezSet< ezString > & | GetUnknownObjectTypes () const |
Returns the set of unknown object types encountered during loading. | |
ezUInt32 | GetUnknownObjectTypeInstances () const |
Returns the number of unknown object type instances encountered during loading. | |
void | SetAddToResetFilesList (bool b) |
If disabled, this document will not be put into the recent files list. | |
bool | GetAddToRecentFilesList () const |
Whether this document shall be put into the recent files list. | |
void | ShowDocumentStatus (const ezFormatString &msg) const |
Broadcasts a status message event. The window that displays the document may show this in some form, e.g. in the status bar. | |
virtual ezResult | ComputeObjectTransformation (const ezDocumentObject *pObject, ezTransform &out_result) const |
Tries to compute the position and rotation for an object in the document. Returns EZ_SUCCESS if it was possible. | |
virtual ezManipulatorSearchStrategy | GetManipulatorSearchStrategy () const |
Needed by ezManipulatorManager to know where to look for the manipulator attributes. | |
ezStringView | GetDocumentPath () const |
Returns the absolute path to the document. | |
ezStatus | SaveDocument (bool bForce=false) |
Saves the document, if it is modified. If bForce is true, the document will be written, even if it is not considered modified. | |
ezTaskGroupID | SaveDocumentAsync (AfterSaveCallback callback, bool bForce=false) |
Saves the document asynchronously. Calls the callback when done. | |
void | DocumentRenamed (ezStringView sNewDocumentPath) |
Updates the document path after a rename operation. | |
ezStatus | LoadDocument () |
Loads the document from disk. | |
void | EnsureVisible () |
Brings the corresponding window to the front. | |
ezDocumentManager * | GetDocumentManager () const |
Returns the document manager that owns this document. | |
bool | HasWindowBeenRequested () const |
const ezDocumentTypeDescriptor * | GetDocumentTypeDescriptor () const |
ezStringView | GetDocumentTypeName () const |
Returns the document's type name. Same as GetDocumentTypeDescriptor()->m_sDocumentTypeName. | |
const ezDocumentInfo * | GetDocumentInfo () const |
virtual bool | CanEngineProcessBeRestarted () const |
Asks the document whether a restart of the engine process is allowed at this time. | |
bool | IsMainDocument () const |
Returns whether this document is a main document, i.e. self contained. | |
bool | IsSubDocument () const |
Returns whether this document is a sub-document, i.e. is part of another document. | |
const ezDocument * | GetMainDocument () const |
In case this is a sub-document, returns the main document this belongs to. Otherwise 'this' is returned. | |
const ezDocument * | GetActiveSubDocument () const |
At any given time, only the active sub-document can be edited. This returns the active sub-document which can also be this document itself. Changes to the active sub-document are generally triggered by ezDocumentObjectStructureEvent::Type::AfterReset. | |
ezDocument * | GetMainDocument () |
ezDocument * | GetActiveSubDocument () |
virtual bool | ArePrefabsAllowed () const |
Whether the document allows to create prefabs in it. This may not be allowed for prefab documents themselves, to prevent nested prefabs. | |
virtual void | UpdatePrefabs () |
Updates ALL prefabs in the document with the latest changes. Merges the current prefab templates with the instances in the document. | |
void | RevertPrefabs (ezArrayPtr< const ezDocumentObject * > selection) |
Resets the given objects to their template prefab state, if they have local modifications. | |
virtual void | UnlinkPrefabs (ezArrayPtr< const ezDocumentObject * > selection) |
Removes the link between a prefab instance and its template, turning the instance into a regular object. | |
virtual ezStatus | CreatePrefabDocumentFromSelection (ezStringView sFile, const ezRTTI *pRootType, ezDelegate< void(ezAbstractObjectNode *)> adjustGraphNodeCB={}, ezDelegate< void(ezDocumentObject *)> adjustNewNodesCB={}, ezDelegate< void(ezAbstractObjectGraph &graph, ezDynamicArray< ezAbstractObjectNode * > &graphRootNodes)> finalizeGraphCB={}) |
Creates a prefab document from the current selection. | |
virtual ezStatus | CreatePrefabDocument (ezStringView sFile, ezArrayPtr< const ezDocumentObject * > rootObjects, const ezUuid &invPrefabSeed, ezUuid &out_newDocumentGuid, ezDelegate< void(ezAbstractObjectNode *)> adjustGraphNodeCB={}, bool bKeepOpen=false, ezDelegate< void(ezAbstractObjectGraph &graph, ezDynamicArray< ezAbstractObjectNode * > &graphRootNodes)> finalizeGraphCB={}) |
Creates a prefab document from the given root objects. | |
virtual ezUuid | ReplaceByPrefab (const ezDocumentObject *pRootObject, ezStringView sPrefabFile, const ezUuid &prefabAsset, const ezUuid &prefabSeed, bool bEnginePrefab) |
Replaces the given object by a prefab instance. Returns new guid of replaced object. | |
virtual ezUuid | RevertPrefab (const ezDocumentObject *pObject) |
Reverts the given object to its prefab state. Returns new guid of reverted object. | |
![]() | |
virtual const ezRTTI * | GetDynamicRTTI () const |
bool | IsInstanceOf (const ezRTTI *pType) const |
Returns whether the type of this instance is of the given type or derived from it. | |
template<typename T > | |
EZ_ALWAYS_INLINE bool | IsInstanceOf () const |
Returns whether the type of this instance is of the given type or derived from it. | |
Public Attributes | |
ezEvent< const ezEditorEngineDocumentMsg * > | m_ProcessMessageEvent |
![]() | |
ezUniquePtr< ezObjectMetaData< ezUuid, ezDocumentObjectMetaData > > | m_DocumentObjectMetaData |
Meta data for all document objects. | |
ezEvent< const ezDocumentEvent & > | m_EventsOne |
Event for document-specific notifications. | |
ezEvent< const ezObjectAccessorChangeEvent & > | m_ObjectAccessorChangeEvents |
Event for object accessor change notifications. | |
Protected Member Functions | |
void | EngineConnectionEventHandler (const ezEditorEngineProcessConnection::Event &e) |
void | AddPrefabDependencies (const ezDocumentObject *pObject, ezAssetDocumentInfo *pInfo) const |
Adds all prefab dependencies to the ezAssetDocumentInfo object. Called automatically by UpdateAssetDocumentInfo() | |
void | AddReferences (const ezDocumentObject *pObject, ezAssetDocumentInfo *pInfo, bool bInsidePrefab) const |
Crawls through all asset properties of pObject and adds all string properties that have a ezAssetBrowserAttribute as a dependency to pInfo. Automatically called by UpdateAssetDocumentInfo() | |
virtual ezDocumentInfo * | CreateDocumentInfo () override |
Creates the document info structure. Must be implemented by derived classes. | |
ezTransformStatus | DoTransformAsset (const ezPlatformProfile *pAssetProfile, ezBitflags< ezTransformFlags > transformFlags) |
Hash Functions | |
ezUInt64 | GetDocumentHash () const |
Computes the hash from all document objects. | |
void | GetChildHash (const ezDocumentObject *pObject, ezUInt64 &inout_uiHash) const |
Computes the hash for one document object and combines it with the given hash. | |
virtual void | InternalGetMetaDataHash (const ezDocumentObject *pObject, ezUInt64 &inout_uiHash) const |
Computes the hash for transform relevant meta data of the given document object and combines it with the given hash. | |
Reimplemented Base Functions | |
virtual ezTaskGroupID | InternalSaveDocument (AfterSaveCallback callback) override |
Overrides the base function to call UpdateAssetDocumentInfo() to update the settings hash. | |
virtual void | InternalAfterSaveDocument () override |
Implements auto transform on save. | |
virtual void | InitializeAfterLoading (bool bFirstTimeCreation) override |
virtual void | InitializeAfterLoadingAndSaving () override |
Thumbnail Functions | |
virtual ezTransformStatus | InternalCreateThumbnail (const ThumbnailInfo &thumbnailInfo) |
Override this function to generate a thumbnail. Only called if GetAssetFlags returns ezAssetDocumentFlags::SupportsThumbnail. | |
ezString | GetThumbnailFilePath (ezStringView sSubAssetName=ezStringView()) const |
Returns the full path to the jpg file in which the thumbnail for this asset is supposed to be. | |
void | InvalidateAssetThumbnail (ezStringView sSubAssetName=ezStringView()) const |
Should be called after manually changing the thumbnail, such that the system will reload it. | |
ezStatus | RemoteCreateThumbnail (const ThumbnailInfo &thumbnailInfo, ezArrayPtr< ezStringView > viewExclusionTags) const |
Requests the engine side to render a thumbnail, will call SaveThumbnail on success. | |
ezStatus | RemoteCreateThumbnail (const ThumbnailInfo &thumbnailInfo) const |
ezStatus | SaveThumbnail (const ezImage &img, const ThumbnailInfo &thumbnailInfo) const |
Saves the given image as the new thumbnail for the asset. | |
ezStatus | SaveThumbnail (const QImage &img, const ThumbnailInfo &thumbnailInfo) const |
Saves the given image as the new thumbnail for the asset. | |
void | AppendThumbnailInfo (ezStringView sThumbnailFile, const ThumbnailInfo &thumbnailInfo) const |
Appends an asset header containing the thumbnail hash to the file. Each thumbnail is appended by it to check up-to-date state. | |
![]() | |
void | SetModified (bool b) |
void | SetReadOnly (bool b) |
virtual ezStatus | InternalLoadDocument () |
Internal load implementation. Loads the document from disk. | |
virtual void | AttachMetaDataBeforeSaving (ezAbstractObjectGraph &graph) const |
virtual void | RestoreMetaDataAfterLoading (const ezAbstractObjectGraph &graph, bool bUndoable) |
virtual void | BeforeClosing () |
void | SetUnknownObjectTypes (const ezSet< ezString > &Types, ezUInt32 uiInstances) |
virtual void | UpdatePrefabsRecursive (ezDocumentObject *pObject) |
Recursively updates all prefab instances starting from the given object. | |
virtual void | UpdatePrefabObject (ezDocumentObject *pObject, const ezUuid &PrefabAsset, const ezUuid &PrefabSeed, ezStringView sBasePrefab) |
Protected Attributes | |
ezUniquePtr< ezIPCObjectMirrorEditor > | m_pMirror |
EngineStatus | m_EngineStatus |
ezAssetDocEngineConnection | m_EngineConnectionType = ezAssetDocEngineConnection::None |
ezEditorEngineConnection * | m_pEngineConnection |
ezHashTable< ezUuid, ezEditorEngineSyncObject * > | m_AllSyncObjects |
ezDeque< ezEditorEngineSyncObject * > | m_SyncObjects |
ezHybridArray< ezUuid, 32 > | m_DeletedObjects |
![]() | |
ezUniquePtr< ezDocumentObjectManager > | m_pObjectManager |
ezUniquePtr< ezCommandHistory > | m_pCommandHistory |
ezUniquePtr< ezSelectionManager > | m_pSelectionManager |
ezUniquePtr< ezObjectCommandAccessor > | m_pObjectAccessor |
Default object accessor used by every doc. | |
ezDocumentInfo * | m_pDocumentInfo = nullptr |
const ezDocumentTypeDescriptor * | m_pTypeDescriptor = nullptr |
ezDocument * | m_pHostDocument = nullptr |
Pointer to the main document if this is a sub-document, otherwise self. | |
ezDocument * | m_pActiveSubDocument = nullptr |
Pointer to the currently active sub-document. | |
IPC Functions | |
enum class | EngineStatus { Unsupported , Disconnected , Initializing , Loaded } |
EngineStatus | GetEngineStatus () const |
Returns the current state of the engine process side of this document. | |
ezStatus | WaitForEngineStatusLoaded () const |
Waits for GetEngineStatus to return Loaded or returns a failure reason. | |
virtual ezVariant | GetCreateEngineMetaData () const |
Passed into ezEngineProcessDocumentContext::Initialize on the engine process side. Allows the document to provide additional data to the engine process during context creation. | |
bool | SendMessageToEngine (ezEditorEngineDocumentMsg *pMessage) const |
Sends a message to the corresponding ezEngineProcessDocumentContext on the engine process. | |
virtual void | HandleEngineMessage (const ezEditorEngineDocumentMsg *pMsg) |
Handles all messages received from the corresponding ezEngineProcessDocumentContext on the engine process. | |
ezEditorEngineConnection * | GetEditorEngineConnection () const |
Returns the ezEditorEngineConnection for this document. | |
void | AddSyncObject (ezEditorEngineSyncObject *pSync) const |
Registers a sync object for this document. It will be mirrored to the ezEngineProcessDocumentContext on the engine process. | |
void | RemoveSyncObject (ezEditorEngineSyncObject *pSync) const |
Removes a previously registered sync object. It will be removed on the engine process side. | |
ezEditorEngineSyncObject * | FindSyncObject (const ezUuid &guid) const |
Returns the sync object registered under the given guid. | |
ezEditorEngineSyncObject * | FindSyncObject (const ezRTTI *pType) const |
Returns the first sync object registered with the given type. | |
void | SyncObjectsToEngine () const |
Sends messages to sync all sync objects to the engine process side. | |
void | SendDocumentOpenMessage (bool bOpen) |
Common Asset States | |
ezEvent< const ezCommonAssetUiState & > | m_CommonAssetUiChangeEvent |
Used to broadcast state change events for common asset states. | |
ezUInt32 | m_uiCommonAssetStateFlags = 0 |
virtual void | SetCommonAssetUiState (ezCommonAssetUiState::Enum state, double value) |
Override this to handle a change to a common asset state differently. | |
virtual double | GetCommonAssetUiState (ezCommonAssetUiState::Enum state) const |
Override this to return custom values for a common asset state. | |
Asset Functions | |
ezAssetDocumentManager * | GetAssetDocumentManager () const |
const ezAssetDocumentInfo * | GetAssetDocumentInfo () const |
ezBitflags< ezAssetDocumentFlags > | GetAssetFlags () const |
const ezAssetDocumentTypeDescriptor * | GetAssetDocumentTypeDescriptor () const |
ezTransformStatus | TransformAsset (ezBitflags< ezTransformFlags > transformFlags, const ezPlatformProfile *pAssetProfile=nullptr) |
Transforms an asset. Typically not called manually but by the curator which takes care of dependencies first. | |
ezTransformStatus | CreateThumbnail () |
Updates the thumbnail of the asset. Should never be called manually. Called only by the curator which takes care of dependencies first. | |
ezUInt16 | GetAssetTypeVersion () const |
Returns the RTTI type version of this asset document type. E.g. when the algorithm to transform an asset changes, Increase the RTTI version. This will ensure that assets get re-transformed, even though their settings and dependencies might not have changed. | |
virtual void | UpdateAssetDocumentInfo (ezAssetDocumentInfo *pInfo) const |
Override this to add custom data (e.g. additional file dependencies) to the info struct. | |
virtual ezTransformStatus | InternalTransformAsset (ezStreamWriter &stream, ezStringView sOutputTag, const ezPlatformProfile *pAssetProfile, const ezAssetFileHeader &AssetHeader, ezBitflags< ezTransformFlags > transformFlags)=0 |
Override this and write the transformed file for the given szOutputTag into the given stream. | |
virtual ezTransformStatus | InternalTransformAsset (const char *szTargetFile, ezStringView sOutputTag, const ezPlatformProfile *pAssetProfile, const ezAssetFileHeader &AssetHeader, ezBitflags< ezTransformFlags > transformFlags) |
Only override this function, if the transformed file for the given szOutputTag must be written from another process. | |
ezStatus | RemoteExport (const ezAssetFileHeader &header, const char *szOutputTarget) const |
Additional Inherited Members | |
![]() | |
using | AfterSaveCallback = ezDelegate< void(ezDocument *, ezStatus)> |
Callback type for asynchronous save operations. | |
![]() | |
static ezStatus | ReadDocument (ezStringView sDocumentPath, ezUniquePtr< ezAbstractObjectGraph > &ref_pHeader, ezUniquePtr< ezAbstractObjectGraph > &ref_pObjects, ezUniquePtr< ezAbstractObjectGraph > &ref_pTypes) |
Reads a document from disk and parses its header, objects, and types. | |
static ezStatus | ReadAndRegisterTypes (const ezAbstractObjectGraph &types) |
Reads and registers types from the given object graph. | |
![]() | |
static const ezRTTI * | GetStaticRTTI () |
![]() | |
static ezEvent< const ezDocumentEvent & > | s_EventsAny |
Static event for notifications across all documents. | |
|
strong |
|
overrideprotectedvirtual |
Creates the document info structure. Must be implemented by derived classes.
Implements ezDocument.
Reimplemented in ezSimpleAssetDocument< PropertyType, BaseClass >, ezSimpleAssetDocument< ezAngelScriptAssetProperties >, ezSimpleAssetDocument< ezAnimatedMeshAssetProperties >, ezSimpleAssetDocument< ezAnimationClipAssetProperties >, ezSimpleAssetDocument< ezAnimationGraphAssetProperties >, ezSimpleAssetDocument< ezBlackboardTemplateAssetObject >, ezSimpleAssetDocument< ezCollectionAssetData >, ezSimpleAssetDocument< ezColorGradientAssetData >, ezSimpleAssetDocument< ezCurveGroupData >, ezSimpleAssetDocument< ezCustomDataAssetProperties >, ezSimpleAssetDocument< ezDecalAssetProperties >, ezSimpleAssetDocument< ezEditableSkeleton >, ezSimpleAssetDocument< ezImageDataAssetProperties >, ezSimpleAssetDocument< ezJoltCollisionMeshAssetProperties >, ezSimpleAssetDocument< ezKrautTreeAssetProperties >, ezSimpleAssetDocument< ezLUTAssetProperties >, ezSimpleAssetDocument< ezMaterialAssetProperties >, ezSimpleAssetDocument< ezMeshAssetProperties >, ezSimpleAssetDocument< ezMiniAudioSoundAssetProperties >, ezSimpleAssetDocument< ezParticleEffectDescriptor >, ezSimpleAssetDocument< ezPropertyAnimationTrackGroup, ezGameObjectContextDocument >, ezSimpleAssetDocument< ezRmlUiAssetProperties >, ezSimpleAssetDocument< ezSoundBankAssetProperties >, ezSimpleAssetDocument< ezSoundEventAssetProperties >, ezSimpleAssetDocument< ezSubstancePackageAssetProperties >, ezSimpleAssetDocument< ezSurfaceResourceDescriptor >, ezSimpleAssetDocument< ezTextureAssetProperties >, ezSimpleAssetDocument< ezTextureCubeAssetProperties >, and ezSimpleAssetDocument< ezVisualScriptClassAssetProperties >.
|
virtual |
Override this to return custom values for a common asset state.
Reimplemented in ezAnimationClipAssetDocument.
|
inlinevirtual |
Passed into ezEngineProcessDocumentContext::Initialize on the engine process side. Allows the document to provide additional data to the engine process during context creation.
Reimplemented in ezLayerDocument.
|
virtual |
Handles all messages received from the corresponding ezEngineProcessDocumentContext on the engine process.
Reimplemented in ezGameObjectDocument, ezScene2Document, and ezSceneDocument.
|
overrideprotectedvirtual |
Reimplemented from ezDocument.
|
overrideprotectedvirtual |
Reimplemented from ezDocument.
|
overrideprotectedvirtual |
Implements auto transform on save.
Reimplemented from ezDocument.
|
protectedvirtual |
Override this function to generate a thumbnail. Only called if GetAssetFlags returns ezAssetDocumentFlags::SupportsThumbnail.
Reimplemented in ezAnimatedMeshAssetDocument, ezAnimationClipAssetDocument, ezColorGradientAssetDocument, ezCurve1DAssetDocument, ezDecalAssetDocument, ezMaterialAssetDocument, ezMeshAssetDocument, ezSkeletonAssetDocument, ezJoltCollisionMeshAssetDocument, ezKrautTreeAssetDocument, ezParticleEffectAssetDocument, ezRmlUiAssetDocument, and ezSceneDocument.
|
inlineprotectedvirtual |
Computes the hash for transform relevant meta data of the given document object and combines it with the given hash.
Reimplemented in ezAnimationGraphAssetDocument, ezMaterialAssetDocument, ezRenderPipelineAssetDocument, ezStateMachineAssetDocument, ezProcGenGraphAssetDocument, and ezVisualScriptClassAssetDocument.
|
overrideprotectedvirtual |
Overrides the base function to call UpdateAssetDocumentInfo() to update the settings hash.
Reimplemented from ezDocument.
Reimplemented in ezScene2Document.
|
protectedvirtual |
Only override this function, if the transformed file for the given szOutputTag must be written from another process.
szTargetFile is where the transformed asset should be written to. The overriding function must ensure to first write AssetHeader to the file, to make it a valid asset file or provide a custom ezAssetDocumentManager::IsOutputUpToDate function. See ezTransformFlags for definition of transform flags.
Reimplemented in ezAngelScriptAssetDocument, ezImageDataAssetDocument, ezLUTAssetDocument, ezMaterialAssetDocument, ezRenderPipelineAssetDocument, ezStateMachineAssetDocument, ezTextureAssetDocument, ezTextureCubeAssetDocument, ezScene2Document, ezSceneDocument, and ezSubstancePackageAssetDocument.
|
protectedpure virtual |
Override this and write the transformed file for the given szOutputTag into the given stream.
The stream already contains the ezAssetFileHeader. This is the function to prefer when the asset can be written directly from the editor process. AssetHeader is already written to the stream, but provided as reference.
stream | Data stream to write the asset to. |
szOutputTag | Either empty for the default output or matches one of the tags defined in ezAssetDocumentInfo::m_Outputs. |
szPlatform | Platform for which is the output is to be created. Default is 'Default'. |
AssetHeader | Header already written to the stream, provided for reference. |
transformFlags | flags that affect the transform process, see ezTransformFlags. |
Implemented in ezBlackboardTemplateAssetDocument, ezAngelScriptAssetDocument, ezAnimatedMeshAssetDocument, ezAnimationClipAssetDocument, ezAnimationGraphAssetDocument, ezCollectionAssetDocument, ezColorGradientAssetDocument, ezCurve1DAssetDocument, ezCustomDataAssetDocument, ezDecalAssetDocument, ezImageDataAssetDocument, ezLUTAssetDocument, ezMaterialAssetDocument, ezMeshAssetDocument, ezPropertyAnimAssetDocument, ezRenderPipelineAssetDocument, ezSkeletonAssetDocument, ezStateMachineAssetDocument, ezSurfaceAssetDocument, ezTextureAssetDocument, ezTextureCubeAssetDocument, ezSoundBankAssetDocument, ezSoundEventAssetDocument, ezJoltCollisionMeshAssetDocument, ezKrautTreeAssetDocument, ezMiniAudioSoundAssetDocument, ezParticleEffectAssetDocument, ezProcGenGraphAssetDocument, ezRmlUiAssetDocument, ezSceneDocument, ezSubstancePackageAssetDocument, and ezVisualScriptClassAssetDocument.
|
protected |
Saves the given image as the new thumbnail for the asset.
void ezAssetDocument::SendDocumentOpenMessage | ( | bool | bOpen | ) |
/brief Sends a message that the document has been opened or closed. Resends all document data.
Calling this will always clear the existing document on the engine side and reset the state to the editor state.
|
virtual |
Override this to handle a change to a common asset state differently.
By default an on-off flag for every state is tracked, but nothing else. Also this automatically broadcasts the m_CommonAssetUiChangeEvent event.
Reimplemented in ezAnimationClipAssetDocument.
ezTransformStatus ezAssetDocument::TransformAsset | ( | ezBitflags< ezTransformFlags > | transformFlags, |
const ezPlatformProfile * | pAssetProfile = nullptr |
||
) |
Transforms an asset. Typically not called manually but by the curator which takes care of dependencies first.
If ezTransformFlags::ForceTransform is set, it will try to transform the asset, ignoring whether the transform is up to date. If ezTransformFlags::TriggeredManually is set, transform produced changes will be saved back to the document. If ezTransformFlags::BackgroundProcessing is set and transforming the asset would require re-saving it, nothing is done.
|
protectedvirtual |
Override this to add custom data (e.g. additional file dependencies) to the info struct.
Reimplemented in ezAngelScriptAssetDocument, ezCustomDataAssetDocument, ezMaterialAssetDocument, ezMeshAssetDocument, ezSkeletonAssetDocument, ezTextureAssetDocument, ezTextureCubeAssetDocument, ezSoundBankAssetDocument, ezSoundEventAssetDocument, ezJoltCollisionMeshAssetDocument, ezMiniAudioSoundAssetDocument, ezParticleEffectAssetDocument, ezProcGenGraphAssetDocument, ezScene2Document, ezSceneDocument, ezSubstancePackageAssetDocument, and ezVisualScriptClassAssetDocument.