コード例 #1
0
 def intersect_circle_point(self, direction, point, start=None):
     if start is None:
         start = self.location
     (ccp, cp, l) = intersect_circle_point(
         padd(psub(start, self.location), self.center), self.axis,
         self.distance_radius, self.distance_radiussq, direction, point)
     if ccp:
         cl = padd(cp, psub(start, ccp))
         return (cl, ccp, cp, l)
     return (None, None, None, INFINITE)
コード例 #2
0
 def intersect_circle_point(self, direction, point, start=None):
     if start is None:
         start = self.location
     (ccp, cp, l) = intersect_circle_point(start, self.axis,
             self.distance_majorradius, self.distance_majorradiussq,
             direction, point)
     if ccp:
         cl = cp.sub(ccp.sub(start))
         return (cl, ccp, point, l)
     return (None, None, None, INFINITE)
コード例 #3
0
ファイル: ToroidalCutter.py プロジェクト: stevegt/pycam
 def intersect_circle_point(self, direction, point, start=None):
     if start is None:
         start = self.location
     (ccp, cp, l) = intersect_circle_point(start, self.axis,
             self.distance_majorradius, self.distance_majorradiussq,
             direction, point)
     if ccp:
         cl = psub(cp, psub(ccp, start))
         return (cl, ccp, point, l)
     return (None, None, None, INFINITE)
コード例 #4
0
ファイル: CylindricalCutter.py プロジェクト: I--Fox--I/pycam
 def intersect_circle_point(self, direction, point, start=None):
     if start is None:
         start = self.location
     (ccp, cp, l) = intersect_circle_point(
             start.sub(self.location).add(self.center), self.axis,
             self.distance_radius, self.distance_radiussq, direction, point)
     if ccp:
         cl = cp.add(start.sub(ccp))
         return (cl, ccp, cp, l)
     return (None, None, None, INFINITE)