Class ScreenCapture
- Namespace
- HelixToolkit.SharpDX.Utilities
- Assembly
- HelixToolkit.SharpDX.dll
public static class ScreenCapture
- Inheritance
-
ScreenCapture
- Inherited Members
Methods
CaptureTexture(DeviceContext, Texture2D?, out Texture2D?)
Captures the texture.
public static bool CaptureTexture(DeviceContext context, Texture2D? source, out Texture2D? stagingTexture)
Parameters
contextDeviceContextThe context.
sourceTexture2DThe source.
stagingTextureTexture2DThe staging texture.
Returns
SaveWICTextureToBitmapStream(IDeviceResources, Texture2D?, MemoryStream)
Saves the wic texture to bitmap stream.
public static bool SaveWICTextureToBitmapStream(IDeviceResources deviceResource, Texture2D? source, MemoryStream bitmapStream)
Parameters
deviceResourceIDeviceResourcesThe device resource.
sourceTexture2DThe source.
bitmapStreamMemoryStreamThe bitmap stream.
Returns
Exceptions
SaveWICTextureToFile(IDeviceResources, Texture2D?, string, Direct2DImageFormat)
Saves the wic texture to file.
public static bool SaveWICTextureToFile(IDeviceResources deviceResource, Texture2D? source, string file, Direct2DImageFormat format)
Parameters
deviceResourceIDeviceResourcesThe device resource.
sourceTexture2DThe source.
filestringThe file.
formatDirect2DImageFormatThe format.
Returns
SaveWICTextureToFile(IDeviceResources, Texture2D?, string, Guid)
Saves the wic texture to file.
public static bool SaveWICTextureToFile(IDeviceResources deviceResource, Texture2D? source, string fileName, Guid containerFormat)
Parameters
deviceResourceIDeviceResourcesThe device resource.
sourceTexture2DThe source.
fileNamestringName of the file.
containerFormatGuidThe container format.