Show / Hide Table of Contents

Class SwapchainSource

A platform-specific object representing a renderable surface. A SwapchainSource can be created with one of several static factory methods. A SwapchainSource is used to describe a Swapchain (see SwapchainDescription).

Inheritance
System.Object
SwapchainSource
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: Veldrid
Assembly: cs.temp.dll.dll
Syntax
public abstract class SwapchainSource

Methods

CreateAndroidSurface(IntPtr, IntPtr)

Creates a new SwapchainSource for the given Android Surface.

Declaration
public static SwapchainSource CreateAndroidSurface(IntPtr surfaceHandle, IntPtr jniEnv)
Parameters
Type Name Description
System.IntPtr surfaceHandle

The handle of the Android Surface.

System.IntPtr jniEnv

The Java Native Interface Environment handle.

Returns
Type Description
SwapchainSource

A new SwapchainSource which can be used to create a Vulkan Swapchain or an OpenGLES GraphicsDevice for the given Android Surface.

CreateNSView(IntPtr)

Creates a new SwapchainSource for the given NSView.

Declaration
public static SwapchainSource CreateNSView(IntPtr nsView)
Parameters
Type Name Description
System.IntPtr nsView

A pointer to an NSView.

Returns
Type Description
SwapchainSource

A new SwapchainSource which can be used to create a Metal Swapchain for the given NSView.

CreateNSWindow(IntPtr)

Creates a new SwapchainSource for the given NSWindow.

Declaration
public static SwapchainSource CreateNSWindow(IntPtr nsWindow)
Parameters
Type Name Description
System.IntPtr nsWindow

A pointer to an NSWindow.

Returns
Type Description
SwapchainSource

A new SwapchainSource which can be used to create a Metal Swapchain for the given NSWindow.

CreateUIView(IntPtr)

Creates a new SwapchainSource for the given UIView.

Declaration
public static SwapchainSource CreateUIView(IntPtr uiView)
Parameters
Type Name Description
System.IntPtr uiView

The UIView's native handle.

Returns
Type Description
SwapchainSource

A new SwapchainSource which can be used to create a Metal Swapchain or an OpenGLES GraphicsDevice for the given UIView.

CreateUwp(Object, Single)

Creates a new SwapchainSource for a UWP SwapChain panel.

Declaration
public static SwapchainSource CreateUwp(object swapChainPanel, float logicalDpi)
Parameters
Type Name Description
System.Object swapChainPanel

A COM object which must implement the or interface. Generally, this should be a SwapChainPanel or SwapChainBackgroundPanel contained in your application window.

System.Single logicalDpi

The logical DPI of the swapchain panel.

Returns
Type Description
SwapchainSource

A new SwapchainSource which can be used to create a Swapchain for the given UWP panel.

CreateWayland(IntPtr, IntPtr)

Creates a new SwapchainSource from the given Wayland information.

Declaration
public static SwapchainSource CreateWayland(IntPtr display, IntPtr surface)
Parameters
Type Name Description
System.IntPtr display

The Wayland display proxy.

System.IntPtr surface

The Wayland surface proxy to map.

Returns
Type Description
SwapchainSource

A new SwapchainSource which can be used to create a Swapchain for the given Wayland surface.

CreateWin32(IntPtr, IntPtr)

Creates a new SwapchainSource for a Win32 window.

Declaration
public static SwapchainSource CreateWin32(IntPtr hwnd, IntPtr hinstance)
Parameters
Type Name Description
System.IntPtr hwnd

The Win32 window handle.

System.IntPtr hinstance

The Win32 instance handle.

Returns
Type Description
SwapchainSource

A new SwapchainSource which can be used to create a Swapchain for the given Win32 window.

CreateXlib(IntPtr, IntPtr)

Creates a new SwapchainSource from the given Xlib information.

Declaration
public static SwapchainSource CreateXlib(IntPtr display, IntPtr window)
Parameters
Type Name Description
System.IntPtr display

An Xlib Display.

System.IntPtr window

An Xlib Window.

Returns
Type Description
SwapchainSource

A new SwapchainSource which can be used to create a Swapchain for the given Xlib window.

Back to top