Radium Engine  1.5.0
Ra::Gui::GizmoManager Class Reference

#include <Gui/Viewer/Gizmo/GizmoManager.hpp>

+ Inheritance diagram for Ra::Gui::GizmoManager:
+ Collaboration diagram for Ra::Gui::GizmoManager:

Public Types

enum  GizmoType { NONE , TRANSLATION , ROTATION , SCALE }
 

Public Slots

void setEditable (const Engine::Scene::ItemEntry &ent) override
 Set the object being currently edited.
 
void cleanup ()
 Destroy all gizmos.
 
void handlePickingResult (int drawableId)
 Callback when a drawable is picked.
 
void setLocal (bool useLocal)
 Change mode from local axis to global.
 
void changeGizmoType (GizmoType type)
 Change gizmo type (rotation or translation)
 
void updateValues () override
 Retrieve the transform from the editable and update the gizmos.
 

Public Member Functions

 GizmoManager (QObject *parent=nullptr)
 
virtual bool handleMousePressEvent (QMouseEvent *event, const Qt::MouseButtons &buttons, const Qt::KeyboardModifiers &modifiers, int key, const Core::Asset::Camera &cam)
 Receive mouse events and transmit them to the gizmos.
 
virtual bool handleMouseReleaseEvent (QMouseEvent *event)
 
virtual bool handleMouseMoveEvent (QMouseEvent *event, const Qt::MouseButtons &buttons, const Qt::KeyboardModifiers &modifiers, int key, const Core::Asset::Camera &cam)
 

Friends

class KeyMappingManageable< GizmoManager >
 

Additional Inherited Members

- Static Public Member Functions inherited from Ra::Gui::KeyMappingManageable< GizmoManager >
static KeyMappingManager::Context getContext ()
 
static void configureKeyMapping ()
 
- Protected Member Functions inherited from Ra::Gui::KeyMappingManageable< GizmoManager >
GizmoManagerself ()
 
- Static Protected Member Functions inherited from Ra::Gui::KeyMappingManageable< GizmoManager >
static void setContext (const KeyMappingManager::Context &c)
 

Detailed Description

This class interfaces the gizmos with the ui commands. It allows to change the gizmo type when editing an editable transform object Note : currently the scale gizmo is not implemented so it will just return a null pointer

Definition at line 23 of file GizmoManager.hpp.

Member Function Documentation

◆ handleMouseMoveEvent()

bool Ra::Gui::GizmoManager::handleMouseMoveEvent ( QMouseEvent *  event,
const Qt::MouseButtons &  buttons,
const Qt::KeyboardModifiers &  modifiers,
int  key,
const Core::Asset::Camera cam 
)
virtual
Todo:
what about if someone start a motion with a key, and then release it while moving the mouse ?

Definition at line 138 of file GizmoManager.cpp.


The documentation for this class was generated from the following files: