Practical Tools for Simple Design
Loading...
Searching...
No Matches
Texture.hpp
1#ifndef CORE_TEXTURE_HPP
2#define CORE_TEXTURE_HPP
3
4#include "pch.hpp" // IWYU pragma: export
5
6namespace Core {
7class Texture {
8public:
9 Texture(GLint format, int width, int height, const void *data);
10 Texture(const Texture &) = delete;
11 Texture(Texture &&texture);
12
13 ~Texture();
14
15 Texture &operator=(const Texture &) = delete;
16 Texture &operator=(Texture &&other);
17
18 GLuint GetTextureId() const { return m_TextureId; }
19
20 void Bind(int slot) const;
21 void Unbind() const;
22
23 void UpdateData(GLint format, int width, int height, const void *data);
24
25private:
26 GLuint m_TextureId;
27};
28} // namespace Core
29
30#endif
Core functionality of the framework
Definition Context.hpp:10