appleseedhq / appleseed-max

appleseed plugin for Autodesk® 3ds Max®
https://appleseedhq.net/
MIT License
33 stars 16 forks source link

asSurfaceLuminance does not work #348

Open dictoon opened 4 years ago

dictoon commented 4 years ago

The reason is that its output is of type float, and we try to connect it to the input of type color of as_max_closure2surface:

2020-01-14T12:55:23.911009Z <001>  1751 MB error   | osl: ConnectShaders: cannot connect a float (out_result) to a closure color (in_input)
2020-01-14T12:55:23.912010Z <001>  1751 MB error   | error connecting shaders Material #45_mat::out_result -> Material #45_mat_closure_2_surface_name::in_input.
usakhelo commented 4 years ago

Yes, I remember this. I think if we just re-arrange output parameters and put output closure color out_color = 0 first and output float out_result = 0 second it should fix the issue. I'll try and let you now.

dictoon commented 4 years ago

That would be awesome, please do keep me posted!