private CollisionResult pickFromCamera() {
        CollisionResults results = new CollisionResults();
        Ray ray = new Ray(cam.getLocation(), cam.getDirection());
        instancedNode.collideWith(ray, results);
        return results.getClosestCollision();
    }
A test case for using instancing with ray casting.

Based on distance from camera, swap in/out more/less detailed geometry to/from an InstancedNode.

@author duncanj
jme3-examples/src/main/java/jme3test/scene/instancing/TestInstancedNodeAttachDetachWithPicking.java