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

# 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: SIMD4<Float>, n: SIMD4<Float>, eta: Float) -> SIMD4<Float>
```

## See Also

### Geometry Functions

- [dot(_:_:)](simd/dot(_:_:)-47df.md)
- [normalize(_:)](simd/normalize(_:)-6g9xc.md)
- [project(_:_:)](simd/project(_:_:)-pdsh.md)
- [reflect(_:n:)](simd/reflect(_:n:)-8i5cc.md)
