renamed the name from "WorldMatrix" to "CameraMatrix"

This commit is contained in:
2021-01-25 12:03:17 +08:00
parent 15f475fba1
commit ee35354d43
22 changed files with 70 additions and 70 deletions

View File

@@ -300,7 +300,7 @@ class CameraAppFramework:public VulkanApplicationFramework
{
private:
GPUBuffer * ubo_world_matrix =nullptr;
GPUBuffer * ubo_camera_matrix =nullptr;
protected:
@@ -340,7 +340,7 @@ public:
camera->Refresh(); //更新矩阵计算
ubo_world_matrix=db->CreateUBO(sizeof(WorldMatrix),&camera->matrix);
ubo_camera_matrix=db->CreateUBO(sizeof(CameraMatrix),&camera->matrix);
}
void Resize(int w,int h)override
@@ -351,7 +351,7 @@ public:
GPUBuffer *GetCameraMatrixBuffer()
{
return ubo_world_matrix;
return ubo_camera_matrix;
}
virtual void BuildCommandBuffer(uint32_t index)=0;
@@ -359,7 +359,7 @@ public:
virtual void Draw()override
{
camera->Refresh(); //更新相机矩阵
ubo_world_matrix->Write(&camera->matrix); //写入缓冲区
ubo_camera_matrix->Write(&camera->matrix); //写入缓冲区
const uint32_t index=AcquireNextImage();