Table of Contents

Enum UnitMode

Namespace
SharpDX.Direct2D1
Assembly
SharpDX.Direct2D1.dll

Specifies how units in Direct2D will be interpreted.

public enum UnitMode

Fields

Dips = 0

Units will be interpreted as device-independent pixels (1/96").

Pixels = 1

Units will be interpreted as pixels.

Remarks

Setting the unit mode to D2D1_UNIT_MODE_PIXELS is similar to setting the DeviceContext dots per inch (dpi) to 96. However, Direct2D still checks the dpi to determine the threshold for enabling vertical antialiasing for text, and when the unit mode is restored, the dpi will be remembered.