private static function calculatePoint($center, $rx, $ry, $xa, $angle)
    {
        $a = $rx * cos($angle);
        $b = $ry * sin($angle);

        return array(
            cos($xa) * $a - sin($xa) * $b + $center[0],
            sin($xa) * $a + cos($xa) * $b + $center[1],
        );
    }