VectSharp  2.2.1
A light library for C# vector graphics
VectSharp.ImageSharpUtils.RasterImageStream Class Reference

A RasterImage created from a stream. More...

Inheritance diagram for VectSharp.ImageSharpUtils.RasterImageStream:

Public Member Functions

 RasterImageStream (Stream imageStream, bool alpha=true, bool interpolate=true)
 Creates a new RasterImage from the specified stream. More...
 
 RasterImageStream (IntPtr imageAddress, int imageLength, bool alpha=true, bool interpolate=true)
 Creates a new RasterImage from the specified stream. More...
 
- Public Member Functions inherited from VectSharp.RasterImage
 RasterImage (IntPtr pixelData, int width, int height, bool hasAlpha, bool interpolate)
 Creates a new RasterImage instance from the specified pixel data in RGB or RGBA format. More...
 
 RasterImage (ref DisposableIntPtr pixelData, int width, int height, bool hasAlpha, bool interpolate)
 Creates a new RasterImage instance from the specified pixel data in RGB or RGBA format. More...
 
 RasterImage (byte[] data, int width, int height, PixelFormats pixelFormat, bool interpolate)
 Creates a new RasterImage instance copying the specified pixel data. More...
 
void ClearPNGCache ()
 Disposes the PNGStream. Also useful if is is necessary to regenerate it, e.g. because the underlying image pixel data has changed. More...
 
void Dispose ()
 

Additional Inherited Members

- Properties inherited from VectSharp.RasterImage
IntPtr ImageDataAddress [get]
 The memory address of the image pixel data. More...
 
IDisposable DataHolder [get]
 An IDisposable that will be disposed when the image is disposed. More...
 
string Id [get]
 A univocal identifier for this image. More...
 
bool HasAlpha [get]
 Determines whether the image has an alpha channel. More...
 
int Width [get]
 The width in pixels of the image. More...
 
int Height [get]
 The height in pixels of the image. More...
 
bool Interpolate [get]
 Determines whether the image should be interpolated when it is resized. More...
 
MemoryStream PNGStream [get]
 Contains a representation of the image in PNG format. Generated at the first access and cached until the image is disposed. More...
 

Detailed Description

A RasterImage created from a stream.

Definition at line 106 of file RasterImages.cs.

Constructor & Destructor Documentation

◆ RasterImageStream() [1/2]

VectSharp.ImageSharpUtils.RasterImageStream.RasterImageStream ( Stream  imageStream,
bool  alpha = true,
bool  interpolate = true 
)

Creates a new RasterImage from the specified stream.

Parameters
imageStreamThe stream containing the image data.
alphaA boolean value indicating whether transparency (alpha) data from the image should be preserved or not.
interpolateA boolean value indicating whether the image should be interpolated when it is resized or not.

Definition at line 114 of file RasterImages.cs.

◆ RasterImageStream() [2/2]

VectSharp.ImageSharpUtils.RasterImageStream.RasterImageStream ( IntPtr  imageAddress,
int  imageLength,
bool  alpha = true,
bool  interpolate = true 
)

Creates a new RasterImage from the specified stream.

Parameters
imageAddressA pointer to the address where the image data is contained.
imageLengthThe length in bytes of the image data.
alphaA boolean value indicating whether transparency (alpha) data from the image should be preserved or not.
interpolateA boolean value indicating whether the image should be interpolated when it is resized or not.

Definition at line 185 of file RasterImages.cs.


The documentation for this class was generated from the following file: