<!--
{
  "availability" : [
    "macOS: 26.0.0 -",
    "visionOS: 2.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "CompositorServices",
  "identifier" : "/documentation/CompositorServices/LayerRenderer/Drawable/computeProjection(convention:viewIndex:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "Compositor Services",
      "CompositorServices"
    ],
    "preciseIdentifier" : "s:So13cp_drawable_tV18CompositorServicesE17computeProjection10convention9viewIndexSo13simd_float4x4aSo0a16_axis_direction_G0V_SitF"
  },
  "title" : "computeProjection(convention:viewIndex:)"
}
-->

# computeProjection(convention:viewIndex:)

```
func computeProjection(convention: AxisDirectionConvention = .rightUpBack, viewIndex: Int) -> matrix_float4x4
```

---

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)