Commit b9081a81 authored by sumpfralle's avatar sumpfralle

r651@erker: lars | 2010-02-14 03:08:48 +0100

 protect matrix during axis drawing
 disable weird translate call during axis drawing


git-svn-id: https://pycam.svn.sourceforge.net/svnroot/pycam/trunk@116 bbaffbd6-741e-11dd-a85d-61de82d9cad9
parent 1a5c64a1
......@@ -46,6 +46,7 @@ def keep_matrix(func):
@keep_matrix
def draw_string(x, y, z, p, s, scale=.01):
GL.glPushMatrix()
GL.glTranslatef(x, y, z)
if p == 'xy':
pass
......@@ -59,13 +60,14 @@ def draw_string(x, y, z, p, s, scale=.01):
GL.glScalef(scale, scale, scale)
for c in str(s):
GLUT.glutStrokeCharacter(GLUT.GLUT_STROKE_ROMAN, ord(c))
GL.glPopMatrix()
@keep_gl_mode
@keep_matrix
def draw_axes(settings):
GL.glMatrixMode(GL.GL_MODELVIEW)
GL.glLoadIdentity()
GL.glTranslatef(0, 0, -2)
#GL.glTranslatef(0, 0, -2)
if settings.get("unit") == "mm":
size = 100
else:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment