private DirectionalLight findLight(Node node) { for (Light light : node.getWorldLightList()) { if (light instanceof DirectionalLight) { return (DirectionalLight) light; } } for (Spatial child : node.getChildren()) { if (child instanceof Node) { return findLight((Node) child); } } return null; }
DirectionalLight directionalLight = findLight((Node) reflectionScene); if (directionalLight != null && useDirectionLightFromScene()) { lightDirection = directionalLight.getDirection();
private DirectionalLight findLight(Node node) { for (Light light : node.getWorldLightList()) { if (light instanceof DirectionalLight) { return (DirectionalLight) light; } } for (Spatial child : node.getChildren()) { if (child instanceof Node) { return findLight((Node) child); } } return null; }
private DirectionalLight findLight(Node node) { for (Light light : node.getWorldLightList()) { if (light instanceof DirectionalLight) { return (DirectionalLight) light; } } for (Spatial child : node.getChildren()) { if (child instanceof Node) { return findLight((Node) child); } } return null; }
private DirectionalLight findLight(Node node) { for (Light light : node.getWorldLightList()) { if (light instanceof DirectionalLight) { return (DirectionalLight) light; } } for (Spatial child : node.getChildren()) { if (child instanceof Node) { return findLight((Node) child); } } return null; }
DirectionalLight l = findLight((Node) reflectionScene); if (l != null) { lightDirection = l.getDirection();
DirectionalLight l = findLight((Node) reflectionScene); if (l != null) { lightDirection = l.getDirection();
DirectionalLight directionalLight = findLight((Node) reflectionScene); if (directionalLight != null && useDirectionLightFromScene()) { lightDirection = directionalLight.getDirection();