Skip to content

Commit

Permalink
Update AlphaOption.cs xml docs
Browse files Browse the repository at this point in the history
This copies over the descriptions from the official docs.
  • Loading branch information
kmgallahan authored Oct 21, 2023
1 parent 1f004f6 commit 54385ee
Showing 1 changed file with 26 additions and 12 deletions.
38 changes: 26 additions & 12 deletions src/Magick.NET.Core/Enums/AlphaOption.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,27 +14,34 @@ public enum AlphaOption
Undefined,

/// <summary>
/// Activate.
/// Enable the image's transparency channel. Note that normally Set should be used instead of

Check warning on line 17 in src/Magick.NET.Core/Enums/AlphaOption.cs

View workflow job for this annotation

GitHub Actions / MacOS (Q8/Q16/Q16-HDRI)

/// this, unless you specifically need to preserve the existing (but specifically turned Off)

Check warning on line 18 in src/Magick.NET.Core/Enums/AlphaOption.cs

View workflow job for this annotation

GitHub Actions / MacOS (Q8/Q16/Q16-HDRI)

/// transparency channel.
/// </summary>
Activate,

/// <summary>
/// Associate.
/// Associate the alpha channel with the image.
/// </summary>
Associate,

/// <summary>
/// Background.
/// Set any fully-transparent pixel to the background color, while leaving it fully-transparent.

Check warning on line 29 in src/Magick.NET.Core/Enums/AlphaOption.cs

View workflow job for this annotation

GitHub Actions / MacOS (Q8/Q16/Q16-HDRI)

/// This can make some image file formats, such as PNG, smaller as the RGB values of transparent

Check warning on line 30 in src/Magick.NET.Core/Enums/AlphaOption.cs

View workflow job for this annotation

GitHub Actions / MacOS (Q8/Q16/Q16-HDRI)

/// pixels are more uniform, and thus can compress better.
/// </summary>
Background,

/// <summary>
/// Copy.
/// Turns 'On' the alpha/matte channel, then copies the grayscale intensity of the image, into

Check warning on line 36 in src/Magick.NET.Core/Enums/AlphaOption.cs

View workflow job for this annotation

GitHub Actions / MacOS (Q8/Q16/Q16-HDRI)

/// the alpha channel, converting a grayscale mask into a transparent shaped mask ready to be

Check warning on line 37 in src/Magick.NET.Core/Enums/AlphaOption.cs

View workflow job for this annotation

GitHub Actions / MacOS (Q8/Q16/Q16-HDRI)

/// colored appropriately. The color channels are not modified.
/// </summary>
Copy,

/// <summary>
/// Deactivate.
/// Disables the image's transparency channel. This does not delete or change the existing data,

Check warning on line 43 in src/Magick.NET.Core/Enums/AlphaOption.cs

View workflow job for this annotation

GitHub Actions / MacOS (Q8/Q16/Q16-HDRI)

/// it just turns off the use of that data.
/// </summary>
Deactivate,

Expand All @@ -44,12 +51,14 @@ public enum AlphaOption
Discrete,

/// <summary>
/// Disassociate.
/// Disassociate the alpha channel from the image.
/// </summary>
Disassociate,

/// <summary>
/// Extract.
/// Copies the alpha channel values into all the color channels and turns 'Off' the image's

Check warning on line 59 in src/Magick.NET.Core/Enums/AlphaOption.cs

View workflow job for this annotation

GitHub Actions / MacOS (Q8/Q16/Q16-HDRI)

/// transparency, so as to generate a grayscale mask of the image's shape. The alpha channel

Check warning on line 60 in src/Magick.NET.Core/Enums/AlphaOption.cs

View workflow job for this annotation

GitHub Actions / MacOS (Q8/Q16/Q16-HDRI)

/// data is left intact just deactivated. This is the inverse of 'Copy'.
/// </summary>
Extract,

Expand All @@ -64,27 +73,32 @@ public enum AlphaOption
On,

/// <summary>
/// Opaque.
/// Enables the alpha/matte channel and forces it to be fully opaque.
/// </summary>
Opaque,

/// <summary>
/// Remove.
/// Composite the image over the background color.
/// </summary>
Remove,

/// <summary>
/// Set.
/// Activates the alpha/matte channel. If it was previously turned off then it also

Check warning on line 86 in src/Magick.NET.Core/Enums/AlphaOption.cs

View workflow job for this annotation

GitHub Actions / MacOS (Q8/Q16/Q16-HDRI)

/// resets the channel to opaque. If the image already had the alpha channel turned on,
/// it will have no effect.
/// </summary>
Set,

/// <summary>
/// Shape.
/// As per 'Copy' but also colors the resulting shape mask with the current background color.
/// That is the RGB color channels is replaced, with appropriate alpha shape.
/// </summary>
Shape,

/// <summary>
/// Transparent.
/// Activates the alpha/matte channel and forces it to be fully transparent. This effectively
/// creates a fully transparent image the same size as the original and with all its original
/// RGB data still intact, but fully transparent.
/// </summary>
Transparent,
}

0 comments on commit 54385ee

Please sign in to comment.