namespace ScreenConnect; public class PixelInfo { public int BitsPerChannel { get; } public int BitsPerPixel { get; } public int BytesPerPixel { get; } protected PixelInfo(int bitsPerPixel, int bitsPerChannel) { BitsPerPixel = bitsPerPixel; BytesPerPixel = bitsPerPixel / 8; BitsPerChannel = bitsPerChannel; } public override bool Equals(object obj) { if (obj is PixelInfo pixelInfo) { return pixelInfo.BitsPerPixel == BitsPerPixel; } return false; } public override int GetHashCode() { return BitsPerPixel.GetHashCode(); } }