|
|
@ -49,27 +49,27 @@ namespace ImageProcessor |
|
|
/// Gets the Y luminance component.
|
|
|
/// Gets the Y luminance component.
|
|
|
/// <remarks>A value ranging between 0 and 255.</remarks>
|
|
|
/// <remarks>A value ranging between 0 and 255.</remarks>
|
|
|
/// </summary>
|
|
|
/// </summary>
|
|
|
public float Y { get; } |
|
|
public readonly float Y; |
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
/// <summary>
|
|
|
/// Gets the Cb chroma component.
|
|
|
/// Gets the Cb chroma component.
|
|
|
/// <remarks>A value ranging between 0 and 255.</remarks>
|
|
|
/// <remarks>A value ranging between 0 and 255.</remarks>
|
|
|
/// </summary>
|
|
|
/// </summary>
|
|
|
public float Cb { get; } |
|
|
public readonly float Cb; |
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
/// <summary>
|
|
|
/// Gets the Cr chroma component.
|
|
|
/// Gets the Cr chroma component.
|
|
|
/// <remarks>A value ranging between 0 and 255.</remarks>
|
|
|
/// <remarks>A value ranging between 0 and 255.</remarks>
|
|
|
/// </summary>
|
|
|
/// </summary>
|
|
|
public float Cr { get; } |
|
|
public readonly float Cr; |
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
/// <summary>
|
|
|
/// Gets a value indicating whether this <see cref="YCbCr"/> is empty.
|
|
|
/// Gets a value indicating whether this <see cref="YCbCr"/> is empty.
|
|
|
/// </summary>
|
|
|
/// </summary>
|
|
|
[EditorBrowsable(EditorBrowsableState.Never)] |
|
|
[EditorBrowsable(EditorBrowsableState.Never)] |
|
|
public bool IsEmpty => Math.Abs(this.Y) < Epsilon |
|
|
public bool IsEmpty => Math.Abs(this.Y) < Epsilon |
|
|
&& Math.Abs(this.Cb) < Epsilon |
|
|
&& Math.Abs(this.Cb) < Epsilon |
|
|
&& Math.Abs(this.Cr) < Epsilon; |
|
|
&& Math.Abs(this.Cr) < Epsilon; |
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
/// <summary>
|
|
|
/// Compares two <see cref="YCbCr"/> objects. The result specifies whether the values
|
|
|
/// Compares two <see cref="YCbCr"/> objects. The result specifies whether the values
|
|
|
|