Qt Jambi Home

com.trolltech.qt.core
Enum Qt.ImageConversionFlag

java.lang.Object
  extended by java.lang.Enum<Qt.ImageConversionFlag>
      extended by com.trolltech.qt.core.Qt.ImageConversionFlag
All Implemented Interfaces:
QtEnumerator, java.io.Serializable, java.lang.Comparable<Qt.ImageConversionFlag>
Enclosing interface:
Qt

public static enum Qt.ImageConversionFlag
extends java.lang.Enum<Qt.ImageConversionFlag>
implements QtEnumerator

The options marked "(default)" are set if no other values from the list are included (since the defaults are zero).

Color/Mono preference (ignored for QBitmap):

ConstantValueDescription
AutoColor0(default) - If the image has depth 1 and contains only black and white pixels, the pixmap becomes monochrome.
ColorOnly3The pixmap is dithered/converted to the native display depth.
MonoOnly2The pixmap becomes monochrome. If necessary, it is dithered using the chosen dithering algorithm.

Dithering mode preference for RGB channels:

ConstantValueDescription
DiffuseDither0(default) - A high-quality dither.
OrderedDither16A faster, more ordered dither.
ThresholdDither32No dithering; closest color is used.

Dithering mode preference for alpha channel:

ConstantValueDescription
ThresholdAlphaDither0(default) - No dithering.
OrderedAlphaDither4A faster, more ordered dither.
DiffuseAlphaDither8A high-quality dither.

Color matching versus dithering preference:

ConstantValueDescription
PreferDither64(default when converting to a pixmap) - Always dither 32-bit images when the image is converted to 8 bits.
AvoidDither128(default when converting for the purpose of saving to file) - Dither 32-bit images only if the image has more than 256 colors and it is being converted to 8 bits.


Enum Constant Summary
AlphaDither_Mask
          Internal.
AutoColor
          (default) - If the image has depth 1 and contains only black and white pixels, the pixmap becomes monochrome.
AvoidDither
          (default when converting for the purpose of saving to file) - Dither 32-bit images only if the image has more than 256 colors and it is being converted to 8 bits.
ColorMode_Mask
          Internal.
DiffuseAlphaDither
          A high-quality dither.
Dither_Mask
          Internal.
DitherMode_Mask
          Internal.
MonoOnly
          The pixmap becomes monochrome.
OrderedAlphaDither
          A faster, more ordered dither.
OrderedDither
          A faster, more ordered dither.
PreferDither
          (default when converting to a pixmap) - Always dither 32-bit images when the image is converted to 8 bits.
ThresholdDither
          No dithering; closest color is used.
 
Method Summary
static Qt.ImageConversionFlags createQFlags(Qt.ImageConversionFlag... values)
           
static Qt.ImageConversionFlag resolve(int value)
           
 int value()
          This function should return an integer value for the enum values of the enumeration that implements this interface.
static Qt.ImageConversionFlag valueOf(java.lang.String name)
          Returns the enum constant of this type with the specified name.
static Qt.ImageConversionFlag[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

ColorMode_Mask

public static final Qt.ImageConversionFlag ColorMode_Mask
Internal.


AutoColor

public static final Qt.ImageConversionFlag AutoColor

(default) - If the image has depth 1 and contains only black and white pixels, the pixmap becomes monochrome.


MonoOnly

public static final Qt.ImageConversionFlag MonoOnly

The pixmap becomes monochrome. If necessary, it is dithered using the chosen dithering algorithm.


AlphaDither_Mask

public static final Qt.ImageConversionFlag AlphaDither_Mask
Internal.


OrderedAlphaDither

public static final Qt.ImageConversionFlag OrderedAlphaDither

A faster, more ordered dither.


DiffuseAlphaDither

public static final Qt.ImageConversionFlag DiffuseAlphaDither

A high-quality dither.


Dither_Mask

public static final Qt.ImageConversionFlag Dither_Mask
Internal.


OrderedDither

public static final Qt.ImageConversionFlag OrderedDither

A faster, more ordered dither.


ThresholdDither

public static final Qt.ImageConversionFlag ThresholdDither

No dithering; closest color is used.


DitherMode_Mask

public static final Qt.ImageConversionFlag DitherMode_Mask
Internal.


PreferDither

public static final Qt.ImageConversionFlag PreferDither

(default when converting to a pixmap) - Always dither 32-bit images when the image is converted to 8 bits.


AvoidDither

public static final Qt.ImageConversionFlag AvoidDither

(default when converting for the purpose of saving to file) - Dither 32-bit images only if the image has more than 256 colors and it is being converted to 8 bits.

Method Detail

values

public static Qt.ImageConversionFlag[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
for (Qt.ImageConversionFlag c : Qt.ImageConversionFlag.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared

valueOf

public static Qt.ImageConversionFlag valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
java.lang.NullPointerException - if the argument is null

value

public int value()
Description copied from interface: QtEnumerator
This function should return an integer value for the enum values of the enumeration that implements this interface.

Specified by:
value in interface QtEnumerator

createQFlags

public static Qt.ImageConversionFlags createQFlags(Qt.ImageConversionFlag... values)

resolve

public static Qt.ImageConversionFlag resolve(int value)

Qt Jambi Home