None means the requested box was outside the bounds
This commit is contained in:
parent
e1b201f417
commit
b346c83f4b
@ -997,7 +997,9 @@ class MCLevel(object):
|
|||||||
return box, (destX, destY, destZ)
|
return box, (destX, destY, destZ)
|
||||||
|
|
||||||
def extractSchematic(self, box):
|
def extractSchematic(self, box):
|
||||||
box, destPoint = self.adjustExtractionParameters(box);
|
p = self.adjustExtractionParameters(box);
|
||||||
|
if p is None: return
|
||||||
|
box, destPoint = p
|
||||||
|
|
||||||
tempSchematic = MCSchematic(shape=box.size)
|
tempSchematic = MCSchematic(shape=box.size)
|
||||||
tempSchematic.materials = self.materials
|
tempSchematic.materials = self.materials
|
||||||
@ -1006,7 +1008,10 @@ class MCLevel(object):
|
|||||||
return tempSchematic
|
return tempSchematic
|
||||||
|
|
||||||
def extractZipSchematic(self, box, zipfilename):
|
def extractZipSchematic(self, box, zipfilename):
|
||||||
box, destPoint = self.adjustExtractionParameters(box);
|
p = self.adjustExtractionParameters(box);
|
||||||
|
if p is None: return
|
||||||
|
box, destPoint = p
|
||||||
|
|
||||||
destPoint = (0,0,0)
|
destPoint = (0,0,0)
|
||||||
|
|
||||||
filename = tempfile.mktemp("schematic")
|
filename = tempfile.mktemp("schematic")
|
||||||
|
Reference in New Issue
Block a user