←Select platform

AutoColorLevelCommandType Enumeration

Summary
Enumeration flags that identify the type of leveling to perform.
Syntax
C#
Objective-C
C++/CLI
Java
Python
public enum AutoColorLevelCommandType   
typedef NS_ENUM(NSInteger, LTAutoColorLevelCommandType) { 
 LTAutoColorLevelCommandTypeNone = 0x0000,  
 LTAutoColorLevelCommandTypeLevel = 0x00000001,  
 LTAutoColorLevelCommandTypeContrast = 0x00000002,  
 LTAutoColorLevelCommandTypeIntensity = 0x00000003,  
}; 
public final class AutoColorLevelCommandType 
    extends java.lang.Enum<AutoColorLevelCommandType> 
public enum class AutoColorLevelCommandType   
class AutoColorLevelCommandType(Enum): 
   None = 0 
   Level = 1 
   Contrast = 2 
   Intensity = 3 
Members
ValueMemberDescription
0None No change.
1Level Perform leveling on the individual R, G and B channels, treating each of the R, G and B channels as a separate entity. It introduces color cast on the image.
2Contrast Perform leveling on the Master channel (the grayscale values of the pixels). No color cast will be introduced.

In order to speed up widely used image processing filters in LEADTOOLS, the grayscale value (master channel) of a colored image is calculated using the following formulas:

        #define CalcGrayValue(r, g, b) ((L_UCHAR)(((L_UCHAR) (((2 * (L_UINT) (r)) + (5 * (L_UINT) (g)) + (L_UINT) (b) + 4) / 8))))
        #define CalcGrayValue16(r, g, b) ((L_UINT16) (((2 * (L_UINT32) (r)) + (5 * (L_UINT32) (g)) + (L_UINT32) (b) + 4) / 8))
        #define CalcGrayValue32(r, g, b) ((L_UINT32) (((2 * (L_UINT32) (r)) + (5 * (L_UINT32) (g)) + (L_UINT32) (b) + 4) / 8))

3Intensity Perform leveling on the RGB channel (the sum of the R, G, and B channels). No color cast will be introduced.
Requirements

Target Platforms

Help Version 23.0.2024.3.3
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2024 LEAD Technologies, Inc. All Rights Reserved.

Leadtools.ImageProcessing.Color Assembly

Products | Support | Contact Us | Intellectual Property Notices
© 1991-2023 LEAD Technologies, Inc. All Rights Reserved.