From c5c706228593612b864aa7e1ec674bb98e6b8764 Mon Sep 17 00:00:00 2001 From: =?utf8?q?C=C3=B4me=20Chilliet?= Date: Wed, 4 Jan 2017 14:23:42 +0100 Subject: [PATCH] Removed unused method from Model class --- Source/Graphic/Models.cpp | 27 --------------------------- Source/Graphic/Models.hpp | 1 - 2 files changed, 28 deletions(-) diff --git a/Source/Graphic/Models.cpp b/Source/Graphic/Models.cpp index 0f6a2db..dc81be2 100644 --- a/Source/Graphic/Models.cpp +++ b/Source/Graphic/Models.cpp @@ -880,33 +880,6 @@ void Model::draw() glDisableClientState(GL_TEXTURE_COORD_ARRAY); } -//TODO: phase out in favor of Texture -void Model::drawdifftex(GLuint texture) -{ - glEnableClientState(GL_NORMAL_ARRAY); - glEnableClientState(GL_VERTEX_ARRAY); - glEnableClientState(GL_TEXTURE_COORD_ARRAY); - if (color) { - glInterleavedArrays( GL_T2F_C3F_V3F, 8 * sizeof(GLfloat), &vArray[0]); - } else { - glInterleavedArrays( GL_T2F_N3F_V3F, 8 * sizeof(GLfloat), &vArray[0]); - } - - glBindTexture(GL_TEXTURE_2D, (unsigned long)texture); - glTexParameterf( GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_REPEAT ); - glTexParameterf( GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_REPEAT ); - - glDrawArrays(GL_TRIANGLES, 0, Triangles.size() * 3); - - if (color) { - glDisableClientState(GL_COLOR_ARRAY); - } else { - glDisableClientState(GL_NORMAL_ARRAY); - } - glDisableClientState(GL_VERTEX_ARRAY); - glDisableClientState(GL_TEXTURE_COORD_ARRAY); -} - void Model::drawdifftex(Texture texture) { glEnableClientState(GL_NORMAL_ARRAY); diff --git a/Source/Graphic/Models.hpp b/Source/Graphic/Models.hpp index 3756c1e..ecfb3dd 100644 --- a/Source/Graphic/Models.hpp +++ b/Source/Graphic/Models.hpp @@ -117,7 +117,6 @@ public: void Translate(float xtrans, float ytrans, float ztrans); void CalculateNormals(bool facenormalise); void draw(); - void drawdifftex(GLuint texture); void drawdifftex(Texture texture); void drawimmediate(); void Rotate(float xang, float yang, float zang); -- 2.39.5