Index: game.py
===================================================================
--- game.py	(revision a7f54e31d95e33e65a3085b3d76a8ddd69e1bc3a)
+++ game.py	(revision b2d384b5eb7623b1fb79fe5d189626b30c1e5990)
@@ -11,17 +11,11 @@
    #glEnable (GL_BLEND); glBlendFunc (GL_ONE, GL_ONE);
 
-   # I should really figure out which attributes in the 2D rendering
-   # break the 3d rendering and reset those back instead of resetting
-   # all attributes
-   glPushAttrib(GL_ALL_ATTRIB_BITS)
+   glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
+
    render3d(surface)
-   glPopAttrib()
 
    if showOverlay:
       renderOverlay(overlay, font)
-
-      glPushAttrib(GL_ALL_ATTRIB_BITS)
       projectOverlay(surface, overlay)
-      glPopAttrib()
 
 
@@ -35,4 +29,6 @@
 
    pygame.draw.rect(overlay, (0, 128, 255), pygame.Rect(30, 30, 60, 60))
+   pygame.draw.rect(overlay, (128, 255, 0), pygame.Rect(300, 300, 1000, 1000))
+   
    overlay.blit(text, (500, 100))
 
@@ -41,5 +37,5 @@
    glPushMatrix()
 
-   glClear(GL_COLOR_BUFFER_BIT|GL_DEPTH_BUFFER_BIT)
+   glColor3f(1.0, 1.0, 1.0)
 
    glTranslatef(0.0,0.0,-zNear)
@@ -74,4 +70,6 @@
 
    glEnd()
+   
+   glDisable(GL_TEXTURE_2D)
 
    glPopMatrix()
@@ -104,9 +102,8 @@
    
    glPushMatrix()
-
-   glClear(GL_COLOR_BUFFER_BIT|GL_DEPTH_BUFFER_BIT)
+   
+   glColor3f(1.0, 0.0, 0.0)
 
    glTranslatef(0.0,0.0,-2*zNear)
-   glColor3f(1.0, 1.0, 1.0)
 
    glBegin(GL_LINES)
@@ -167,4 +164,8 @@
 
 zNear = 1.0/math.tan(math.radians(45.0/2))
+
+# not really need here since there are no previous
+# matrix modifications, but keeping it for reference
+#glLoadIdentity()
 gluPerspective(45, (w/h), zNear, 500.0)
 
