[Closed] Direct X Shader and Light1Pos
I’m encountering an issue with Max’s DirectX shader. When I load a scene it doesn’t update the DX shader property Light1Pos, which stores the lighting information for the shader.
I’m writing a scripted material plugin that extends DxMaterial and have tried to force it by using the “on load do” and “on postLoad do” event handlers, but neither work. It does update appropriately if I re-assign it in the rollout “on open do” event handler, but that requires the material browser to be open with that rollout open. i would prefer it update correctly when the shaders are loaded. It will also update appropriately by typing the following in the listener:
<DirectX_9_Shader>.light1Pos = <DirectX_9_Shader>.light1Pos
Has anyone else run into this and found a solution. I’m in Max 2010 (I know, I know, behind the times). Also, If it’s fixed in a later version, please let me know.
Thanks for the help.
–Jon