Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(5)  |  Call(3)  |  Derive(0)  |  Import(2)

src/c/h/Chiplotle-0.4/chiplotle/tools/hpgltools/rotate_hpglprimitives.py   Chiplotle(Download)
from chiplotle.hpgl.abstract.hpglprimitive import _HPGLPrimitive
from chiplotle.tools.mathtools.rotate_2d import rotate_coordinate_2d
from chiplotle.geometry.core.coordinatearray import CoordinateArray
from chiplotle.geometry.core.coordinate import Coordinate
 
            result = [ ]
            for cp in e.xy:
               result.append(rotate_coordinate_2d(cp, angle, pivot))
            e.xy = CoordinateArray(result)
         elif isinstance(e.xy, Coordinate):
            e.xy = rotate_coordinate_2d(e.xy, angle, pivot)

src/c/h/Chiplotle-0.4/chiplotle/geometry/core/transformlock.py   Chiplotle(Download)
from chiplotle.geometry.core.group import Group
from chiplotle.tools.mathtools.rotate_2d import rotate_coordinate_2d
from chiplotle.tools.geometrytools.scale import scale
 
class TransformLock(Group):
   def rotate_to_offset(points, angle, pivot):
      def offset(points, value):
         return points + value
      center = points.center
      new_coord = rotate_coordinate_2d(center, angle, pivot)