Skip to content

PixelRect

Namespace Nfty.Core.Editing in assembly Nfty.Core.

public readonly struct PixelRect : IEquatable<PixelRect>

An integer pixel rectangle (top-left origin).

Constructors

PixelRect(int, int, int, int)

public PixelRect(int X, int Y, int Width, int Height);

Parameters

  • X (int) - Left edge, in pixels from the image's left.
  • Y (int) - Top edge, in pixels from the image's top.
  • Width (int) - Width in pixels.
  • Height (int) - Height in pixels.

Properties

Height

public int Height { get; init; }

Height in pixels.

Width

public int Width { get; init; }

Width in pixels.

X

public int X { get; init; }

Left edge, in pixels from the image's left.

Y

public int Y { get; init; }

Top edge, in pixels from the image's top.