summaryrefslogtreecommitdiff
path: root/indra/llrender/llvertexbuffer.h
diff options
context:
space:
mode:
authorDave Parks <davep@lindenlab.com>2011-09-23 17:59:05 -0500
committerDave Parks <davep@lindenlab.com>2011-09-23 17:59:05 -0500
commit57620a9da903f3c6fe482627d18c44b6411e6910 (patch)
treeb502aaa58018db970afede0ee441be1377f98e80 /indra/llrender/llvertexbuffer.h
parentb9926e8f57787eb146b06260cc3d0260e34330ce (diff)
SH-2244 Vertex buffer cleanup, fix for bad vertices in rigged attachments, added "RenderUseVAO" debug setting to control whether or not to use VAO's in non-core GL profiles.
Diffstat (limited to 'indra/llrender/llvertexbuffer.h')
-rw-r--r--indra/llrender/llvertexbuffer.h13
1 files changed, 5 insertions, 8 deletions
diff --git a/indra/llrender/llvertexbuffer.h b/indra/llrender/llvertexbuffer.h
index eba10dbaa5..d116a552fa 100644
--- a/indra/llrender/llvertexbuffer.h
+++ b/indra/llrender/llvertexbuffer.h
@@ -91,9 +91,7 @@ public:
S32 mIndex;
S32 mCount;
- MappedRegion(S32 type, S32 index, S32 count)
- : mType(type), mIndex(index), mCount(count)
- { }
+ MappedRegion(S32 type, S32 index, S32 count);
};
LLVertexBuffer(const LLVertexBuffer& rhs)
@@ -113,11 +111,12 @@ public:
static LLVBOPool sDynamicIBOPool;
static BOOL sUseStreamDraw;
+ static BOOL sUseVAO;
static BOOL sPreferStreamDraw;
static void initClass(bool use_vbo, bool no_vbo_mapping);
static void cleanupClass();
- static void setupClientArrays(U32 data_mask, U32& ref_mask = LLVertexBuffer::sLastMask);
+ static void setupClientArrays(U32 data_mask);
static void drawArrays(U32 mode, const std::vector<LLVector3>& pos, const std::vector<LLVector3>& norm);
static void drawElements(U32 mode, const LLVector4a* pos, const LLVector2* tc, S32 num_indices, const U16* indicesp);
@@ -141,7 +140,7 @@ public:
// 5 - modify LLViewerShaderMgr::mReservedAttribs
// 6 - update LLVertexBuffer::setupVertexArray
enum {
- TYPE_VERTEX,
+ TYPE_VERTEX = 0,
TYPE_NORMAL,
TYPE_TEXCOORD0,
TYPE_TEXCOORD1,
@@ -149,14 +148,12 @@ public:
TYPE_TEXCOORD3,
TYPE_COLOR,
TYPE_EMISSIVE,
- // These use VertexAttribPointer and should possibly be made generic
TYPE_BINORMAL,
TYPE_WEIGHT,
TYPE_WEIGHT4,
TYPE_CLOTHWEIGHT,
- TYPE_MAX,
- //no actual additional data, but indicates position.w is texture index
TYPE_TEXTURE_INDEX,
+ TYPE_MAX,
TYPE_INDEX,
};
enum {