Fixed flip options, added show log when slicing fails, fixed bug in comb module

master
Daid 2012-03-11 11:56:50 +01:00
parent 34bc6c5b0b
commit 351bb29ade
3 changed files with 9 additions and 10 deletions

View File

@ -74,18 +74,18 @@ class sliceProgessPanel(wx.Panel):
def OnSliceDone(self, result):
self.progressGauge.Destroy()
self.progressLog = result.progressLog
self.sizer.Remove(self.abortButton)
self.logButton = wx.Button(self, -1, "Show Log")
self.Bind(wx.EVT_BUTTON, self.OnShowLog, self.logButton)
self.sizer.Add(self.logButton, 0)
if result.returnCode == 0:
self.statusText.SetLabel("Ready.")
self.logButton = wx.Button(self, -1, "Show Log")
self.Bind(wx.EVT_BUTTON, self.OnShowLog, self.logButton)
self.showButton = wx.Button(self, -1, "Show GCode")
self.Bind(wx.EVT_BUTTON, self.OnShowGCode, self.showButton)
self.sizer.Remove(self.abortButton)
self.sizer.Add(self.logButton, 0)
self.sizer.Add(self.showButton, 0)
self.sizer.Add(self.abortButton, 0)
else:
self.statusText.SetLabel("Something went wrong during slicing!")
self.sizer.Add(self.abortButton, 0)
self.sizer.Layout()
self.Layout()
self.abort = True

View File

@ -204,11 +204,11 @@ class CarveSkein:
scaleX = scale
scaleY = scale
scaleZ = scale
if repository.flipX.value == 'True':
if repository.flipX.value == True:
scaleX = -scaleX
if repository.flipY.value == 'True':
if repository.flipY.value == True:
scaleY = -scaleY
if repository.flipZ.value == 'True':
if repository.flipZ.value == True:
scaleZ = -scaleZ
mat00 = math.cos(rotate) * scaleX
mat01 =-math.sin(rotate) * scaleY

View File

@ -141,12 +141,11 @@ class BoundarySegment:
def getSegment(self, boundarySegmentIndex, boundarySegments, edgeWidth, runningJumpSpace):
'Get both paths along the loop from the point closest to the begin to the point closest to the end.'
negativeEdgeWidth = -edgeWidth
nextBoundarySegment = boundarySegments[boundarySegmentIndex + 1]
nextBegin = nextBoundarySegment.segment[0]
end = getJumpPointIfInside(self.boundary, nextBegin, edgeWidth, runningJumpSpace)
if end == None:
end = self.boundary.segment[1]
end = self.segment[1]
nextBegin = getJumpPointIfInside(nextBoundarySegment.boundary, end, edgeWidth, runningJumpSpace)
if nextBegin != None:
nextBoundarySegment.segment[0] = nextBegin