---
title: "simd_quaternion(_:)"
framework: simd
role: symbol
role_heading: Function
path: "simd/simd_quaternion(_:)-8kjw1"
---

# simd_quaternion(_:)

## Declaration

```swift
func simd_quaternion(_ xyzr: UnsafePointer<Float16>!) -> simd_quath
```

## Discussion

Discussion Constructs a quaternion from an array of four scalars. Note that the imaginary part of the quaternion comes from array elements 0, 1, and 2, and the real part comes from element 3.
