<!--
{
  "availability" : [
    "iOS: -",
    "visionOS: 1.0.0 - 2.0.0"
  ],
  "documentType" : "symbol",
  "framework" : "CompositorServices",
  "identifier" : "/documentation/CompositorServices/LayerRenderer/Drawable/View/tangents",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Property",
  "symbol" : {
    "kind" : "Instance Property",
    "modules" : [
      "Compositor Services",
      "CompositorServices"
    ],
    "preciseIdentifier" : "c:@F@cp_view_get_tangents"
  },
  "title" : "tangents"
}
-->

# tangents

The tangent values for the angles you use to determine the planes of the viewing frustum.

```
var tangents: simd_float4 { get }
```

## Discussion

In a 3D scene, the viewing frustum is the volume between the near and far clipping planes that contains the scene’s visible content.
When you render this content into a view, you generate a two-dimensional version of your content suitable for display.
To ensure your content still looks three-dimensional, apply a perspective projection matrix to your content.
This matrix scales your content appropriately based on its distance from the viewing point.

This function returns the tangent values you use to build the perspective projection matrix for your content.
You can also use the values to determine the apparent size of the view at any distance from the viewing point.
When you multiply a tangent value by a distance, you obtain the horizontal
or vertical distance from the view’s center point to the corresponding rectangle edge at that distance.
For a perspective projection matrix, multiply these values by the distance
to the near clipping plane and combine them to create the matrix rows you need.

> Note: The angles and tangent values are always positive.

---

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)