<!--
{
  "availability" : [
    "iOS: 9.0.0 -",
    "iPadOS: 9.0.0 -",
    "macCatalyst: 13.1.0 -",
    "macOS: 10.11.0 -",
    "tvOS: 9.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "MetalKit",
  "identifier" : "/documentation/MetalKit/MTKView/currentDrawable",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Property",
  "symbol" : {
    "kind" : "Instance Property",
    "modules" : [
      "MetalKit"
    ],
    "preciseIdentifier" : "c:objc(cs)MTKView(py)currentDrawable"
  },
  "title" : "currentDrawable"
}
-->

# currentDrawable

The drawable to use for the current frame.

```
var currentDrawable: (any CAMetalDrawable)? { get }
```

## Discussion

If all drawable objects are in use, the value of this property is `nil`. Your app should check that [`currentDrawable`](/documentation/MetalKit/MTKView/currentDrawable) isn’t `nil` before attempting to draw. The view changes the value of this property only after returning from a drawing function, either <doc://com.apple.documentation/documentation/UIKit/UIView/draw(_:)> from a subclassed instance of the view, or [`draw(in:)`](/documentation/MetalKit/MTKViewDelegate/draw(in:)) from the view’s delegate.

Use a <doc://com.apple.documentation/documentation/Metal/MTLRenderCommandEncoder> object to render into the drawable’s texture and present it for display (typically registered using the <doc://com.apple.documentation/documentation/Metal/MTLCommandBuffer/present(_:)> method of a command buffer). Try to minimize the time between when you fetch the drawable and when you submit the command buffer that uses it. For more information, see <doc://com.apple.documentation/documentation/QuartzCore/CAMetalLayer>.

---

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)