Package com.ardor3d.scenegraph

Examples of com.ardor3d.scenegraph.Spatial


        if (_children == null) {
            return;
        }
        for (int i = 0, max = Math.min(_childMask.length(), _children.size()); i < max; i++) {
            if (_childMask.get(i)) {
                final Spatial child = _children.get(i);
                if (child != null) {
                    child.onDraw(r);
                }
            }
        }
    }
View Full Code Here


        if (_children == null) {
            return;
        }
        for (int i = 0, max = Math.min(_childMask.length(), _children.size()); i < max; i++) {
            if (_childMask.get(i)) {
                final Spatial child = _children.get(i);
                if (child != null) {
                    child.updateGeometricState(time, false);
                }
            }
        }
    }
View Full Code Here

                continue;
            }

            pass.applyPassNodeStates(context);

            Spatial child;
            for (int i = 0, cSize = _children.size(); i < cSize; i++) {
                child = _children.get(i);
                if (child != null) {
                    child.onDraw(r);
                }
            }
            r.renderBuckets();

            context.popEnforcedStates();
View Full Code Here

     *            if true, recursively check any sub-containers for the given component.
     * @return if the given component is found
     */
    public boolean contains(final UIComponent component, final boolean recurse) {
        for (int i = getNumberOfChildren(); --i >= 0;) {
            final Spatial child = getChild(i);
            if (child.equals(component)) {
                return true;
            } else if (recurse && component instanceof UIContainer) {
                if (((UIContainer) component).contains(component, true)) {
                    return true;
                }
View Full Code Here

     * @param comp
     *            the component to remove
     */
    public void removeAllComponents() {
        for (int i = getNumberOfChildren(); --i >= 0;) {
            final Spatial child = getChild(i);
            if (child instanceof UIComponent) {
                remove((UIComponent) child);
            }
        }
    }
View Full Code Here

            _layout.layoutContents(this);
        }

        // call layout on children
        for (int x = 0, max = getNumberOfChildren(); x < max; x++) {
            final Spatial child = getChild(x);
            if (child instanceof UIComponent) {
                ((UIComponent) child).layout();
            }
        }
    }
View Full Code Here

    @Override
    public void updateMinimumSizeFromContents() {
        // call update on children first
        for (int x = 0, max = getNumberOfChildren(); x < max; x++) {
            final Spatial child = getChild(x);
            if (child instanceof UIComponent) {
                ((UIComponent) child).updateMinimumSizeFromContents();
            }
        }
View Full Code Here

        }
    }

    @Override
    public void attachedToHud() {
        Spatial child;
        for (int i = 0, cSize = getNumberOfChildren(); i < cSize; i++) {
            child = getChild(i);
            if (child != null) {
                if (child instanceof UIComponent) {
                    ((UIComponent) child).attachedToHud();
View Full Code Here

        }
    }

    @Override
    public void detachedFromHud() {
        Spatial child;
        for (int i = 0, cSize = getNumberOfChildren(); i < cSize; i++) {
            child = getChild(i);
            if (child != null) {
                if (child instanceof UIComponent) {
                    ((UIComponent) child).detachedFromHud();
View Full Code Here

        UIComponent ret = null;
        UIComponent found = this;

        for (int i = 0; i < getNumberOfChildren(); i++) {
            final Spatial s = getChild(i);
            if (s instanceof UIComponent) {
                final UIComponent comp = (UIComponent) s;
                ret = comp.getUIComponent(hudX, hudY);

                if (ret != null) {
View Full Code Here

TOP

Related Classes of com.ardor3d.scenegraph.Spatial

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.