<!--
{
  "availability" : [

  ],
  "documentType" : "symbol",
  "framework" : "Accelerate",
  "identifier" : "/documentation/simd/refract(_:n:eta:)-2macj",
  "metadataVersion" : "0.1.0",
  "role" : "Function",
  "symbol" : {
    "kind" : "Function",
    "modules" : [
      "simd"
    ],
    "preciseIdentifier" : "s:4simd7refract_1n3etas5SIMD4VySdGAG_AGSdtF"
  },
  "title" : "refract(_:n:eta:)"
}
-->

# refract(_:n:eta:)

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

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

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)