def create_ring_coordinates(radius, count):
""" Create coordinates arranged in a ring.
:param radius: Radius of the ring.
:type radius: float
:param count: Count of coordinates to generate.
:type count: int
:returns: Tuple of the coordinates.
:rtype: tuple
"""
pixelstep = math.radians(360/count)
pixels = []
for index in range(0, count):
pixels.append((radius * math.cos(index*pixelstep),
radius * math.sin(index*pixelstep)))
return pixels
评论列表
文章目录