Skip to content

Commit 546507e

Browse files
authored
Update AlphaOption.cs xml docs (#1465)
1 parent 1f004f6 commit 546507e

File tree

1 file changed

+26
-12
lines changed

1 file changed

+26
-12
lines changed

src/Magick.NET.Core/Enums/AlphaOption.cs

Lines changed: 26 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -14,27 +14,34 @@ public enum AlphaOption
1414
Undefined,
1515

1616
/// <summary>
17-
/// Activate.
17+
/// Enable the image's transparency channel. Note that normally Set should be used instead of
18+
/// this, unless you specifically need to preserve the existing (but specifically turned Off)
19+
/// transparency channel.
1820
/// </summary>
1921
Activate,
2022

2123
/// <summary>
22-
/// Associate.
24+
/// Associate the alpha channel with the image.
2325
/// </summary>
2426
Associate,
2527

2628
/// <summary>
27-
/// Background.
29+
/// Set any fully-transparent pixel to the background color, while leaving it fully-transparent.
30+
/// This can make some image file formats, such as PNG, smaller as the RGB values of transparent
31+
/// pixels are more uniform, and thus can compress better.
2832
/// </summary>
2933
Background,
3034

3135
/// <summary>
32-
/// Copy.
36+
/// Turns 'On' the alpha/matte channel, then copies the grayscale intensity of the image, into
37+
/// the alpha channel, converting a grayscale mask into a transparent shaped mask ready to be
38+
/// colored appropriately. The color channels are not modified.
3339
/// </summary>
3440
Copy,
3541

3642
/// <summary>
37-
/// Deactivate.
43+
/// Disables the image's transparency channel. This does not delete or change the existing data,
44+
/// it just turns off the use of that data.
3845
/// </summary>
3946
Deactivate,
4047

@@ -44,12 +51,14 @@ public enum AlphaOption
4451
Discrete,
4552

4653
/// <summary>
47-
/// Disassociate.
54+
/// Disassociate the alpha channel from the image.
4855
/// </summary>
4956
Disassociate,
5057

5158
/// <summary>
52-
/// Extract.
59+
/// Copies the alpha channel values into all the color channels and turns 'Off' the image's
60+
/// transparency, so as to generate a grayscale mask of the image's shape. The alpha channel
61+
/// data is left intact just deactivated. This is the inverse of 'Copy'.
5362
/// </summary>
5463
Extract,
5564

@@ -64,27 +73,32 @@ public enum AlphaOption
6473
On,
6574

6675
/// <summary>
67-
/// Opaque.
76+
/// Enables the alpha/matte channel and forces it to be fully opaque.
6877
/// </summary>
6978
Opaque,
7079

7180
/// <summary>
72-
/// Remove.
81+
/// Composite the image over the background color.
7382
/// </summary>
7483
Remove,
7584

7685
/// <summary>
77-
/// Set.
86+
/// Activates the alpha/matte channel. If it was previously turned off then it also
87+
/// resets the channel to opaque. If the image already had the alpha channel turned on,
88+
/// it will have no effect.
7889
/// </summary>
7990
Set,
8091

8192
/// <summary>
82-
/// Shape.
93+
/// As per 'Copy' but also colors the resulting shape mask with the current background color.
94+
/// That is the RGB color channels is replaced, with appropriate alpha shape.
8395
/// </summary>
8496
Shape,
8597

8698
/// <summary>
87-
/// Transparent.
99+
/// Activates the alpha/matte channel and forces it to be fully transparent. This effectively
100+
/// creates a fully transparent image the same size as the original and with all its original
101+
/// RGB data still intact, but fully transparent.
88102
/// </summary>
89103
Transparent,
90104
}

0 commit comments

Comments
 (0)