Problem with ambient lighting and .visible property

Software: Away3D 4.x

CraigMurray, Newbie
Posted: 17 January 2013 12:22 AM   Total Posts: 4

So I’m seeing what appears to be a very strange bug.  I have an Object3DContainer with several children.  If I do this:

child1.visible = false;
child2.visible = true;

The very next frame I see child2 as visible, but with the only diffuse and specular light, NO ambient light applied.

Then on the 2nd frame, I see child2, lit correctly.

After my app has been running awhile, it seems to stop happening, but the first time I do this, it always happens.

It appears as a flash when I’m running at 60fps, but if i set my frame rate low I can clearly see child1, visible, and lit without any ambient.

I have verified that both PointLight and DirectionalLight do not have their ambient applied during this one frame.

In my screenshot you can see the dark blocks, these are the ones that just had their visible property set to true on the previous frame.

I should add that I’m using a stage proxy because I have Starling running my HUD layer.

I could be doing something wrong, but I dont think so.  I think it might be a bug.  Any suggestions?

Thanks!

Craig

 

   

CraigMurray, Newbie
Posted: 18 January 2013 04:15 PM   Total Posts: 4   [ # 1 ]

I have been unable to fix this bug (not much of a 3D programmer) and have worked around it by removing all ambient light from my scene and instead adding more point lights using only diffuse.  It’s kind of a bummer but it’s the only workaround I’ve found so far.

Any ideas what’s wrong with the ambient lighting routine in Away3D 4.0.10?

   

CraigMurray, Newbie
Posted: 29 January 2013 04:28 PM   Total Posts: 4   [ # 2 ]

Nothing? No one?

   
   

X

Away3D Forum

Member Login

Username

Password

Remember_me



X