Hi, I wanted to get some feedback on something that’s been bothering me for ages.
I find myself quite often in the situation where I have an object with multiple materials. Some of them PBR materials and other procedural. When preparing the object for export I need to bake the procedural materials, but not the PBR materials.
So I add an empty image texture node to my procedural material and select it and bake.
However, when baking blender picks the active image texture from each material (or if none is active it even just picks a random one) and not just the selected images. This results in one of the images in each PBR material getting overwritten (the one that happens to be clicked last or happens to come first in the nodetree).
To prevent this from happening I need to add a ‘dummy’ active ImageTexture node in each PBR material to catch the stray baking. Which is far from ideal when working with linked materials.
This has caused textures from my material library to be overwritten when I was distracted on closing and just pressed ‘save all images’, which is a pain.
I created a simple patch locally which just skips all unselected image nodes, so it only bakes to the images explicitly selected.
This seems to me much better than the current behaviour. I could create a PR from it but I first wanted to ask if I’m overlooking something. Is there a situation where you actually want to bake to all ‘active’ images?
I know baking needs a revamp and it’s probably better to really fix the way it works, but this simple (2 ifs added and an error message adapted) patch does prevent a lot of frustration/data loss.