code: def _scalePoints(points, scale=1, convertToInteger=True):
      
      if convertToInteger:
          points = [
              (int(round(x * scale)), int(round(y * scale)))
              for (x, y) in points
          ]
      else:
          points = [(x * scale, y * scale) for (x, y) in points]
      return points
docs: Scale points and optionally convert them to integers.