예제 #1
0
def reflect(x, y, x0, y0, d=1.0, a=180):
    """ Returns the reflection of a point through origin (x0,y0).
    """
    return coordinates(x0, y0, d * distance(x0, y0, x, y),
                       a + angle(x0, y0, x, y))
예제 #2
0
파일: geometry.py 프로젝트: est/nodebox-gl
def reflect(x, y, x0, y0, d=1.0, a=180):
    """ Returns the reflection of a point through origin (x0,y0).
    """
    return coordinates(x0, y0, d*distance(x0,y0,x,y), a+angle(x0,y0,x,y))