diff options
| author | Lioncash <mathew1800@gmail.com> | 2014-08-17 15:17:04 -0400 |
|---|---|---|
| committer | Lioncash <mathew1800@gmail.com> | 2014-08-17 15:17:04 -0400 |
| commit | 15a3b30e27121ad89805b2e3ac8920d3a5e92960 (patch) | |
| tree | 1758da2240fd1f73bb5801f6f95e2b3a5c4a4bf4 /Source/Core/VideoBackends/OGL/NativeVertexFormat.cpp | |
| parent | e3e1869493d95ea88c68941642c785553b833fa1 (diff) | |
| parent | 7e3d1050f0f25f659dded00a9df787195b47e7b5 (diff) | |
Merge pull request #790 from lioncash/ogl-cleanup
Small OGL cleanup
Diffstat (limited to 'Source/Core/VideoBackends/OGL/NativeVertexFormat.cpp')
| -rw-r--r-- | Source/Core/VideoBackends/OGL/NativeVertexFormat.cpp | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/Source/Core/VideoBackends/OGL/NativeVertexFormat.cpp b/Source/Core/VideoBackends/OGL/NativeVertexFormat.cpp index dd1ffc2dfd..4207a5a4af 100644 --- a/Source/Core/VideoBackends/OGL/NativeVertexFormat.cpp +++ b/Source/Core/VideoBackends/OGL/NativeVertexFormat.cpp @@ -35,7 +35,7 @@ GLVertexFormat::~GLVertexFormat() glDeleteVertexArrays(1, &VAO); } -inline GLuint VarToGL(VarType t) +static inline GLuint VarToGL(VarType t) { static const GLuint lookup[5] = { GL_UNSIGNED_BYTE, GL_BYTE, GL_UNSIGNED_SHORT, GL_SHORT, GL_FLOAT @@ -75,24 +75,22 @@ void GLVertexFormat::Initialize(const PortableVertexDeclaration &_vtx_decl) SetPointer(SHADER_POSITION_ATTRIB, vertex_stride, vtx_decl.position); - for (int i = 0; i < 3; i++) { + for (int i = 0; i < 3; i++) SetPointer(SHADER_NORM0_ATTRIB+i, vertex_stride, vtx_decl.normals[i]); - } - for (int i = 0; i < 2; i++) { + for (int i = 0; i < 2; i++) SetPointer(SHADER_COLOR0_ATTRIB+i, vertex_stride, vtx_decl.colors[i]); - } - for (int i = 0; i < 8; i++) { + for (int i = 0; i < 8; i++) SetPointer(SHADER_TEXTURE0_ATTRIB+i, vertex_stride, vtx_decl.texcoords[i]); - } SetPointer(SHADER_POSMTX_ATTRIB, vertex_stride, vtx_decl.posmtx); vm->m_last_vao = VAO; } -void GLVertexFormat::SetupVertexPointers() { +void GLVertexFormat::SetupVertexPointers() +{ } } |
