This commit is contained in:
2025-07-16 00:32:40 +02:00
parent d1690192db
commit aaf76a3ff0
41 changed files with 2963 additions and 599 deletions

View File

@@ -0,0 +1,30 @@
#pragma once
#include <td/render/shader/ShaderProgram.h>
namespace td {
namespace shader {
class EntityShader : public ShaderProgram {
private:
unsigned int m_LocationProjectionMatrix = 0;
unsigned int m_LocationViewMatrix = 0;
unsigned int m_LocationPosition = 0;
unsigned int m_LocationColorEffect = 0;
protected:
virtual void GetAllUniformLocation();
public:
EntityShader();
void LoadShader();
void SetColorEffect(const Vec3f& color);
void SetProjectionMatrix(const Mat4f& proj) const;
void SetViewMatrix(const Mat4f& view) const;
void SetModelPos(const Vec3f& pos) const;
};
} // namespace shader
} // namespace td