#include <node.h>
Classes | |
class | MutationLog |
Public Member Functions | |
Node () | |
~Node () | |
const std::string & | GetName () const |
void | SetName (const std::string &new_name) |
Node * | GetParent () const |
std::shared_ptr< Node > | FindChildByName (const std::string &name, bool exclude_animation_players=false) const |
std::shared_ptr< Animation > | FindAnimationByName (const std::string &name) const |
AnimationClip * | AddAnimation (const std::shared_ptr< Animation > &animation) |
void | SetLocalTransform (Matrix transform) |
Matrix | GetLocalTransform () const |
void | SetGlobalTransform (Matrix transform) |
Matrix | GetGlobalTransform () const |
bool | AddChild (std::shared_ptr< Node > child) |
std::vector< std::shared_ptr< Node > > & | GetChildren () |
void | SetMesh (Mesh mesh) |
Mesh & | GetMesh () |
void | SetIsJoint (bool is_joint) |
bool | IsJoint () const |
bool | Render (SceneEncoder &encoder, Allocator &allocator, const Matrix &parent_transform) |
void | AddMutation (const MutationLog::Entry &entry) |
Static Public Member Functions | |
static std::shared_ptr< Node > | MakeFromFlatbuffer (const fml::Mapping &ipscene_mapping, Allocator &allocator) |
static std::shared_ptr< Node > | MakeFromFlatbuffer (const fb::Scene &scene, Allocator &allocator) |
|
default |
AnimationClip * impeller::scene::Node::AddAnimation | ( | const std::shared_ptr< Animation > & | animation | ) |
bool impeller::scene::Node::AddChild | ( | std::shared_ptr< Node > | child | ) |
Definition at line 300 of file node.cc.
References VALIDATION_LOG.
Referenced by impeller::SceneContents::Render().
void impeller::scene::Node::AddMutation | ( | const MutationLog::Entry & | entry | ) |
Definition at line 412 of file node.cc.
References impeller::scene::Node::MutationLog::Append().
std::shared_ptr< Animation > impeller::scene::Node::FindAnimationByName | ( | const std::string & | name | ) | const |
std::shared_ptr< Node > impeller::scene::Node::FindChildByName | ( | const std::string & | name, |
bool | exclude_animation_players = false |
||
) | const |
std::vector< std::shared_ptr< Node > > & impeller::scene::Node::GetChildren | ( | ) |
Definition at line 325 of file node.cc.
Referenced by impeller::scene::testing::TEST_P().
Matrix impeller::scene::Node::GetGlobalTransform | ( | ) | const |
Definition at line 293 of file node.cc.
References GetGlobalTransform().
Referenced by GetGlobalTransform(), and SetGlobalTransform().
Matrix impeller::scene::Node::GetLocalTransform | ( | ) | const |
Definition at line 282 of file node.cc.
Referenced by impeller::scene::Skin::GetJointsTexture(), and impeller::scene::testing::TEST_P().
Mesh & impeller::scene::Node::GetMesh | ( | ) |
const std::string & impeller::scene::Node::GetName | ( | ) | const |
Node * impeller::scene::Node::GetParent | ( | ) | const |
Definition at line 240 of file node.cc.
Referenced by impeller::scene::Skin::GetJointsTexture().
bool impeller::scene::Node::IsJoint | ( | ) | const |
Definition at line 341 of file node.cc.
Referenced by impeller::scene::Skin::GetJointsTexture().
|
static |
Definition at line 126 of file node.cc.
References impeller::scene::Animation::MakeFromFlatbuffer(), textures, impeller::scene::importer::ToMatrix(), impeller::scene::UnpackTextureFromFlatbuffer(), and VALIDATION_LOG.
|
static |
Definition at line 47 of file node.cc.
References VALIDATION_LOG.
Referenced by impeller::scene::testing::TEST_P().
bool impeller::scene::Node::Render | ( | SceneEncoder & | encoder, |
Allocator & | allocator, | ||
const Matrix & | parent_transform | ||
) |
Definition at line 345 of file node.cc.
References AddAnimation(), FindAnimationByName(), impeller::scene::Mesh::Render(), impeller::scene::AnimationClip::Seek(), impeller::scene::AnimationClip::SetLoop(), impeller::scene::AnimationClip::SetPlaybackTimeScale(), impeller::scene::AnimationClip::SetPlaying(), and impeller::scene::AnimationClip::SetWeight().
Referenced by impeller::scene::Scene::Render().
void impeller::scene::Node::SetGlobalTransform | ( | Matrix | transform | ) |
Definition at line 286 of file node.cc.
References GetGlobalTransform(), and impeller::Matrix::Invert().
void impeller::scene::Node::SetIsJoint | ( | bool | is_joint | ) |
void impeller::scene::Node::SetLocalTransform | ( | Matrix | transform | ) |
Definition at line 278 of file node.cc.
Referenced by impeller::scene::testing::TEST_P().
void impeller::scene::Node::SetMesh | ( | Mesh | mesh | ) |
Definition at line 329 of file node.cc.
Referenced by impeller::scene::testing::TEST_P().
void impeller::scene::Node::SetName | ( | const std::string & | new_name | ) |