Class QoiEncoder
- Namespace
- SixLabors.ImageSharp.Formats.Qoi
- Assembly
- SixLabors.ImageSharp.dll
Image encoder for writing an image to a stream as a QOI image
public class QoiEncoder : ImageEncoder, IImageEncoder
- Inheritance
-
QoiEncoder
- Implements
- Inherited Members
Constructors
QoiEncoder()
public QoiEncoder()
Properties
Channels
Gets the color channels on the image that can be RGB or RGBA. This is purely informative. It doesn't change the way data chunks are encoded.
public QoiChannels? Channels { get; init; }
Property Value
ColorSpace
Gets the color space of the image that can be sRGB with linear alpha or all channels linear. This is purely informative. It doesn't change the way data chunks are encoded.
public QoiColorSpace? ColorSpace { get; init; }
Property Value
Methods
Encode<TPixel>(Image<TPixel>, Stream, CancellationToken)
Encodes the image to the specified stream from the Image<TPixel>.
protected override void Encode<TPixel>(Image<TPixel> image, Stream stream, CancellationToken cancellationToken) where TPixel : unmanaged, IPixel<TPixel>
Parameters
image
Image<TPixel>The Image<TPixel> to encode from.
stream
StreamThe Stream to encode the image data to.
cancellationToken
CancellationTokenThe token to monitor for cancellation requests.
Type Parameters
TPixel
The pixel format.
Remarks
This method is designed to support the ImageSharp internal infrastructure and is not recommended for direct use.