]> git.lizzy.rs Git - irrlicht.git/blobdiff - source/Irrlicht/OpenGL/Driver.h
Unify quad drawing
[irrlicht.git] / source / Irrlicht / OpenGL / Driver.h
index 42c2debc21779964c79e41815b92c78c2aca95d3..dc2929738812c7825be08e9a2cfa03a9498458f9 100644 (file)
@@ -332,6 +332,10 @@ namespace video
                //! Same as `CacheHandler->setViewport`, but also sets `ViewPort`\r
                virtual void setViewPortRaw(u32 width, u32 height);\r
 \r
+               void drawQuad(const S3DVertex (&vertices)[4], bool textured);\r
+               void drawQuads(const S3DVertex *vertices, int quad_count, bool textured);\r
+               void drawArrays(GLenum type, const S3DVertex *vertices, int vertex_count, bool textured);\r
+\r
                COpenGL3CacheHandler* CacheHandler;\r
                core::stringw Name;\r
                core::stringc VendorName;\r
@@ -379,6 +383,9 @@ private:
 \r
                IContextManager* ContextManager;\r
 \r
+               std::vector<u16> QuadsIndices;\r
+               void initQuadsIndices(int max_vertex_count = 65536);\r
+\r
                void debugCb(GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar *message);\r
                static void APIENTRY debugCb(GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar *message, const void *userParam);\r
        };\r