<!--
{
  "availability" : [
    "iOS: 16.0.0 -",
    "iPadOS: 16.0.0 -",
    "macCatalyst: -",
    "macOS: 13.0.0 -",
    "tvOS: 16.0.0 -",
    "visionOS: -",
    "watchOS: 9.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Spatial",
  "identifier" : "/documentation/Spatial/Angle2D/init(from:)",
  "metadataVersion" : "0.1.0",
  "role" : "Initializer",
  "symbol" : {
    "kind" : "Initializer",
    "modules" : [
      "Spatial"
    ],
    "preciseIdentifier" : "s:So7SPAnglea7SpatialE4fromABs7Decoder_p_tKcfc"
  },
  "title" : "init(from:)"
}
-->

# init(from:)

Creates a new instance by decoding from the given decoder.

```
init(from decoder: any Decoder) throws
```

## Parameters

`decoder`

The decoder to read data from.

---

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)