SceneNode矩阵变换,以及使用PushConstants传递LocalToWorld绘制成功

This commit is contained in:
2019-05-29 21:48:56 +08:00
parent 3155234629
commit c4c63a7add
19 changed files with 164 additions and 161 deletions

View File

@@ -3,6 +3,7 @@
//#include<hgl/type/List.h>
#include<hgl/math/Math.h>
#include<hgl/graph/vulkan/VK.h>
//#include<hgl/graph/Transform.h>
namespace hgl
{
@@ -23,11 +24,15 @@ namespace hgl
Matrix4f InverseLocalMatrix; ///<反向当前矩阵
Matrix4f InverseLocalToWorldMatrix; ///<反向当前到世界矩阵
vulkan::PushConstant pc;
public:
SceneOrient();
virtual ~SceneOrient()=default;
vulkan::PushConstant *GetPushConstant(){return &pc;}
Matrix4f & SetLocalMatrix (const Matrix4f &); ///<设定当前节点矩阵
Matrix4f & SetLocalToWorldMatrix (const Matrix4f &); ///<设定当前节点到世界矩阵