Gawain: fix immediate mode drawing exceeding IMM_BUFFER_SIZE

Would cause crazy colors in file selector.
This commit is contained in:
Campbell Barton
2017-04-20 20:43:56 +10:00
parent 28ed66552b
commit 8e0c57a812

View File

@@ -208,9 +208,8 @@ void immBegin(PrimitiveType prim_type, unsigned vertex_ct)
else
{
// orphan this buffer & start with a fresh one
#if APPLE_LEGACY
glBufferData(GL_ARRAY_BUFFER, IMM_BUFFER_SIZE, NULL, GL_DYNAMIC_DRAW);
#else
#if !APPLE_LEGACY
if (GLEW_VERSION_4_3 || GLEW_ARB_invalidate_subdata)
glInvalidateBufferData(imm.vbo_id);
else