@Override
    public void addView(View child, int index) {
        if (!isTornDown()) {
            if (child instanceof VRTLight) {
                ((VRTLight) child).addToNode(mNodeJni);

            } else if (child instanceof VRTCamera) {
                final VRTCamera cameraView = (VRTCamera)child;
                mNodeJni.addChildNode(cameraView.getNodeRootTransformCamera().getNodeJni());
            } else if (child instanceof VRTNode) {
                final VRTNode childNode = (VRTNode) child;
                mNodeJni.addChildNode(childNode.mNodeJni);
            } else if (child instanceof VRTAnimatedComponent) {
                // We want the AnimatedComponent to be "invisible" to the scene graph so we need to add
                // the children of the AnimatedComponent to the parent of the AnimatedComponent natively.
                // Otherwise the parent of an AnimatedComponent has no idea that it has extra children
                // natively.
                // Note: AnimatedComponents can only have 1 child right now, so the loop is just
                // futureproofing
                VRTAnimatedComponent animatedComponent = (VRTAnimatedComponent) child;
                for (int i = 0; i < animatedComponent.getChildCount(); i++) {
                    if (!(animatedComponent.getChildAt(i) instanceof VRTNode)) {
                        continue;
                    }

                    VRTNode animatedTarget = (VRTNode) animatedComponent.getChildAt(i);
                    if (!containsChild(animatedTarget)) {
                        addNativeChild(animatedTarget);
                    }
                }
            } else {
                // TODO: Throw Error? Red Screen?
            }
        }

        super.addView(child, index);
    }
This function creates a Node object. Child classes should override to provide
     their own Node.
android/viro_bridge/src/main/java/com/viromedia/bridge/component/node/VRTNode.java