Examples of IHSColorSpace


Examples of com.lightcrafts.mediax.jai.IHSColorSpace

        public final static Color LZOrange = new Color(254, 155, 14);
        public final static Color SelectedToolBorder = relight(LZOrange, 0.7f);
    }

    static Color relight(Color color, float amount) {
        IHSColorSpace ihs = IHSColorSpace.getInstance();

        float components[] = new float[3];
        components = ihs.fromRGB(color.getColorComponents(components));
        components[0] *= amount;
        components = ihs.toRGB(components);
        return new Color(components[0], components[1], components[2]);
    }
View Full Code Here

Examples of javax.media.jai.IHSColorSpace

    public final ImageWorker forceColorSpaceIHS() {
        if (!isColorSpaceIHS()) {
            forceComponentColorModel();

            // Create a ColorModel to convert the image to IHS.
            final IHSColorSpace ihs = IHSColorSpace.getInstance();
            final int numBits = image.getColorModel().getComponentSize(0);
            final ColorModel ihsColorModel = new ComponentColorModel(ihs, new int[] { numBits,
                    numBits, numBits }, false, false, Transparency.OPAQUE, image.getSampleModel()
                    .getDataType());
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.