24#include <glm/vec2.hpp>
25#include <glm/vec3.hpp>
61 for (
auto& texture :
height) {
80 for (
auto& model_mesh :
meshes) {
84 auto& material =
materials[model_mesh->material];
86 shader->
setVec3(
"diffuse", material.base_diffuse);
98 glm::vec3
normal = glm::vec3(0.f, 0.f, 0.f);
The base class for assets.
Definition: asset.h:157
A shader program.
Definition: shader.h:68
void setVec3(const std::string &name, const glm::vec3 &value)
Definition: shader.cpp:95
AssetType
Definition: asset.h:31
@ MODEL
Model prototype.
Definition: assetprototype.h:30
std::shared_ptr< ModelMesh > ModelMesh_t
Definition: model.h:71
glm::vec3 base_specular
Definition: model.h:45
std::vector< asset::Texture * > ambient
Definition: model.h:42
std::vector< asset::Texture * > specular
Definition: model.h:41
~Material()
Definition: model.h:51
glm::vec3 base_ambient
Definition: model.h:46
glm::vec3 base_transparent
Definition: model.h:48
std::vector< asset::Texture * > height
Definition: model.h:43
glm::vec3 base_diffuse
Definition: model.h:44
std::vector< asset::Texture * > diffuse
Definition: model.h:40
glm::vec3 base_emissive
Definition: model.h:47
asset::Texture * ambient
Definition: model.h:35
asset::Texture * specular
Definition: model.h:34
asset::Texture * diffuse
Definition: model.h:33
asset::Texture * height
Definition: model.h:36
AssetType GetAssetType() override
Definition: model.h:77
std::map< int, Material > materials
Definition: model.h:75
std::vector< ModelMesh_t > meshes
Definition: model.h:74
void Draw(ShaderProgram *shader)
Definition: model.h:79
int material
Definition: model.h:68
glm::vec2 texCoords
Definition: model.h:100
glm::vec3 normal
Definition: model.h:98
glm::vec3 position
Definition: model.h:96
glm::vec3 bitangent
Definition: model.h:104
static const int MAX_BONE_INFLUENCE
Definition: model.h:94
int m_BoneIDs[MAX_BONE_INFLUENCE]
Definition: model.h:106
float m_Weights[MAX_BONE_INFLUENCE]
Definition: model.h:108
glm::vec3 tangent
Definition: model.h:102