tkeskita / BVtkNodes

Create and execute VTK pipelines in Blender Node Editor
GNU General Public License v3.0
119 stars 20 forks source link

Set transparency for VTK meshes? #60

Open renehommel opened 3 years ago

renehommel commented 3 years ago

Is it possible to add transparency to a VTK To Blender mesh generated object? I can't find anything in the documentation and the known places on the web (e.g. blenderartists, vtk.org).

Under Material Properties one can set the Blend Mode and Alpha value, but it is turned off or set to 1 (no transparency) during rendering. In viewport rendering this doesn't happen, but the render result is of course not that good (with my knowledge).

Is there a solution with the help of the BVTK nodes or is there even a connection to the material nodes possible?

CFDTom commented 3 years ago

Hi Rene, I think your problem is with render setup. Correct me if I'm wrong but, if you setup cycles render you should be able to set paths in render settings, namely transmision paths ( i think). Try to set this at a bit higher values and it should be transparent in your render. Note that the proper material is needed (I think you already knew this)

Tom

renehommel commented 3 years ago

I'm certainly not a Blender expert, but I think the global render settings do not solve the issue, since the goal is to provide a single mesh object, or each VTK to Blender generated mesh object, for which a material was generated with the BVTK node (e.g. showing an U-distribution on a cut plane), individually with an alpha value. Similar to "normal" materials, defined in the shader editor.

(BTW, for standard purposes I usually use Eevee, but the render engine shouldn't matter)

tkeskita commented 3 years ago

Hi, currently I think it's not possible to assign arbitrary alpha/transparency to mesh points/faces. Good idea for future development though. I'm busy with core refactoring, so no fast solution from me. :) Changing alpha for colors in Color Ramp is possible, but that alpha is linked to color values, so it's not very flexible.

renehommel commented 3 years ago

That's a good tip with the alpha channel of individual colors - thank you!

But it also means that a simultaneous use of the shader editor material nodes is not possible together with the material generated by BVTK? Because then the transparency effect could be made possible in this way.

Unfortunately my coding skills do not extend so far that I could help at this point.