Method GetBitmap
- Namespace
- PaintDotNet.Effects
- Assembly
- PaintDotNet.Effects.Core.dll
GetBitmap(in PixelFormat)
Gets a bitmap that renders the layer's contents in the requested pixel format.
IEffectInputBitmap GetBitmap(in PixelFormat pixelFormat)
Parameters
pixelFormat
PixelFormatThe requested pixel format for the bitmap. The native pixel format used by Paint.NET is currently Bgra32, which can be accessed using the ColorBgra32 struct. Specifying a different pixel format is valid, but will incur conversion overhead.
Returns
- IEffectInputBitmap
The bitmap.
Remarks
This bitmap does not take Visible or Opacity into account.
When retrieving a bitmap in a floating-point pixel format, such as Rgba128Float,
linear gamma will be used. The source will be converted if necessary. If the working space of the document
(ColorContext) cannot be linearized, then scRGB (aka linearized sRGB)
will be used instead.