public final class C
extends java.lang.Object
Implements a color index model using a colix as a COLor IndeX.
A colix is a color index represented as a short int.
The value 0 is considered a null value ... for no color. In Jmol this generally means that the value is inherited from some other object.
The value 1 is used to indicate that color only is to be inherited. 0x0001 INHERIT_OPAQUE -- opaque, but with the color coming from the parent. 0x4001 INHERIT_TRANSLUCENT -- translucent but with the color coming from the parent. The value 2 is used to indicate that one of the palettes is to be used. 0x0002 PALETTE, opaque 0x4002 PALETTE, translucent Palettes themselves are coded separately in a Palette ID that is tracked with
Modifier and Type | Field and Description |
---|---|
static int |
ALPHA_SHIFT |
(package private) static int[] |
argbs |
private static int[] |
argbsGreyscale |
static short |
BLACK |
static short |
BLUE |
static short |
CHANGEABLE_MASK |
private static Int2IntHash |
colixHash |
(package private) static int |
colixMax |
static short |
CYAN |
static short |
GOLD |
static short |
GRAY |
static short |
GREEN |
static short |
HOTPINK |
static short |
INHERIT_ALL |
static short |
INHERIT_COLOR |
static int |
LAST_AVAILABLE_COLIX |
static short |
LIME |
static short |
MAGENTA |
static short |
MAROON |
static short |
NAVY |
static short |
OLIVE |
static short |
OPAQUE_MASK |
static short |
ORANGE |
static short |
PINK |
static short |
PURPLE |
static short |
RAW_RGB |
private static int |
RAW_RGB_INT |
static short |
RED |
static short |
SILVER |
static short |
SPECIAL_COLIX_MAX |
static short |
TEAL |
static int |
TRANSLUCENT_MASK |
static int |
TRANSLUCENT_SCREENED |
static int |
TRANSLUCENT_SHIFT |
static int |
TRANSPARENT |
static short |
UNMASK_CHANGEABLE_TRANSLUCENT |
static short |
USE_PALETTE |
static short |
WHITE |
static short |
YELLOW |
Constructor and Description |
---|
C() |
Modifier and Type | Method and Description |
---|---|
static int |
allocateColix(int argb,
boolean forceLast) |
(package private) static void |
calcArgbsGreyscale() |
static short |
copyColixTranslucency(short colixFrom,
short colixTo) |
static int |
getArgb(short colix) |
static int |
getArgbGreyscale(short colix) |
static short |
getBgContrast(int argb) |
static short |
getChangeableColixIndex(short colix) |
static short |
getColix(int argb) |
static short[] |
getColixArray(java.lang.String colorNames) |
static short |
getColixInherited(short myColix,
short parentColix) |
static short |
getColixO(java.lang.Object obj) |
static short |
getColixS(java.lang.String colorName) |
static float |
getColixTranslucencyFractional(short colix) |
static java.lang.String |
getColixTranslucencyLabel(short colix) |
static int |
getColixTranslucencyLevel(short colix) |
static short |
getColixTranslucent(int argb) |
static short |
getColixTranslucent3(short colix,
boolean isTranslucent,
float translucentLevel) |
static java.lang.String |
getHexCode(short colix) |
static java.lang.String |
getHexCodes(short[] colixes) |
private static int |
getTranslucentFlag(float translucentLevel) |
static boolean |
isColixColorInherited(short colix) |
static boolean |
isColixLastAvailable(short colix) |
static boolean |
isColixTranslucent(short colix) |
static boolean |
renderPass2(short colix) |
(package private) static void |
setLastGrey(int argb) |
public static final short INHERIT_ALL
public static final short INHERIT_COLOR
public static final short USE_PALETTE
public static final short RAW_RGB
public static final short SPECIAL_COLIX_MAX
static int colixMax
static int[] argbs
private static int[] argbsGreyscale
private static final Int2IntHash colixHash
private static final int RAW_RGB_INT
public static final short UNMASK_CHANGEABLE_TRANSLUCENT
public static final short CHANGEABLE_MASK
public static final int LAST_AVAILABLE_COLIX
public static final int TRANSLUCENT_SHIFT
public static final int ALPHA_SHIFT
public static final int TRANSLUCENT_MASK
public static final int TRANSLUCENT_SCREENED
public static final int TRANSPARENT
public static final short OPAQUE_MASK
public static final short BLACK
public static final short ORANGE
public static final short PINK
public static final short BLUE
public static final short WHITE
public static final short CYAN
public static final short RED
public static final short GREEN
public static final short GRAY
public static final short SILVER
public static final short LIME
public static final short MAROON
public static final short NAVY
public static final short OLIVE
public static final short PURPLE
public static final short TEAL
public static final short MAGENTA
public static final short YELLOW
public static final short HOTPINK
public static final short GOLD
public static short getColix(int argb)
public static int allocateColix(int argb, boolean forceLast)
static void setLastGrey(int argb)
static void calcArgbsGreyscale()
public static final int getArgbGreyscale(short colix)
public static short getColixO(java.lang.Object obj)
private static int getTranslucentFlag(float translucentLevel)
public static boolean isColixLastAvailable(short colix)
public static int getArgb(short colix)
public static final boolean isColixColorInherited(short colix)
public static final short getColixInherited(short myColix, short parentColix)
public static final boolean renderPass2(short colix)
public static final boolean isColixTranslucent(short colix)
public static final short getChangeableColixIndex(short colix)
public static final short getColixTranslucent3(short colix, boolean isTranslucent, float translucentLevel)
public static final short copyColixTranslucency(short colixFrom, short colixTo)
public static float getColixTranslucencyFractional(short colix)
public static java.lang.String getColixTranslucencyLabel(short colix)
public static final int getColixTranslucencyLevel(short colix)
public static short getColixS(java.lang.String colorName)
public static short[] getColixArray(java.lang.String colorNames)
public static java.lang.String getHexCode(short colix)
public static java.lang.String getHexCodes(short[] colixes)
public static short getColixTranslucent(int argb)
public static short getBgContrast(int argb)