int c[] = ColorsFactory.getColor(w, channel); setRGBA(w, c[ColorsFactory.RED], c[ColorsFactory.GREEN], c[ColorsFactory.BLUE], c[ColorsFactory.ALPHA]);
Color c = ColorsFactory.getColor(w, channel); setRGBA(w, c.getRed(), c.getGreen(), c.getBlue(), c.getAlpha());
    public void resetDefaults()    {        // Reset the bit resolution.        setQuantumStrategy(QuantumFactory.DEPTH_8BIT); // NB: Java locks are        setCodomainInterval(0, QuantumFactory.DEPTH_8BIT); // re-entrant.        // Set the each channel's window to the channel's [min, max].        // Make active only the first channel.        ChannelBinding[] cb = getChannelBindings();        boolean active = false;        int model = RenderingDefConstants.GS;                List channels = getMetadata().getChannels();        int w = 0;        for (Iterator i = channels.iterator(); i.hasNext();)        {        	// The channel we're operating on        	Channel channel = (Channel) i.next();            if (channel.getPixels().getAcquisitionContext().getPhotometricInterpretation().getValue() == "RGB") // FIXME            {                active = true;                model = RenderingDefConstants.RGB;            }            cb[w].setActive(Boolean.valueOf(active));            double start = channel.getStatsInfo().getGlobalMin().doubleValue();            double end   = channel.getStatsInfo().getGlobalMax().doubleValue();            setChannelWindow(w, start, end);            int c[] = ColorsFactory.getColor(w, channel);            setRGBA(w, c[ColorsFactory.RED], c[ColorsFactory.GREEN],                    c[ColorsFactory.BLUE], c[ColorsFactory.ALPHA]);            w++;        }        cb[0].setActive(Boolean.valueOf(active));        // Remove all the codomainMapCtx except the identity.        getCodomainChain().remove();        // Fall back to the default strategy.        setModel(model);    }