Table of Contents

Struct ImageParameters

Namespace
SharpDX.WIC
Assembly
SharpDX.Direct2D1.dll

This defines parameters that you can use to override the default parameters normally used when encoding an image.

public struct ImageParameters
Inherited Members

Remarks

If this parameter is not passed to the encoding API, the encoder uses these settings.

  • A pixel format of (DXGI_FORMAT_B8G8R8A8_UNORM, D2D1_ALPHA_MODE_PREMULTIPLIED).
  • An x and y DPI of 96.
  • The entire image bounds will be used for encoding.
Note??The parameters as specified can't result in a scale. The encoder can use a larger portion of the input image based on the passed in DPI and the pixel width and height.?

Constructors

ImageParameters(PixelFormat, float, float, float, float, int, int)

Initializes a new instance of the ImageParameters struct.

public ImageParameters(PixelFormat pixelFormat, float dpiX, float dpiY, float top, float left, int pixelWidth, int pixelHeight)

Parameters

pixelFormat PixelFormat

The pixel format.

dpiX float

The dpi X.

dpiY float

The dpi Y.

top float

The top.

left float

The left.

pixelWidth int

Width in pixel.

pixelHeight int

Height in pixel.

Fields

DpiX

The DPI in the x dimension.

public float DpiX

Field Value

float

DpiY

The DPI in the y dimension.

public float DpiY

Field Value

float

Left

The left corner in pixels of the image space to be encoded to the destination.

public float Left

Field Value

float

PixelFormat

The pixel format to which the image is processed before it is written to the encoder.

public PixelFormat PixelFormat

Field Value

PixelFormat

PixelHeight

The height in pixels of the part of the image to write.

public int PixelHeight

Field Value

int

PixelWidth

The width in pixels of the part of the image to write.

public int PixelWidth

Field Value

int

Top

The top corner in pixels of the image space to be encoded to the destination.

public float Top

Field Value

float