6 #include <glm/gtc/type_ptr.hpp> 7 #include <assimp/Importer.hpp> 8 #include <assimp/postprocess.h> 9 #include <assimp/scene.h> 11 #include "sceneobject.hpp" 14 #include "texture.hpp" 22 Geometry(
const glm::mat4 &matrix_,
const std::string &filePath);
31 virtual void draw(
Shader *shader,
Camera *camera,
bool useFrustumCulling, Texture::FilterType filterType,
const glm::mat4 &viewMat);
55 std::vector<std::shared_ptr<Surface>> surfaces;
58 std::string directoryPath;
61 static std::vector<std::shared_ptr<Texture>> loadedTextures;
68 const std::string &filePath
90 std::shared_ptr<Texture> loadMaterialTexture(
glm::vec3 getBBMax()
Returns max vertex of axis-aligned bounding box enclosing all surfaces.
Definition: geometry.cpp:29
virtual void update(float timeDelta)
Update the state of the SceneObject.
Definition: geometry.cpp:34
glm::vec3 getBBMin()
Returns min vertex of axis-aligned bounding box enclosing all surfaces.
Definition: geometry.cpp:24
glm::mat3 getNormalMatrix() const
return a the transposed inverse of the modelMatrix.
Definition: geometry.cpp:19
Shader class.
Definition: shader.h:15
A SceneObject that holds Surfaces containing mesh data and textures.
Definition: geometry.h:19
static int drawnSurfaceCount
The number of surfaces being drawn.
Definition: geometry.h:52
virtual void draw(Shader *shader, Camera *camera, bool useFrustumCulling, Texture::FilterType filterType, const glm::mat4 &viewMat)
draw the SceneObject using given shader
Definition: geometry.cpp:37
A base class for all scene objects.
Definition: sceneobject.hpp:15
A Camera is a SceneObject that maintains a view matrix, as well as parameters defining the projection...
Definition: camera.h:20