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

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

#include <SceneViewWidget.moc.h>

Inheritance diagram for xiiQtSceneViewWidget:
[legend]

Public Member Functions

 xiiQtSceneViewWidget (QWidget *pParent, xiiQtGameObjectDocumentWindow *pOwnerWindow, xiiEngineViewConfig *pViewConfig)
virtual bool IsPickingAgainstSelectionAllowed () const override
 Disabled during drag&drop operations, to prevent picking against the dragged object.
Public Member Functions inherited from xiiQtGameObjectViewWidget
 xiiQtGameObjectViewWidget (QWidget *pParent, xiiQtGameObjectDocumentWindow *pOwnerWindow, xiiEngineViewConfig *pViewConfig)
 Copyright (c) Theophilus Eriata. All Rights Reserved.
virtual void SyncToEngine () override
 Sends the redraw message to the engine.
Public Member Functions inherited from xiiQtEngineViewWidget
 xiiQtEngineViewWidget (QWidget *pParent, xiiQtEngineDocumentWindow *pDocumentWindow, xiiEngineViewConfig *pViewConfig)
xiiUInt32 GetViewID () const
 Returns the ID of this view.
xiiQtEngineDocumentWindow * GetDocumentWindow () const
void GetCameraMatrices (xiiMat4 &out_mViewMatrix, xiiMat4 &out_mProjectionMatrix) const
void UpdateCameraInterpolation ()
 Called every frame to move the camera to its current target (focus on selection, etc.).
void InterpolateCameraTo (const xiiVec3 &vPosition, const xiiVec3 &vDirection, float fFovOrDim, const xiiVec3 *pNewUpDirection=nullptr, bool bImmediate=false)
 The view's camera will be interpolated to the given coordinates.
void SetEnablePicking (bool bEnable)
void SetPickTransparent (bool bEnable)
void OpenContextMenu (QPoint globalPos)
 Supposed to open a context menu at the given position. Derived classes must implement OnOpenContextMenu and do the actual work there.
const xiiObjectPickingResult & PickObject (xiiUInt16 uiScreenPosX, xiiUInt16 uiScreenPosY) const
 Starts a picking operation for the given pixel position in this view. Returns the most recent picking information in the meantime.
xiiResult PickPlane (xiiUInt16 uiScreenPosX, xiiUInt16 uiScreenPosY, const xiiPlane &plane, xiiVec3 &out_vPosition) const
 Similar to PickObject, but computes the intersection with the given plane instead.
void HandleViewMessage (const xiiEditorEngineViewMsg *pMsg)
 Processes incoming messages from the engine that are meant for this particular view. Mostly picking results.
virtual xiiPlane GetFallbackPickingPlane (xiiVec3 vPointOnPlane=xiiVec3(0)) const
void TakeScreenshot (xiiStringView sOutputPath) const

Protected Member Functions

virtual void dragEnterEvent (QDragEnterEvent *e) override
virtual void dragLeaveEvent (QDragLeaveEvent *e) override
virtual void dragMoveEvent (QDragMoveEvent *e) override
virtual void dropEvent (QDropEvent *e) override
virtual void OnOpenContextMenu (QPoint globalPos) override
Protected Member Functions inherited from xiiQtGameObjectViewWidget
virtual void HandleMarqueePickingResult (const xiiViewMarqueePickingResultMsgToEditor *pMsg) override
Protected Member Functions inherited from xiiQtEngineViewWidget
virtual bool eventFilter (QObject *object, QEvent *event) override
 Used to deactivate shortcuts.
virtual void paintEvent (QPaintEvent *event) override
virtual QPaintEngine * paintEngine () const override
virtual void resizeEvent (QResizeEvent *event) override
virtual void keyPressEvent (QKeyEvent *e) override
virtual void keyReleaseEvent (QKeyEvent *e) override
virtual void mousePressEvent (QMouseEvent *e) override
virtual void mouseReleaseEvent (QMouseEvent *e) override
virtual void mouseMoveEvent (QMouseEvent *e) override
virtual void wheelEvent (QWheelEvent *e) override
virtual void focusOutEvent (QFocusEvent *e) override
void EngineViewProcessEventHandler (const xiiEditorEngineProcessConnection::Event &e)
void ShowRestartButton (bool bShow)
void RecreateEngineViewport ()

Protected Attributes

bool m_bAllowPickSelectedWhileDragging
xiiTime m_LastDragMoveEvent
Protected Attributes inherited from xiiQtGameObjectViewWidget
xiiUInt32 m_uiLastMarqueeActionID = 0
xiiDeque< xiiUuid > m_MarqueeBaseSelection
Protected Attributes inherited from xiiQtEngineViewWidget
bool m_bUpdatePickingData
bool m_bPickTransparent = true
bool m_bInDragAndDropOperation
xiiUInt32 m_uiViewID
xiiQtEngineDocumentWindow * m_pDocumentWindow = nullptr
float m_fCameraLerp
float m_fCameraStartFovOrDim
float m_fCameraTargetFovOrDim
xiiVec3 m_vCameraStartPosition
xiiVec3 m_vCameraTargetPosition
xiiVec3 m_vCameraStartDirection
xiiVec3 m_vCameraTargetDirection
xiiVec3 m_vCameraUp
xiiTime m_LastCameraUpdate
QHBoxLayout * m_pMainLayout = nullptr
QPushButton * m_pRestartButton = nullptr
QWidget * m_pViewportWidget = nullptr
xiiObjectPickingResult m_LastPickingResult

Static Protected Attributes

static bool s_bContextMenuInitialized = false
 Copyright (c) Theophilus Eriata. All Rights Reserved.
Static Protected Attributes inherited from xiiQtEngineViewWidget
static xiiUInt32 s_uiNextViewID = 0
 Copyright (c) Theophilus Eriata. All Rights Reserved.
static InteractionContext s_InteractionContext

Additional Inherited Members

Static Public Member Functions inherited from xiiQtEngineViewWidget
static const InteractionContext & GetInteractionContext ()
 Returns the latest information about what viewport the user interacted with.
static void SetInteractionContext (const InteractionContext &ctxt)
 Overrides the InteractionContext with custom values. Mostly useful for injecting procedural user interaction for unit tests.
Public Attributes inherited from xiiQtGameObjectViewWidget
xiiOrthoGizmoContext * m_pOrthoGizmoContext
xiiSelectionContext * m_pSelectionContext
xiiCameraMoveContext * m_pCameraMoveContext
Public Attributes inherited from xiiQtEngineViewWidget
xiiHybridArray< xiiEditorInputContext *, 8 > m_InputContexts
 Add input contexts in the order in which they are supposed to be processed.
xiiEngineViewConfig * m_pViewConfig
Static Public Attributes inherited from xiiQtEngineViewWidget
static xiiSizeU32 s_FixedResolution

Detailed Description

Copyright (c) Theophilus Eriata. All Rights Reserved.

Member Function Documentation

◆ dragEnterEvent()

void xiiQtSceneViewWidget::dragEnterEvent ( QDragEnterEvent * e)
overrideprotectedvirtual

Reimplemented from xiiQtEngineViewWidget.

◆ dragLeaveEvent()

void xiiQtSceneViewWidget::dragLeaveEvent ( QDragLeaveEvent * e)
overrideprotectedvirtual

Reimplemented from xiiQtEngineViewWidget.

◆ dropEvent()

void xiiQtSceneViewWidget::dropEvent ( QDropEvent * e)
overrideprotectedvirtual

Reimplemented from xiiQtEngineViewWidget.

◆ IsPickingAgainstSelectionAllowed()

bool xiiQtSceneViewWidget::IsPickingAgainstSelectionAllowed ( ) const
overridevirtual

Disabled during drag&drop operations, to prevent picking against the dragged object.

Reimplemented from xiiQtEngineViewWidget.

◆ OnOpenContextMenu()

void xiiQtSceneViewWidget::OnOpenContextMenu ( QPoint globalPos)
overrideprotectedvirtual

Reimplemented from xiiQtEngineViewWidget.


The documentation for this class was generated from the following files:
  • /home/runner/work/XII/XII/Source/EditorPlugins/Scene/EditorPluginScene/Scene/SceneViewWidget.moc.h
  • /home/runner/work/XII/XII/Source/EditorPlugins/Scene/EditorPluginScene/Scene/SceneViewWidget.cpp