# `GSPath ellipseWithCenter:radius1:radius2:angle:`

*Initializer*

Creates a closed cubic path approximating an ellipse.

## Declaration

```swift
convenience init?(ellipseAt center: NSPoint, radius1 a: CGFloat, radius2 b: CGFloat, transform theta: CGFloat)
```

```objc
+ (instancetype) ellipseWithCenter:(NSPoint) center radius1:(CGFloat) a radius2:(CGFloat) b angle:(CGFloat) theta;
```

```python
ellipseWithCenter_radius1_radius2_angle_(center: NSPoint, a: float, b: float, theta: float) -> GSPath
```

## Discussion

The angle is measured in radians.

Returns `nil` when both radii are zero.

## See Also

### Creating a Path

- [`GSPath initWithDict:format:`](/Core/GlyphsCore/GSPath/initWithDict:format:) — Creates a path from a Glyphs file dictionary representation.
- [`GSPath initWithGlyphsParser:format:`](/Core/GlyphsCore/GSPath/initWithGlyphsParser:format:) — Creates a path from the Glyphs file representation at the current parser position.
- [`GSPath pathWithString:isClosed:`](/Core/GlyphsCore/GSPath/pathWithString:isClosed:) — Creates a path from a sequence of node element strings.
- [`GSPath pathWithRect:`](/Core/GlyphsCore/GSPath/pathWithRect:) — Creates a closed rectangular path enclosing the rectangle.
- [`GSPath circleWithRect:`](/Core/GlyphsCore/GSPath/circleWithRect:) — Creates a closed cubic path approximating an ellipse inside the rectangle.
- [`GSPath circleWithCenter:radius:`](/Core/GlyphsCore/GSPath/circleWithCenter:radius:) — Creates a closed cubic path approximating a circle.

