---
title: inflationConstraint
framework: realitykit
role: symbol
role_heading: Instance Property
path: realitykit/clothbodycomponent/inflationconstraint-swift.property
---

# inflationConstraint

An optional inflation constraint for representing inflatable bodies (must be watertight).

## Declaration

```swift
var inflationConstraint: ClothBodyComponent.InflationConstraint? { get set }
```

## Discussion

Discussion When non-nil, the body will try to maintain the specified target volume with the given stiffness. The mesh must be watertight for this inflation constraint to have any effect. Setting this to nil disables the inflation constraint (equivalent to a stiffness of zero).

## See Also

### Applying external forces

- [externalForces](realitykit/clothbodycomponent/externalforces.md)
- [ClothBodyComponent.ExternalForce](realitykit/clothbodycomponent/externalforce.md)
- [ClothBodyComponent.InflationConstraint](realitykit/clothbodycomponent/inflationconstraint-swift.struct.md)
