Class TiffEncoder
Encoder for writing the data image to a stream in TIFF format.
Implements
Inherited Members
Namespace: SixLabors.ImageSharp.Formats.Tiff
Assembly: SixLabors.ImageSharp.dll
Syntax
public class TiffEncoder : IImageEncoder
Properties
| Improve this Doc View SourceBitsPerPixel
Declaration
public TiffBitsPerPixel? BitsPerPixel { get; set; }
Property Value
Type | Description |
---|---|
Nullable<TiffBitsPerPixel> |
Compression
Declaration
public TiffCompression? Compression { get; set; }
Property Value
Type | Description |
---|---|
Nullable<TiffCompression> |
CompressionLevel
Declaration
public DeflateCompressionLevel? CompressionLevel { get; set; }
Property Value
Type | Description |
---|---|
Nullable<DeflateCompressionLevel> |
HorizontalPredictor
Declaration
public TiffPredictor? HorizontalPredictor { get; set; }
Property Value
Type | Description |
---|---|
Nullable<TiffPredictor> |
PhotometricInterpretation
Declaration
public TiffPhotometricInterpretation? PhotometricInterpretation { get; set; }
Property Value
Type | Description |
---|---|
Nullable<TiffPhotometricInterpretation> |
Quantizer
Declaration
public IQuantizer Quantizer { get; set; }
Property Value
Type | Description |
---|---|
IQuantizer |
Methods
| Improve this Doc View SourceEncode<TPixel>(Image<TPixel>, Stream)
Encodes the image to the specified stream from the Image<TPixel>.
Declaration
public void Encode<TPixel>(Image<TPixel> image, Stream stream)
where TPixel : struct, IPixel<TPixel>
Parameters
Type | Name | Description |
---|---|---|
Image<TPixel> | image | The Image<TPixel> to encode from. |
Stream | stream | The Stream to encode the image data to. |
Type Parameters
Name | Description |
---|---|
TPixel | The pixel format. |
EncodeAsync<TPixel>(Image<TPixel>, Stream, CancellationToken)
Encodes the image to the specified stream from the Image<TPixel>.
Declaration
public Task EncodeAsync<TPixel>(Image<TPixel> image, Stream stream, CancellationToken cancellationToken)
where TPixel : struct, IPixel<TPixel>
Parameters
Type | Name | Description |
---|---|---|
Image<TPixel> | image | The Image<TPixel> to encode from. |
Stream | stream | The Stream to encode the image data to. |
CancellationToken | cancellationToken | The token to monitor for cancellation requests. |
Returns
Type | Description |
---|---|
Task | A Task representing the asynchronous operation. |
Type Parameters
Name | Description |
---|---|
TPixel | The pixel format. |