From b38ef39ab7b88eb7e4fa253deec64cecb72508aa Mon Sep 17 00:00:00 2001 From: degasus Date: Fri, 24 Jan 2014 15:16:52 +0100 Subject: PortableVertexFormat: use AttributeFormat for normal attribute format --- Source/Core/VideoBackends/OGL/NativeVertexFormat.cpp | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'Source/Core/VideoBackends/OGL/NativeVertexFormat.cpp') diff --git a/Source/Core/VideoBackends/OGL/NativeVertexFormat.cpp b/Source/Core/VideoBackends/OGL/NativeVertexFormat.cpp index 49098b24b4..88147aa755 100644 --- a/Source/Core/VideoBackends/OGL/NativeVertexFormat.cpp +++ b/Source/Core/VideoBackends/OGL/NativeVertexFormat.cpp @@ -75,10 +75,7 @@ void GLVertexFormat::Initialize(const PortableVertexDeclaration &_vtx_decl) SetPointer(SHADER_POSITION_ATTRIB, vertex_stride, vtx_decl.position); for (int i = 0; i < 3; i++) { - if (vtx_decl.num_normals > i) { - glEnableVertexAttribArray(SHADER_NORM0_ATTRIB+i); - glVertexAttribPointer(SHADER_NORM0_ATTRIB+i, vtx_decl.normal_gl_size, VarToGL(vtx_decl.normal_gl_type), GL_TRUE, vtx_decl.stride, (u8*)NULL + vtx_decl.normal_offset[i]); - } + SetPointer(SHADER_NORM0_ATTRIB+i, vertex_stride, vtx_decl.normals[i]); } for (int i = 0; i < 2; i++) { -- cgit v1.2.3