Package com.ardor3d.light

Examples of com.ardor3d.light.Light


            if (context.getCapabilities().isOpenGL1_2Supported()) {
                setSpecularControl(state.getSeparateSpecular(), record);
            }

            for (int i = 0, max = state.getNumberOfChildren(); i < max; i++) {
                final Light light = state.get(i);
                LightRecord lr = record.getLightRecord(i);
                // TODO: use the reference to get the lightrecord - rherlitz

                if (lr == null) {
                    lr = new LightRecord();
                    record.setLightRecord(lr, i);
                }

                if (light == null) {
                    setSingleLightEnabled(false, i, record, lr);
                } else {
                    if (light.isEnabled()) {
                        setLight(i, light, state, record, lr);
                    } else {
                        setSingleLightEnabled(false, i, record, lr);
                    }
                }
View Full Code Here


        destination.setGlobalAmbient(source.getGlobalAmbient());
        destination.setLightMask(source.getLightMask());
        destination.setNeedsRefresh(true);

        for (int i = 0, maxL = source.getLightList().size(); i < maxL; i++) {
            final Light pkLight = source.get(i);
            if (pkLight != null) {
                destination.attach(pkLight);
            }
        }
    }
View Full Code Here

            if (caps.isOpenGL1_2Supported()) {
                setSpecularControl(state.getSeparateSpecular(), record);
            }

            for (int i = 0, max = state.getNumberOfChildren(); i < max; i++) {
                final Light light = state.get(i);
                LightRecord lr = record.getLightRecord(i);
                // TODO: use the reference to get the lightrecord - rherlitz

                if (lr == null) {
                    lr = new LightRecord();
                    record.setLightRecord(lr, i);
                }

                if (light == null) {
                    setSingleLightEnabled(false, i, record, lr);
                } else {
                    if (light.isEnabled()) {
                        setLight(i, light, record, state, lr);
                    } else {
                        setSingleLightEnabled(false, i, record, lr);
                    }
                }
View Full Code Here

            _pssmPass.init(renderer);
        }
        updateQuadTextures(renderer);

        // Update the shadowpass "light" position. Iow it's camera.
        final Light light = _lightState.get(0);
        if (light instanceof PointLight) {
            ((PointLight) light).setLocation(lightPosition);
        } else if (light instanceof DirectionalLight) {
            ((DirectionalLight) light).setDirection(lightPosition.normalize(null).negateLocal());
        }
View Full Code Here

TOP

Related Classes of com.ardor3d.light.Light

Copyright © 2018 www.massapicom. 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.