First I want to thank the Away3Dlite team for the "obj3d.screenZ"
property. This makes this possible.
I have been having issues with strange renderings that happen when an
object is around, on, or just behind the camera. To turn off objects
behind the camera I'm using the "screenZ" property of every object
like so:
//loop through all top level objects in the scene.
for each(var obj3:Object3D in view.scene.children)
{
if(obj3.layer != null)
{
if(obj3.screenZ < 200)
{
//trace("Not Visible:"+obj3.name+" "+obj3.screenZ);
obj3.visible = false;
obj3.layer.visible = false;
}else{
//trace("Visible:"+obj3.name+" "+obj3.screenZ);
obj3.visible =true;
obj3.layer.visible = true;
}
}
}
Tony