2014-02-10 05:43:20 +00:00
|
|
|
#pragma once
|
|
|
|
#ifndef _DRAWBUFFER_HPP_
|
|
|
|
#define _DRAWBUFFER_HPP_
|
2016-04-07 01:13:46 +01:00
|
|
|
#include <gl/gl_core_3_3.h>
|
2014-02-10 05:43:20 +00:00
|
|
|
|
|
|
|
class GeometryBuffer;
|
2014-02-13 10:55:11 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* DrawBuffer stores VAO state
|
|
|
|
*/
|
2014-02-10 05:43:20 +00:00
|
|
|
class DrawBuffer {
|
|
|
|
GLuint vao;
|
|
|
|
|
2014-02-10 08:55:01 +00:00
|
|
|
GLenum facetype;
|
2014-02-10 05:43:20 +00:00
|
|
|
public:
|
|
|
|
|
|
|
|
DrawBuffer();
|
|
|
|
~DrawBuffer();
|
|
|
|
|
|
|
|
GLuint getVAOName() const
|
|
|
|
{ return vao; }
|
|
|
|
|
2014-02-10 08:55:01 +00:00
|
|
|
void setFaceType(GLenum ft)
|
|
|
|
{ facetype = ft; }
|
|
|
|
|
|
|
|
GLenum getFaceType() const
|
|
|
|
{ return facetype; }
|
|
|
|
|
2014-02-10 05:43:20 +00:00
|
|
|
/**
|
|
|
|
* Adds a Geometry Buffer to the Draw Buffer.
|
|
|
|
*/
|
|
|
|
void addGeometry(GeometryBuffer* gbuff);
|
|
|
|
};
|
|
|
|
|
2014-07-28 02:27:55 +01:00
|
|
|
#endif
|