---
title: "refract(_:n:eta:)"
framework: simd
role: symbol
role_heading: Function
path: "simd/refract(_:n:eta:)-13wsy"
---

# refract(_:n:eta:)

Returns the refraction direction of an incident vector, a unit normal vector, and an index of refraction eta.

## Declaration

```swift
func refract(_ x: SIMD3<Double>, n: SIMD3<Double>, eta: Double) -> SIMD3<Double>
```

## See Also

### Geometry Functions

- [cross(_:_:)](simd/cross(_:_:)-7sd7t.md)
- [dot(_:_:)](simd/dot(_:_:)-2sdb.md)
- [normalize(_:)](simd/normalize(_:)-29n8k.md)
- [project(_:_:)](simd/project(_:_:)-9jlig.md)
- [reflect(_:n:)](simd/reflect(_:n:)-1vw0n.md)
