BradyAJohnston / MolecularNodes

Toolbox for molecular animations in Blender, powered by Geometry Nodes.
https://bradyajohnston.github.io/MolecularNodes/
GNU General Public License v3.0
913 stars 87 forks source link

Defaul Materials #465

Closed jojoelfe closed 3 months ago

jojoelfe commented 7 months ago

Hi Brady,

I would like to add a new Material called "MN AO Emission".

image

I use it a lot in my work, mostly because it makes renders work without any lights setup. Settings up lights can be difficult when dealing with cellular scenes and is cumbersome to do for automated visualization scripts. Combined with the Cycles Spheres style it is also ridiculously performant in the live preview.

The main question I have is how the materials are organized at the moment. They are all in the data_file, but from what I can tell one cannot access them from default scenes. They are there when using the MN startup file, but I have not using it that much, because it seems more geared towards rendering single molecules.

So concretely what I am wondering is:

BradyAJohnston commented 7 months ago

I like the material! I have in the past use just plain AO for the same reasons that it is very performant with point clouds and viewport, but this is a nicer improvement on that material.

Currently I have the materials in both. The original idea was have them just in the data file, but I added them to the template so they would be immediately available in the template for users. I was hoping to have them also appendable in the materials workspace from the data file, just like the GN / MN node groups, but I haven't gotten around to making the panel yet.

I think a new template better setup for tomography / Cryo-EM would be good. I defer to you as to what would be useful in there. In the other template I have included an HDRI from poly-haven (which are CC0), so if you think an HDRI would be good you can use the same / different.

As I mentioned there currently isn't a mechanism to import, but we could add one without too much trouble (and should).

I believe this should probably be the realm of 'Asset Libraries'. I think ideally when we install the add-on, the data files become part of the asset library - then they become available automatically inside all parts of Blender. I did look into this briefly once, but found it to be a bit difficult to add a filepath to the asset library inside of Blender when installing. I will have another look into this perhaps.

BradyAJohnston commented 7 months ago

Just revisited it in #467 and managed to get a button to install anything in the assets folder of the add-on as an asset library.

This opens the way to include all sorts of more niche node groups for more specific use cases like tomography etc. The nodes, models / materials / lighting can be in separate .blend files and all be accessible through the assets interface as well as being accessible through general scripting

BradyAJohnston commented 3 months ago

I wouldn't call this 'solved' because adding new materials is a bit messy. But this new material at least is now available in 4.2.

The way currently is to add them to the data file, I have moved them from the template file. This still needs improving but might be able to be done until assets are more improved in Blender.