Commit a53b09e3ba5ef5b3e88526f28659814a04846295

henry 2002-02-16T06:19:20

Removed FT_DoneGlyph and fix state stuff

diff --git a/src/FTGLBitmapFont.cpp b/src/FTGLBitmapFont.cpp
index 1658da0..36edefc 100755
--- a/src/FTGLBitmapFont.cpp
+++ b/src/FTGLBitmapFont.cpp
@@ -20,7 +20,7 @@ FTGlyph* FTGLBitmapFont::MakeGlyph( unsigned int g)
 	if( ftGlyph)
 	{
 		FTBitmapGlyph* tempGlyph = new FTBitmapGlyph( *ftGlyph);
-                FT_Done_Glyph( *ftGlyph );
+//                FT_Done_Glyph( *ftGlyph );
 
 		return tempGlyph;
 	}
@@ -32,8 +32,9 @@ FTGlyph* FTGLBitmapFont::MakeGlyph( unsigned int g)
 
 void FTGLBitmapFont::render( const char* string)
 {	
-	glPushClientAttrib( GL_CLIENT_PIXEL_STORE_BIT | GL_ENABLE_BIT);
-	
+	glPushClientAttrib( GL_CLIENT_PIXEL_STORE_BIT);
+    glPushAttrib( GL_ENABLE_BIT);
+    
 	glPixelStorei( GL_UNPACK_LSB_FIRST, GL_FALSE);
 	glPixelStorei( GL_UNPACK_ROW_LENGTH, 0);
 	glPixelStorei( GL_UNPACK_ALIGNMENT, 1);
@@ -42,15 +43,16 @@ void FTGLBitmapFont::render( const char* string)
 
 	FTFont::render( string);
 
+	glPopAttrib();
 	glPopClientAttrib();
-
 }
 
 
 void FTGLBitmapFont::render( const wchar_t* string)
 {	
-	glPushClientAttrib( GL_CLIENT_PIXEL_STORE_BIT | GL_ENABLE_BIT);
-	
+	glPushClientAttrib( GL_CLIENT_PIXEL_STORE_BIT);
+    glPushAttrib( GL_ENABLE_BIT);
+    
 	glPixelStorei( GL_UNPACK_LSB_FIRST, GL_FALSE);
 	glPixelStorei( GL_UNPACK_ROW_LENGTH, 0);
 	glPixelStorei( GL_UNPACK_ALIGNMENT, 1);
@@ -59,7 +61,7 @@ void FTGLBitmapFont::render( const wchar_t* string)
 
 	FTFont::render( string);
 
+	glPopAttrib();
 	glPopClientAttrib();
-
 }