I dont want to use the emission map.
I have three boxes attached all to gether to one single mesh.
I assign this to a mesh light.
I assign to the texture of the mesh light an OSL color switcher.
This method works to assign different color materials to a group
of objects.
How can I do a similar thing using mesh lighting?
I hope I explained it well..
thx.
Solved! Go to Solution.
Solved by madsd. Go to Solution.
Max 2020 file attached.
The 3 boxes are collapsed into 1 mesh, and each "element" is called ID:1 ID:2 ID:3
I droped down to Element in the mesh and clicked each one and gave them the numbers 1,2,3 in Material ID.
Source this ID with a Material ID node to 1 to 5 maps Index and set the colors R,G and B.
The boxes now sends out meshlight according the the array 3 first colors.
If you want them to flicker around between random colors, we setup a DCM modifier that injects a random float value, we can shuffle with the Arnold Jitter node, or by animating the DCM shuffle parameter.
You're a life savior @Mads God bless you prof...
I have totally ignored since now the existance of ID's.. 🙂
Again a BIG thanks 🙂
I will try also the dcm modifier...
And as I understand to have these objects also self illuminated, I have to assign
same osl node as emission color because light shape visible is always grayed out...
That may be the case yes. but as you mention, you can use the same shader chain to pipe the the surface.
If you get stuck with the generation of Element ID for an animated shuffle let us know.