TSdlMetalView
A a CAMetalLayer-backed NSView (macOS) or UIView (iOS/tvOS).
Definition
Unit: Neslib.Sdl3.Video
Properties
Name | Description |
---|---|
Layer | The (Objective-C) ID of the backing CAMetalLayer for this viuew. You can use TCAMetalLayer.Wrap to access this layer. |
View | The (Objective-C) ID of this metal view. You can use TNSView.Wrap (on macOS) or TUIView.Wrap (on IOS) to get the underlying NSView or UIView. |
Constructors
Name | Description |
---|---|
Create | Create a CAMetalLayer-backed NSView/UIView and attach it to the specified window. |
Operators
Name | Description |
---|---|
Equal(TSdlMetalView, TSdlMetalView) | Used to compare against another TSdlMetalView. |
Equal(TSdlMetalView, Pointer) | Used to compare against nil . |
Implicit | Used to set the value to nil . |
NotEqual(TSdlMetalView, TSdlMetalView) | Used to compare against another TSdlMetalView. |
NotEqual(TSdlMetalView, Pointer) | Used to compare against nil . |
Methods
Name | Description |
---|---|
Free | Destroy this TSdlMetalView object. |
Property Descriptions
Layer
The (Objective-C) ID of the backing CAMetalLayer for this viuew. You can use TCAMetalLayer.Wrap to access this layer.
property Layer: Pointer read GetLayer
Type: Pointer
View
The (Objective-C) ID of this metal view. You can use TNSView.Wrap (on macOS) or TUIView.Wrap (on IOS) to get the underlying NSView or UIView.
property View: Pointer read GetView
Type: Pointer
Constructor Descriptions
Create
Create a CAMetalLayer-backed NSView/UIView and attach it to the specified window.
On macOS, this does not associate a MTLDevice with the CAMetalLayer on its own. It is up to user code to do that.
The View property can by cast to a NSView (macOS) or UIView (iOS) using TNSView.Wrap() or TUIView.Wrap(). To access the backing CAMetalLayer, use the Layer property and wrap it using TCAMetalLayer.Wrap().
constructor Create(const AWindow: TSdlWindow)
Parameters
AWindow
: TSdlWindow
: The window.
See Also
Operator Descriptions
Equal(TSdlMetalView, TSdlMetalView)
Used to compare against another TSdlMetalView.
class operator Equal(const ALeft, ARight: TSdlMetalView): Boolean; inline; static
Parameters
ALeft
: TSdlMetalView
ARight
: TSdlMetalView
Returns
Boolean
Equal(TSdlMetalView, Pointer)
Used to compare against nil
.
class operator Equal(const ALeft: TSdlMetalView; const ARight: Pointer): Boolean; inline; static
Parameters
ALeft
: TSdlMetalView
ARight
: Pointer
Returns
Boolean
Implicit(Pointer)
Used to set the value to nil
.
class operator Implicit(const AValue: Pointer): TSdlMetalView; inline; static
Parameters
AValue
: Pointer
Returns
NotEqual(TSdlMetalView, TSdlMetalView)
Used to compare against another TSdlMetalView.
class operator NotEqual(const ALeft, ARight: TSdlMetalView): Boolean; inline; static
Parameters
ALeft
: TSdlMetalView
ARight
: TSdlMetalView
Returns
Boolean
NotEqual(TSdlMetalView, Pointer)
Used to compare against nil
.
class operator NotEqual(const ALeft: TSdlMetalView; const ARight: Pointer): Boolean; inline; static
Parameters
ALeft
: TSdlMetalView
ARight
: Pointer
Returns
Boolean
Method Descriptions
Free
Destroy this TSdlMetalView object.
This should be called destroying the window, if it was created after the window was created..
procedure Free; inline