コード例 #1
0
def getManipulatedPaths(close, elementNode, loop, prefix, sideLength):
	"Get path with outline."
	if len(loop) < 2:
		return [loop]
	derivation = OutlineDerivation(elementNode, prefix, sideLength)
	loopComplex = euclidean.getComplexPath(loop)
	if derivation.isClosed:
		loopComplexes = intercircle.getAroundsFromLoop(loopComplex, derivation.radius)
	else:
		loopComplexes = intercircle.getAroundsFromPath(loopComplex, derivation.radius)
	return euclidean.getVector3Paths(loopComplexes, loop[0].z)
コード例 #2
0
ファイル: outline.py プロジェクト: folksjos/RepG
def getManipulatedPaths(close, elementNode, loop, prefix, sideLength):
	"Get path with outline."
	if len(loop) < 2:
		return [loop]
	derivation = OutlineDerivation(elementNode, prefix, sideLength)
	loopComplex = euclidean.getComplexPath(loop)
	if derivation.isClosed:
		loopComplexes = intercircle.getAroundsFromLoop(loopComplex, derivation.radius)
	else:
		loopComplexes = intercircle.getAroundsFromPath(loopComplex, derivation.radius)
	return euclidean.getVector3Paths(loopComplexes, loop[0].z)
コード例 #3
0
ファイル: outline.py プロジェクト: mccoyn/SkeinFactory
def getManipulatedPaths(close, loop, prefix, sideLength, xmlElement):
	"Get path with overhangs removed or filled in."
	if len(loop) < 2:
		return [loop]
	isClosed = evaluate.getEvaluatedBooleanDefault(False, prefix + 'closed', xmlElement)
	radius = lineation.getStrokeRadiusByPrefix(prefix, xmlElement )
	loopComplex = euclidean.getComplexPath(loop)
	if isClosed:
		loopComplexes = intercircle.getAroundsFromLoop(loopComplex, radius)
	else:
		loopComplexes = intercircle.getAroundsFromPath(loopComplex, radius)
	return euclidean.getVector3Paths(loopComplexes, loop[0].z)
コード例 #4
0
ファイル: outline.py プロジェクト: folksjos/RepG
def getManipulatedPaths(close, loop, prefix, sideLength, xmlElement):
	"Get path with overhangs removed or filled in."
	if len(loop) < 2:
		return [loop]
	isClosed = evaluate.getEvaluatedBooleanDefault(False, prefix + 'closed', xmlElement)
	radius = lineation.getStrokeRadiusByPrefix(prefix, xmlElement )
	loopComplex = euclidean.getComplexPath(loop)
	if isClosed:
		loopComplexes = intercircle.getAroundsFromLoop(loopComplex, radius)
	else:
		loopComplexes = intercircle.getAroundsFromPath(loopComplex, radius)
	return euclidean.getVector3Paths(loopComplexes, loop[0].z)
コード例 #5
0
def getManipulatedPaths(close, elementNode, loop, prefix, sideLength):
	"Get path with outline."
	if len(loop) < 2:
		return [loop]
	isClosed = evaluate.getEvaluatedBoolean(False, elementNode, prefix + 'closed')
	radius = lineation.getStrokeRadiusByPrefix(elementNode, prefix )
	loopComplex = euclidean.getComplexPath(loop)
	if isClosed:
		loopComplexes = intercircle.getAroundsFromLoop(loopComplex, radius)
	else:
		loopComplexes = intercircle.getAroundsFromPath(loopComplex, radius)
	return euclidean.getVector3Paths(loopComplexes, loop[0].z)
コード例 #6
0
	def addLeadinnedInfill(self):
		'Add leadinned infill.'
		if self.infill == None:
			return
		if len(self.infill) < 2:
			return
		infillOutlines = intercircle.getAroundsFromPath(self.infill, self.quarterInfillWidth)
		lowerZ = self.oldLocation.z - self.halfLayerThickness
		self.addFlowRateLine(0.25 * self.repository.infillBottomFlowRate.value * self.oldFlowRate* (self.repository.infillBottomFeedRate.value))
		self.addInfillOutlines(self.repository.infillBottomFeedRate.value * self.feedRateMinute, infillOutlines, lowerZ)
		self.addFlowRateLine(0.25 * self.repository.infillTopFlowRate.value * self.oldFlowRate * self.repository.infillTopFeedRate.value)
		self.addInfillOutlines(self.repository.infillTopFeedRate.value * self.feedRateMinute, infillOutlines, self.oldLocation.z)
		self.addFlowRateLine(self.oldFlowRate)
コード例 #7
0
def getManipulatedPaths(close, elementNode, loop, prefix, sideLength):
    "Get path with outline."
    if len(loop) < 2:
        return [loop]
    isClosed = evaluate.getEvaluatedBoolean(False, elementNode,
                                            prefix + 'closed')
    radius = lineation.getStrokeRadiusByPrefix(elementNode, prefix)
    loopComplex = euclidean.getComplexPath(loop)
    if isClosed:
        loopComplexes = intercircle.getAroundsFromLoop(loopComplex, radius)
    else:
        loopComplexes = intercircle.getAroundsFromPath(loopComplex, radius)
    return euclidean.getVector3Paths(loopComplexes, loop[0].z)
コード例 #8
0
ファイル: svg_reader.py プロジェクト: CNCBASHER/skeinforge-1
def getTransformedOutlineByPath(path, xmlElement, yAxisPointingUpward):
    "Get the outline from the path."
    aroundsFromPath = intercircle.getAroundsFromPath(
        path, getStrokeRadius(xmlElement))
    return getChainMatrixSVGIfNecessary(
        xmlElement, yAxisPointingUpward).getTransformedPaths(aroundsFromPath)
コード例 #9
0
def getTransformedOutlineByPath(path, xmlElement, yAxisPointingUpward):
	"Get the outline from the path."
	aroundsFromPath = intercircle.getAroundsFromPath(path, getStrokeRadius(xmlElement))
	return getChainMatrixSVGIfNecessary(xmlElement, yAxisPointingUpward).getTransformedPaths(aroundsFromPath)