Brenta Engine 1.1
Loading...
Searching...
No Matches
brenta::model Class Reference

Model class. More...

#include <model.hpp>

Data Structures

class  builder
 Builder class for Model. More...
 

Public Member Functions

 model ()
 Empty constructor.
 
 model (std::string const &path, GLint wrapping=GL_REPEAT, GLint filtering_min=GL_NEAREST, GLint filtering_mag=GL_LINEAR, GLboolean has_mipmap=GL_TRUE, GLint mipmap_min=GL_LINEAR_MIPMAP_LINEAR, GLint mipmap_mag=GL_LINEAR, bool flip=true)
 Construct a new Model object.
 
void draw (types::shader_name_t shader)
 Draw the model.
 

Data Fields

GLint wrapping
 Texture wrapping mode.
 
GLint filtering_min
 Texture filtering mode.
 
GLint filtering_mag
 Texture filtering mode.
 
GLboolean has_mipmap
 If the texture has a mipmap.
 
GLint mipmap_min
 Mipmap filtering mode.
 
GLint mipmap_mag
 Mipmap filtering mode.
 
bool flip
 If the texture should be flipped.
 

Detailed Description

Model class.

This class is used to load a model from a file and draw it

Definition at line 47 of file model.hpp.

Constructor & Destructor Documentation

◆ model() [1/2]

brenta::model::model ( )
inline

Empty constructor.

Does nothing

Definition at line 96 of file model.hpp.

◆ model() [2/2]

model::model ( std::string const & path,
GLint wrapping = GL_REPEAT,
GLint filtering_min = GL_NEAREST,
GLint filtering_mag = GL_LINEAR,
GLboolean has_mipmap = GL_TRUE,
GLint mipmap_min = GL_LINEAR_MIPMAP_LINEAR,
GLint mipmap_mag = GL_LINEAR,
bool flip = true )

Construct a new Model object.

Parameters
pathPath to the model
wrappingTexture wrapping mode
filtering_minTexture filtering mode
filtering_magTexture filtering mode
hasMipmapIf the texture has a mipmap
mipmap_minMipmap filtering mode
mipmap_magMipmap filtering mode
flipIf the texture should be flipped

Definition at line 35 of file model.cpp.

Member Function Documentation

◆ draw()

void model::draw ( types::shader_name_t shader)

Draw the model.

Parameters
shaderShader to use

Definition at line 49 of file model.cpp.

Field Documentation

◆ filtering_mag

GLint brenta::model::filtering_mag

Texture filtering mode.

Check Mesh for more information

Definition at line 67 of file model.hpp.

◆ filtering_min

GLint brenta::model::filtering_min

Texture filtering mode.

Check Mesh for more information

Definition at line 61 of file model.hpp.

◆ flip

bool brenta::model::flip

If the texture should be flipped.

Definition at line 89 of file model.hpp.

◆ has_mipmap

GLboolean brenta::model::has_mipmap

If the texture has a mipmap.

Check Mesh for more information

Definition at line 73 of file model.hpp.

◆ mipmap_mag

GLint brenta::model::mipmap_mag

Mipmap filtering mode.

Check Mesh for more information

Definition at line 85 of file model.hpp.

◆ mipmap_min

GLint brenta::model::mipmap_min

Mipmap filtering mode.

Check Mesh for more information

Definition at line 79 of file model.hpp.

◆ wrapping

GLint brenta::model::wrapping

Texture wrapping mode.

Check Mesh for more information

Definition at line 55 of file model.hpp.


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