Commit 8941eb74 authored by Kliment Yanev's avatar Kliment Yanev

Fix bug with slic3r gcode and duration estimation

Make STLs less shiny on non-Linux OSs
parent a2d5cd5d
...@@ -108,6 +108,7 @@ def estimate_duration(g): ...@@ -108,6 +108,7 @@ def estimate_duration(g):
# calculate the maximum move duration accounting for above ;) # calculate the maximum move duration accounting for above ;)
print ".... estimating ...." print ".... estimating ...."
for i in g: for i in g:
i=i.split(";")[0]
if "G4" in i or "G1" in i: if "G4" in i or "G1" in i:
if "G4" in i: if "G4" in i:
parts = i.split(" ") parts = i.split(" ")
......
...@@ -102,7 +102,7 @@ class GLPanel(wx.Panel): ...@@ -102,7 +102,7 @@ class GLPanel(wx.Panel):
self.dist=1000 self.dist=1000
self.vpmat=None self.vpmat=None
#normal gl init #normal gl init
glClearColor(0, 0, 0, 0.5) glClearColor(0, 0, 0, 1)
glColor3f(1, 0, 0) glColor3f(1, 0, 0)
glEnable(GL_DEPTH_TEST) glEnable(GL_DEPTH_TEST)
glEnable(GL_CULL_FACE) glEnable(GL_CULL_FACE)
...@@ -129,7 +129,7 @@ class GLPanel(wx.Panel): ...@@ -129,7 +129,7 @@ class GLPanel(wx.Panel):
glMaterialfv(GL_FRONT_AND_BACK, GL_AMBIENT_AND_DIFFUSE, vec(0.5, 0, 0.3, 1)) glMaterialfv(GL_FRONT_AND_BACK, GL_AMBIENT_AND_DIFFUSE, vec(0.5, 0, 0.3, 1))
glMaterialfv(GL_FRONT_AND_BACK, GL_SPECULAR, vec(1, 1, 1, 1)) glMaterialfv(GL_FRONT_AND_BACK, GL_SPECULAR, vec(1, 1, 1, 1))
glMaterialf(GL_FRONT_AND_BACK, GL_SHININESS, 200) glMaterialf(GL_FRONT_AND_BACK, GL_SHININESS, 50)
glMaterialfv(GL_FRONT_AND_BACK, GL_EMISSION, vec(0,0.1,0,0.9)) glMaterialfv(GL_FRONT_AND_BACK, GL_EMISSION, vec(0,0.1,0,0.9))
#create objects to draw #create objects to draw
#self.create_objects() #self.create_objects()
......
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