Coordinates
When doing animation you often need to use a polar or coordinate system. However, React Native uses a canvas coordinate system. These functions will help you to seamlessly go back and forth.
Last updated
Was this helpful?
When doing animation you often need to use a polar or coordinate system. However, React Native uses a canvas coordinate system. These functions will help you to seamlessly go back and forth.
Last updated
Was this helpful?
Was this helpful?
export declare const cartesian2Polar: ({ x, y }: Vector, center: Vector) => { radius: number, theta: number };
export declare const polar2Cartesian: ({ theta, radius }: PolarPoint) => Vector;
export declare const polar2Canvas: ({ theta, radius }: PolarPoint, center: Vector) => Vector;
export declare const canvas2Polar: ({ x, y }: Vector, center: Vector) => {
theta: number;
radius: number;
};