XII Release 0.1.0
Loading...
Searching...
No Matches
xiiStateMachineContext Class Reference

Copyright (c) Theophilus Eriata. All Rights Reserved. More...

#include <StateMachineContext.h>

Inheritance diagram for xiiStateMachineContext:
[legend]

Protected Member Functions

virtual xiiEngineProcessViewContext * CreateViewContext () override
 Needs to be implemented to create a view context used for windows and thumbnails rendering.
virtual void DestroyViewContext (xiiEngineProcessViewContext *pContext) override
 Needs to be implemented to destroy the view context created in CreateViewContext.
virtual xiiStatus ExportDocument (const xiiExportDocumentMsgToEngine *pMsg) override
 Exports to current document resource to file. Make sure to write xiiAssetFileHeader at the start of it.
Protected Member Functions inherited from xiiEngineProcessDocumentContext
virtual xiiStatus OnInitialize ()
 OnDeinitialize must release any state acquired before this hook returns failure.
virtual void OnDeinitialize ()
virtual bool PendingOperationInProgress () const
virtual void UpdateDocumentContext ()
void UpdateSyncObjects ()
void CreateThumbnailViewContext (const xiiCreateThumbnailMsgToEngine *pMsg)
 Creates the thumbnail view context. It uses 'CreateViewContext' in combination with an off-screen render target.
void DestroyThumbnailViewContext ()
 Once a thumbnail is successfully rendered, the thumbnail view context is destroyed again.
virtual bool UpdateThumbnailViewContext (xiiEngineProcessViewContext *pThumbnailViewContext)
virtual void OnThumbnailViewContextRequested ()
 Called before a thumbnail context is created.
virtual void OnThumbnailViewContextCreated ()
 Called after a thumbnail context was created. Allows to insert code before the thumbnail is generated.
virtual void OnDestroyThumbnailViewContext ()
 Called before a thumbnail context is destroyed. Used for cleanup of what was done in OnThumbnailViewContextCreated().
void SetTagOnObject (const xiiUuid &object, const char *szTag, bool bSet, bool recursive)
 Sets or removes the given tag on the object and optionally all children.
void SetTagRecursive (xiiGameObject *pObject, const xiiTag &tag)
 Sets the given tag on the object and all children.
void ClearTagRecursive (xiiGameObject *pObject, const xiiTag &tag)
 Clears the given tag on the object and all children.
const xiiEngineProcessViewContext * GetViewContext (xiiUInt32 uiView) const

Additional Inherited Members

Public Member Functions inherited from xiiEngineProcessDocumentContext
 xiiEngineProcessDocumentContext (xiiBitflags< xiiEngineProcessDocumentContextFlags > flags)
virtual xiiStatus Initialize (const xiiUuid &documentGuid, const xiiVariant &metaData, xiiEngineProcessCommunicationChannel *pIPC, xiiStringView sDocumentType)
 Initializes the context and rolls back partially initialized state on failure.
void Deinitialize ()
 Releases initialized or partially initialized state. Repeated calls are safe.
xiiStringView GetDocumentType () const
 Returns the document type for which this context was created. Useful in case a context may be used for multiple document types.
void SendProcessMessage (xiiProcessMessage *pMsg=nullptr)
virtual void HandleMessage (const xiiEditorEngineDocumentMsg *pMsg)
xiiBoundingBoxSphere GetWorldBounds (xiiWorld *pWorld)
void ProcessEditorEngineSyncObjectMsg (const xiiEditorEngineSyncObjectMsg &msg)
const xiiUuid & GetDocumentGuid () const
virtual xiiStatus Reset ()
void ClearExistingObjects ()
virtual xiiWorldRttiConverterContext & GetContext ()
virtual const xiiWorldRttiConverterContext & GetContext () const
xiiWorld * GetWorld () const
xiiResult DrawGizmos (const xiiView &view)
xiiResult PickGizmo (const xiiView &view, float fNormalizedX, float fNormalizedY, xiiEditorGizmoPickResult &out_result)
virtual xiiGameObjectHandle ResolveStringToGameObjectHandle (const void *pString, xiiComponentHandle hThis, xiiStringView sProperty) const
 Tries to resolve a 'reference' (given in pData) to a xiiGameObject.
Public Member Functions inherited from xiiReflectedClass
virtual const xiiRTTI * GetDynamicRTTI () const
bool IsInstanceOf (const xiiRTTI *pType) const
 Returns whether the type of this instance is of the given type or derived from it.
template<typename T>
XII_ALWAYS_INLINE bool IsInstanceOf () const
 Returns whether the type of this instance is of the given type or derived from it.
Static Public Member Functions inherited from xiiEngineProcessDocumentContext
static xiiEngineProcessDocumentContext * GetDocumentContext (xiiUuid guid)
static xiiStatus AllocateDocumentContext (const xiiDocumentOpenMsgToEngine &request, xiiEngineProcessDocumentContext *&out_pContext)
 Copyright (c) Theophilus Eriata. All Rights Reserved.
static xiiStatus AddDocumentContext (xiiUuid guid, const xiiVariant &metaData, xiiEngineProcessDocumentContext *pView, xiiEngineProcessCommunicationChannel *pIPC, xiiStringView sDocumentType)
 Takes ownership on success. Failure leaves ownership unchanged and rolls back any initialization begun here.
static bool PendingOperationsInProgress ()
static void UpdateDocumentContexts ()
static void FinishFrame ()
 Consumes redraw requests after presentation; thumbnails request another frame on their next tick.
static bool TryGetWindowRedrawState (xiiRegisteredWindowHandle hWindow, bool &out_bRedrawRequested)
 Returns whether a window belongs to document views and combines their presentation requests.
static void DestroyDocumentContext (xiiUuid guid)
static void DestroyAllDocumentContexts ()
 Releases borrowed-world contexts before contexts which own their world.
Static Public Member Functions inherited from xiiNoBase
static const xiiRTTI * GetStaticRTTI ()
Public Attributes inherited from xiiEngineProcessDocumentContext
xiiIPCObjectMirrorEngine m_Mirror
xiiWorldRttiConverterContext m_Context
Protected Attributes inherited from xiiEngineProcessDocumentContext
xiiWorld * m_pWorld = nullptr
xiiBitflags< xiiEngineProcessDocumentContextFlags > m_Flags
xiiUuid m_DocumentGuid
xiiVariant m_MetaData
xiiEngineProcessCommunicationChannel * m_pIPC = nullptr
xiiHybridArray< xiiEngineProcessViewContext *, 4 > m_ViewContexts
xiiMap< xiiUuid, xiiEditorEngineSyncObject * > m_SyncObjects

Detailed Description

Copyright (c) Theophilus Eriata. All Rights Reserved.

Member Function Documentation

◆ CreateViewContext()

xiiEngineProcessViewContext * xiiStateMachineContext::CreateViewContext ( )
overrideprotectedvirtual

Needs to be implemented to create a view context used for windows and thumbnails rendering.

Implements xiiEngineProcessDocumentContext.

◆ DestroyViewContext()

void xiiStateMachineContext::DestroyViewContext ( xiiEngineProcessViewContext * pContext)
overrideprotectedvirtual

Needs to be implemented to destroy the view context created in CreateViewContext.

Implements xiiEngineProcessDocumentContext.

◆ ExportDocument()

xiiStatus xiiStateMachineContext::ExportDocument ( const xiiExportDocumentMsgToEngine * pMsg)
overrideprotectedvirtual

Exports to current document resource to file. Make sure to write xiiAssetFileHeader at the start of it.

Reimplemented from xiiEngineProcessDocumentContext.


The documentation for this class was generated from the following files:
  • /home/runner/work/XII/XII/Source/EditorPlugins/Assets/EnginePluginAssets/StateMachineAsset/StateMachineContext.h
  • /home/runner/work/XII/XII/Source/EditorPlugins/Assets/EnginePluginAssets/StateMachineAsset/StateMachineContext.cpp