---
title: flatness
framework: appkit
role: symbol
role_heading: Instance Property
path: appkit/nsbezierpath/flatness
---

# flatness

The accuracy with which curves are rendered.

## Declaration

```swift
var flatness: CGFloat { get set }
```

## Discussion

Discussion The flatness value specifies the accuracy (or smoothness) with which curves are rendered. It is also the maximum error tolerance (measured in pixels) for rendering curves, where smaller numbers give smoother curves at the expense of more computation. The exact interpretation may vary slightly on different rendering devices. The default value of this property is the value returned by the defaultFlatness method.

## See Also

### Related Documentation

- [defaultFlatness](appkit/nsbezierpath/defaultflatness.md)

### Accessing a Path’s Attributes

- [windingRule](appkit/nsbezierpath/windingrule-swift.property.md)
- [lineCapStyle](appkit/nsbezierpath/linecapstyle-swift.property.md)
- [lineJoinStyle](appkit/nsbezierpath/linejoinstyle-swift.property.md)
- [lineWidth](appkit/nsbezierpath/linewidth.md)
- [miterLimit](appkit/nsbezierpath/miterlimit.md)
- [getLineDash(_:count:phase:)](appkit/nsbezierpath/getlinedash(_:count:phase:).md)
- [setLineDash(_:count:phase:)](appkit/nsbezierpath/setlinedash(_:count:phase:).md)
