Struct Vertex
Defined in File Mesh.hpp
Struct Documentation
-
struct Vertex
All data about a given vertex in a mesh.
Public Functions
-
inline Vertex(const glm::vec3 &position, const glm::vec2 &texCoords = glm::vec2(0.0f), const glm::vec3 &normal = glm::vec3(0.0f), const glm::vec4 &tangent = glm::vec4(0.0f, 0.0f, 0.0f, 1.0f))
Create a new vertex.
- Parameters:
position – The position in local space
texCoords – The texture coordinates (optional, defaults to {0, 0})
normal – The surface normal vector (optional, defaults to {0, 0, 0})
tangent – The surface tangent vector (optional, defaults to {0, 0, 0, 1}), stored as XYZ for vector and W for sign
-
inline Vertex(const glm::vec3 &position, const glm::vec2 &texCoords = glm::vec2(0.0f), const glm::vec3 &normal = glm::vec3(0.0f), const glm::vec4 &tangent = glm::vec4(0.0f, 0.0f, 0.0f, 1.0f))