Instance Property

delegate

The view’s delegate.

Declaration

weak var delegate: MTKViewDelegate? { get set }

Discussion

A delegate is optional. If a delegate is provided, it is called instead of the draw(_:) method whenever the view’s contents need to be drawn. You should either provide a delegate or subclass the view to override the draw(_:) method, but not both.