Текстура для буфера кадра

This commit is contained in:
2022-11-23 14:23:44 +03:00
parent 6de0a3af8d
commit d6c8e22205
2 changed files with 25 additions and 0 deletions

View File

@@ -17,6 +17,7 @@ class Texture
{
public:
Texture(GLuint type = TEX_AVAILABLE_COUNT, const std::string& filename = ""); // Загрузка текстуры с диска или использование "пустой"
Texture(GLuint width, GLuint height, GLuint attachment, GLuint texType = TEX_DIFFUSE, GLint internalformat = GL_RGBA, GLint format = GL_RGBA, GLenum dataType = GL_FLOAT); // Конструктор текстуры заданного размера для использования в буфере
Texture(const Texture& other); // Конструктор копирования
~Texture();
@@ -25,6 +26,7 @@ class Texture
void use(); // Привязка текстуры
static void disable(GLuint type); // Отвязка текстуры по типу
GLuint getType(); // Возвращает тип текстуры
void setType(GLuint type); // Задает тип текстуры
private:
GLuint handler; // Дескриптор текстуры
GLuint type; // Тип текстуры, соответствует её слоту