StaticLightPicker - one per material, or can it safely be reused?

Software: Away3D 4.x

Drumbo, Newbie
Posted: 03 March 2012 02:28 PM   Total Posts: 17

If I’ve got a group of objects that I want lit with the same lights, can I reuse the same LightPicker object, or do I need to create a new one for each instance?

Just wondering if reusing it is going to be a false economy

   

Avatar
Matse, Sr. Member
Posted: 03 March 2012 04:48 PM   Total Posts: 149   [ # 1 ]

Hi Drumbo,

My understanding is that they are meant to be re-used as much as possible, I don’t see a reason why it shouldn’t be that way.

   

Avatar
Fabrice Closier, Administrator
Posted: 04 March 2012 12:00 AM   Total Posts: 1265   [ # 2 ]

That’s correct. Tho, if you build big environments and use pointlights with falloffs, you will have to generate new lights and new pickers, as one picker can hold only 3 lights.

Note that there are 2 known issues with the LightPickers
1/ On some meshes with multiple subgeometry, once applied viewport may go black with no errors in AIR, model partly rendered in Flashplayer. Removing the picker restore rendering.

2/ nullifying a picker causes errors. Fix is to set for instance m.repeat=true then false again in order to force invalidate.

The first one is complex to reproduce and may take so time to be nailed down, tho good news is that it occurs only on rare occasions. The second issue, will be fixed asap as the bug has been found.

   
   

X

Away3D Forum

Member Login

Username

Password

Remember_me



X