-
-
Notifications
You must be signed in to change notification settings - Fork 855
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1420 from SixLabors/js/pixel-type-info
Add new PixelAlphaRepresentation property and implement for TPixel types
- Loading branch information
Showing
91 changed files
with
2,304 additions
and
671 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
// Copyright (c) Six Labors. | ||
// Licensed under the Apache License, Version 2.0. | ||
|
||
namespace SixLabors.ImageSharp.PixelFormats | ||
{ | ||
/// <summary> | ||
/// Provides enumeration of the alpha value transparency behavior of a pixel format. | ||
/// </summary> | ||
public enum PixelAlphaRepresentation | ||
{ | ||
/// <summary> | ||
/// Indicates that the pixel format does not contain an alpha channel. | ||
/// </summary> | ||
None, | ||
|
||
/// <summary> | ||
/// Indicates that the transparency behavior is premultiplied. | ||
/// Each color is first scaled by the alpha value. The alpha value itself is the same | ||
/// in both straight and premultiplied alpha. Typically, no color channel value is | ||
/// greater than the alpha channel value. | ||
/// If a color channel value in a premultiplied format is greater than the alpha | ||
/// channel, the standard source-over blending math results in an additive blend. | ||
/// </summary> | ||
Associated, | ||
|
||
/// <summary> | ||
/// Indicates that the transparency behavior is not premultiplied. | ||
/// The alpha channel indicates the transparency of the color. | ||
/// </summary> | ||
Unassociated | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.