/** Set RGB color to specified index */ public void setRGB(int index, int rgb) { alpha.setValue(index, MAX_LEVEL); red.setValue(index, (rgb >> 16) & 0xFF); green.setValue(index, (rgb >> 8) & 0xFF); blue.setValue(index, (rgb >> 0) & 0xFF); gray.setValue(index, ColorUtil.getGrayMix(rgb)); }
/** Set ARGB color to specified index */ public void setARGB(int index, int argb) { alpha.setValue(index, (argb >> 24) & 0xFF); red.setValue(index, (argb >> 16) & 0xFF); green.setValue(index, (argb >> 8) & 0xFF); blue.setValue(index, (argb >> 0) & 0xFF); gray.setValue(index, ColorUtil.getGrayMix(argb)); }
/** Set alpha intensity to specified index */ public void setAlpha(int index, short value) { alpha.setValue(index, value); }
/** Set gray intensity to specified index */ public void setGray(int index, short value) { gray.setValue(index, value); }
/** Set blue intensity to specified index */ public void setBlue(int index, short value) { blue.setValue(index, value); }
/** Set green intensity to specified index */ public void setGreen(int index, short value) { green.setValue(index, value); }
/** Set red intensity to specified index */ public void setRed(int index, short value) { red.setValue(index, value); }