Gems/EMotionFX

Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>
This commit is contained in:
Esteban Papp
2021-09-10 20:18:05 -07:00
parent 48652dcac7
commit 0800e95aa7
12 changed files with 26 additions and 26 deletions
@@ -290,7 +290,7 @@ namespace EMStudio
/// CommandManagerCallback implementation
void OnPreExecuteCommand(MCore::CommandGroup* group, MCore::Command* command, const MCore::CommandLine& commandLine) override;
void OnPostExecuteCommand(MCore::CommandGroup* /*group*/, MCore::Command* /*command*/, const MCore::CommandLine& /*commandLine*/, bool /*wasSuccess*/, const AZStd::string& /*outResult*/) override { }
void OnPreUndoCommand(MCore::Command* command, const MCore::CommandLine& commandLine);
void OnPreUndoCommand(MCore::Command* command, const MCore::CommandLine& commandLine) override;
void OnPreExecuteCommandGroup(MCore::CommandGroup* /*group*/, bool /*undo*/) override { }
void OnPostExecuteCommandGroup(MCore::CommandGroup* /*group*/, bool /*wasSuccess*/) override { }
void OnAddCommandToHistory(size_t /*historyIndex*/, MCore::CommandGroup* /*group*/, MCore::Command* /*command*/, const MCore::CommandLine& /*commandLine*/) override { }
@@ -95,7 +95,7 @@ namespace EMStudio
virtual bool CreateEMStudioActor(EMotionFX::Actor* actor) = 0;
// SkeletonOutlinerNotificationBus
void ZoomToJoints(EMotionFX::ActorInstance* actorInstance, const AZStd::vector<EMotionFX::Node*>& joints);
void ZoomToJoints(EMotionFX::ActorInstance* actorInstance, const AZStd::vector<EMotionFX::Node*>& joints) override;
// ActorNotificationBus
void OnActorReady(EMotionFX::Actor* actor) override;
@@ -81,8 +81,8 @@ namespace EMStudio
// overloaded
const AZStd::vector<EMotionFX::EventTypes> GetHandledEventTypes() const override { return { EMotionFX::EVENT_TYPE_ON_DRAW_LINE, EMotionFX::EVENT_TYPE_ON_DRAW_TRIANGLE, EMotionFX::EVENT_TYPE_ON_DRAW_TRIANGLES }; }
MCORE_INLINE void OnDrawTriangle(const AZ::Vector3& posA, const AZ::Vector3& posB, const AZ::Vector3& posC, const AZ::Vector3& normalA, const AZ::Vector3& normalB, const AZ::Vector3& normalC, uint32 color) { m_widget->AddTriangle(posA, posB, posC, normalA, normalB, normalC, color); }
MCORE_INLINE void OnDrawTriangles() { m_widget->RenderTriangles(); }
MCORE_INLINE void OnDrawTriangle(const AZ::Vector3& posA, const AZ::Vector3& posB, const AZ::Vector3& posC, const AZ::Vector3& normalA, const AZ::Vector3& normalB, const AZ::Vector3& normalC, uint32 color) override { m_widget->AddTriangle(posA, posB, posC, normalA, normalB, normalC, color); }
MCORE_INLINE void OnDrawTriangles() override { m_widget->RenderTriangles(); }
private:
RenderWidget* m_widget;
@@ -53,7 +53,7 @@ namespace EMStudio
void initializeGL() override;
void paintGL() override;
void resizeGL(int width, int height);
void resizeGL(int width, int height) override;
private slots:
void CloneSelectedActorInstances() { CommandSystem::CloneSelectedActorInstances(); }
@@ -64,16 +64,16 @@ namespace EMStudio
void ResetToBindPose() { CommandSystem::ResetToBindPose(); }
protected:
void mouseMoveEvent(QMouseEvent* event) { RenderWidget::OnMouseMoveEvent(this, event); }
void mousePressEvent(QMouseEvent* event) { RenderWidget::OnMousePressEvent(this, event); }
void mouseReleaseEvent(QMouseEvent* event) { RenderWidget::OnMouseReleaseEvent(this, event); }
void wheelEvent(QWheelEvent* event) { RenderWidget::OnWheelEvent(this, event); }
void mouseMoveEvent(QMouseEvent* event) override { RenderWidget::OnMouseMoveEvent(this, event); }
void mousePressEvent(QMouseEvent* event) override { RenderWidget::OnMousePressEvent(this, event); }
void mouseReleaseEvent(QMouseEvent* event) override { RenderWidget::OnMouseReleaseEvent(this, event); }
void wheelEvent(QWheelEvent* event) override { RenderWidget::OnWheelEvent(this, event); }
void focusInEvent(QFocusEvent* event);
void focusOutEvent(QFocusEvent* event);
void focusInEvent(QFocusEvent* event) override;
void focusOutEvent(QFocusEvent* event) override;
void Render();
void Update() { update(); }
void Render() override;
void Update() override { update(); }
void RenderBorder(const MCore::RGBAColor& color);
RenderGL::GBuffer m_gBuffer;
@@ -43,8 +43,8 @@ namespace EMStudio
bool GetIsVertical() const override { return false; }
// overloaded main init function
bool Init();
EMStudioPlugin* Clone() { return new OpenGLRenderPlugin(); }
bool Init() override;
EMStudioPlugin* Clone() override { return new OpenGLRenderPlugin(); }
// overloaded functions
void CreateRenderWidget(RenderViewWidget* renderViewWidget, RenderWidget** outRenderWidget, QWidget** outWidget) override;
@@ -57,7 +57,7 @@ namespace EMStudio
RenderGL::GraphicsManager* m_graphicsManager; // shared OpenGL engine object
// overloaded emstudio actor create function which creates an OpenGL render actor internally
bool CreateEMStudioActor(EMotionFX::Actor* actor);
bool CreateEMStudioActor(EMotionFX::Actor* actor) override;
void RenderActorInstance(EMotionFX::ActorInstance* actorInstance, float timePassedInSeconds) override;
};
@@ -28,7 +28,7 @@ namespace EMStudio
void paint(QPainter* painter, const QStyleOptionViewItem& option, const QModelIndex& index) const override;
QSize sizeHint(const QStyleOptionViewItem& option, const QModelIndex& index) const override;
void setModelData(QWidget* editor, QAbstractItemModel* model, const QModelIndex& index) const;
void setModelData(QWidget* editor, QAbstractItemModel* model, const QModelIndex& index) const override;
signals:
void linkActivated(const QString& link);
@@ -152,7 +152,7 @@ namespace EMStudio
void OnDataChanged(const QModelIndex& topLeft, const QModelIndex& bottomRight, const QVector<int>& roles);
private:
AddConditionButton* m_addConditionButton = nullptr;
void contextMenuEvent(QContextMenuEvent* event);
void contextMenuEvent(QContextMenuEvent* event) override;
void PasteTransition(bool pasteTransitionProperties, bool pasteConditions);
@@ -34,11 +34,11 @@ namespace EMStudio
~BlendTreeVisualNode();
void Sync() override;
uint32 GetType() const { return BlendTreeVisualNode::TYPE_ID; }
uint32 GetType() const override { return BlendTreeVisualNode::TYPE_ID; }
void Render(QPainter& painter, QPen* pen, bool renderShadow) override;
int32 CalcRequiredHeight() const;
int32 CalcRequiredHeight() const override;
private:
QColor GetPortColor(const EMotionFX::AnimGraphNode::Port& port) const;
@@ -70,8 +70,8 @@ namespace EMStudio
void NameEdited(const QString& text);
void EnabledCheckBoxChanged(int state);
void keyPressEvent(QKeyEvent* event);
void keyReleaseEvent(QKeyEvent* event);
void keyPressEvent(QKeyEvent* event) override;
void keyReleaseEvent(QKeyEvent* event) override;
};
/**
@@ -110,7 +110,7 @@ namespace EMotionFX
#if defined (EMOTIONFXANIMATION_EDITOR)
void UpdateAnimationEditorPlugins(float delta);
void NotifyRegisterViews() override;
bool IsSystemActive(EditorAnimationSystemRequests::AnimationSystem systemType);
bool IsSystemActive(EditorAnimationSystemRequests::AnimationSystem systemType) override;
//////////////////////////////////////////////////////////////////////////////////////
// AzToolsFramework::AssetBrowser::AssetBrowserInteractionNotificationBus::Handler
@@ -62,14 +62,14 @@ namespace EMotionFX
m_motionNodeAnimGraph->InitAfterLoading();
}
void SetUp()
void SetUp() override
{
AnimGraphFixture::SetUp();
m_animGraphInstance->Destroy();
m_animGraphInstance = m_motionNodeAnimGraph->GetAnimGraphInstance(m_actorInstance, m_motionSet);
}
void TearDown()
void TearDown() override
{
AnimGraphFixture::TearDown();
}
@@ -122,7 +122,7 @@ namespace EMotionFX
{
}
virtual const AZStd::vector<EventTypes> GetHandledEventTypes() const
const AZStd::vector<EventTypes> GetHandledEventTypes() const override
{
return { EVENT_TYPE_ON_EVENT };
}