<!--
{
  "availability" : [
    "macOS: 26.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "CompositorServices",
  "identifier" : "/documentation/CompositorServices/LayerRenderer/Frame/predictTiming()",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "Compositor Services",
      "CompositorServices"
    ],
    "preciseIdentifier" : "s:So10cp_frame_tV18CompositorServicesE13predictTimingSo0a1_B9_timing_tVSgyF"
  },
  "title" : "predictTiming()"
}
-->

# predictTiming()

Computes and returns the predicted timing information for the frame.

```
func predictTiming() -> LayerRenderer.Frame.Timing?
```

## Return Value

The predicted timing information for the specified frame, or `nil`
if the layer is in the `Layer.State.paused` or `Layer.State.invalidated` state.

## Discussion

The returned timing information contains the frame-related deadlines to meet during the rendering process.
For example, wait until the time in `optimalInputTime` to start the submission phase of your frame update.
This function updates the frame-specific timing information with the latest data from Compositor Services before it returns it.

Don’t call this function after you call [`queryDrawable()`](/documentation/CompositorServices/LayerRenderer/Frame/queryDrawable()) for the specified frame.
After you retrieve the frame’s [`LayerRenderer.Drawable`](/documentation/CompositorServices/LayerRenderer/Drawable) type, get the timing information from the drawable’s [`frameTiming`](/documentation/CompositorServices/LayerRenderer/Drawable/frameTiming) property instead.

---

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)