From c4740054cad83896e2015c46b06847eda2e482cc Mon Sep 17 00:00:00 2001 From: baldurk Date: Thu, 4 May 2017 15:00:24 +0100 Subject: [PATCH] Fix restoring VAO state with double-formatted attribs --- renderdoc/driver/gl/gl_manager.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/renderdoc/driver/gl/gl_manager.cpp b/renderdoc/driver/gl/gl_manager.cpp index ba99ac4b1..c21567312 100644 --- a/renderdoc/driver/gl/gl_manager.cpp +++ b/renderdoc/driver/gl/gl_manager.cpp @@ -2114,7 +2114,9 @@ void GLResourceManager::Apply_InitialState(GLResource live, InitialContentData i if(attrib.size != 0) { - if(initialdata->VertexAttribs[i].integer == 0) + if(attrib.type == eGL_DOUBLE) + gl.glVertexAttribLFormat(i, attrib.size, attrib.type, attrib.offset); + else if(attrib.integer == 0) gl.glVertexAttribFormat(i, attrib.size, attrib.type, (GLboolean)attrib.normalized, attrib.offset); else