Re-implement line loops by constructing a 'looping' index buffer, so it is…

Re-implement line loops by constructing a 'looping' index buffer, so it is compatible with instanced draws. TRAC #19489 Signed-off-by: Daniel Koch Author: Nicolas Capens git-svn-id: https://angleproject.googlecode.com/svn/trunk@973 736b8ea6-26fd-11df-bfd4-992fa37f6226
parent f654945b
......@@ -457,9 +457,7 @@ class Context
void drawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instances);
void sync(bool block); // flush/finish
// Draw the last segment of a line loop
void drawClosingLine(unsigned int first, unsigned int last, int minIndex);
void drawClosingLine(GLsizei count, GLenum type, const GLvoid *indices, int minIndex);
void drawLineLoop(GLsizei count, GLenum type, const GLvoid *indices, int minIndex);
void recordInvalidEnum();
void recordInvalidValue();
......@@ -561,7 +559,7 @@ class Context
Blit *mBlit;
StreamingIndexBuffer *mClosingIB;
StreamingIndexBuffer *mLineLoopIB;
BindingPointer<Texture> mIncompleteTextures[TEXTURE_TYPE_COUNT];
......
......@@ -15,11 +15,6 @@
#include "libGLESv2/mathutil.h"
#include "libGLESv2/main.h"
namespace
{
enum { INITIAL_INDEX_BUFFER_SIZE = 4096 * sizeof(GLuint) };
}
namespace gl
{
unsigned int IndexBuffer::mCurrentSerial = 1;
......
......@@ -18,6 +18,11 @@
#include "libGLESv2/Context.h"
namespace
{
enum { INITIAL_INDEX_BUFFER_SIZE = 4096 * sizeof(GLuint) };
}
namespace gl
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment