X-Git-Url: http://git.localhorst.tv/?a=blobdiff_plain;f=src%2Fmodel%2Fmodel.cpp;h=cad62ac2ec0cea30c99e39685adbef0729b6f3a8;hb=b9a63fedbc65e8659c43f7fa381017c0c70a48da;hp=55050e0b72d856ce57894787705c0630cbc981a3;hpb=9c5308ba4108bd842af6d9d2e893ea575a7e6ca8;p=blank.git diff --git a/src/model/model.cpp b/src/model/model.cpp index 55050e0..cad62ac 100644 --- a/src/model/model.cpp +++ b/src/model/model.cpp @@ -27,6 +27,14 @@ Instance::~Instance() { } +Part::State &Instance::EyesState() noexcept { + return state[model->GetEyesPart().ID()]; +} + +glm::mat4 Instance::EyesTransform() const noexcept { + return model->GetEyesPart().GlobalTransform(*this); +} + void Instance::Render(const glm::mat4 &M, DirectionalLighting &prog) { model->RootPart().Render(M, *this, prog); } @@ -35,7 +43,8 @@ void Instance::Render(const glm::mat4 &M, DirectionalLighting &prog) { Model::Model() : id(0) , root() -, part() { +, part() +, eyes_id(0) { }