Vivid
Loading...
Searching...
No Matches
VertexBuffer.h
1#pragma once
2
3#include "common/maths/Vec.h"
4#include "common/types/Types.h"
5#include "common/types/SmartPointers.h"
6#include "glm/glm/glm.hpp"
7#include "common/maths/Vec.h"
8
9namespace Vivid
10{
11
17 struct Vertex
18 {
19 Maths::Vec3 position;
20 Maths::Vec2 texcoord;
21 Maths::Vec3 normal;
22 Maths::Vec3 tangent;
23 };
24
31 {
32 private:
33 unsigned int m_RendererID;
34
35 public:
36 VertexBuffer(std::vector<Vertex>& vertices);
37
38 static Ref<VertexBuffer> Create(std::vector<Vertex>& vertices);
39
41
42 void Bind(const std::vector<Vertex>& vertices) const;
43
44 void Unbind() const;
45 };
46}
A class for the VertexBuffer.
Definition: VertexBuffer.h:31
Contains a 2D vector.
Definition: Vec.h:108
Contains a 3D vector.
Definition: Vec.h:51
A struct for the Vertex.
Definition: VertexBuffer.h:18