jGL
Loading...
Searching...
No Matches
Public Member Functions | List of all members
jGL::GL::glTexture2DByte Class Reference

#include <glTexture.h>

Inheritance diagram for jGL::GL::glTexture2DByte:
Inheritance graph
[legend]
Collaboration diagram for jGL::GL::glTexture2DByte:
Collaboration graph
[legend]

Public Member Functions

 glTexture2DByte (std::filesystem::path imageFile)
 
 glTexture2DByte (std::vector< std::byte > data)
 
 glTexture2DByte (std::vector< std::byte > pixels, int width, int height)
 
void create (int width, int height)
 
void upload (std::vector< std::byte > pixels)
 
- Public Member Functions inherited from jGL::GL::glTexture
 glTexture ()
 
 ~glTexture ()
 
virtual void upload (std::vector< std::byte > *data)
 
void bind ()
 
void unbind ()
 
void bind (unsigned binding)
 
void generateMipMaps ()
 
- Public Member Functions inherited from jGL::Texture
 Texture ()
 
virtual ~Texture ()=default
 
bool operator== (const Texture &rhs) const
 
const IdgetId () const
 
const glm::ivec3 size () const
 

Additional Inherited Members

- Public Types inherited from jGL::Texture
enum class  Type { RGB , RGBA }
 
- Protected Member Functions inherited from jGL::GL::glTexture
std::vector< std::byte > load_image (std::filesystem::path imageFilePath)
 
std::vector< std::byte > load_image (std::vector< std::byte > imageFile)
 
- Protected Attributes inherited from jGL::GL::glTexture
GLuint id
 
unsigned textureUnit
 
- Protected Attributes inherited from jGL::Texture
int width
 
int height
 
int channels
 
Id id
 

Constructor & Destructor Documentation

◆ glTexture2DByte() [1/3]

jGL::GL::glTexture2DByte::glTexture2DByte ( std::filesystem::path  imageFile)
inline

◆ glTexture2DByte() [2/3]

jGL::GL::glTexture2DByte::glTexture2DByte ( std::vector< std::byte >  data)
inline

◆ glTexture2DByte() [3/3]

jGL::GL::glTexture2DByte::glTexture2DByte ( std::vector< std::byte >  pixels,
int  width,
int  height 
)
inline

Member Function Documentation

◆ create()

void jGL::GL::glTexture2DByte::create ( int  width,
int  height 
)

◆ upload()

void jGL::GL::glTexture2DByte::upload ( std::vector< std::byte >  pixels)

The documentation for this class was generated from the following files: