Hi MACHIN3, I’m using your addon to detail clothing on a character. I’ve noticed that quite a few times, the baking process produces artifacts, projecting details on parts where it’s not desirable. This is fixable by modifying the raycast distance in combination with the cage extrude distance. Unfortunately, the addon enforces its own values, so I took the liberty to modify it so I can change these values in the addon’s interface.
What I found gives me the best results is setting the “Ray Distance” to 0.0001 (in the original addon, the minimum value for this is capped at 0.001) and the cage “Extrusion Distance” to 0.001 (setting this value is not possible in the original addon’s interface). So I also set the defaults at these values.
I’m attaching the modified python files here, as well as the diffs generated as html in winmerge, so you can easily inspect them.
DECALmachine_2.6.4 - mem bake mod.zip (28.2 KB)
dm 2.64 - mem bake mod patches.zip (6.9 KB)
I think these changes might be useful to other users as well, so maybe you could include them in your next official release.
For a clearer picture, here’s how a baked normal map looks with the addon’s default settings:
And here’s how it looks with the modifications:
The values mentioned above (Ray Distance at 0.0001 and Extrusion Distance at 0.001) work fine for DM 2.6.4 on Blender 3.1.2. However, on Blender 3.2.1 RC and 3.3 alpha, the opposite (sort of) seems to be true, as in the Ray distance being set higher than the Extrusion Distance (RD 0.01 and ED of 0.0001 produce similar results as on Blender 3.1.2 with RD 0.0001 and ED 0.001). So it seems something has changed in the way Blender handles these values. The results still turn out with artifacts when using the default DM addon on Blender 3.2.
I still think exposing both values to the user is a good thing, as it allows for tweaking in situations where baking fails with the default values.
I will look into this, thanks.
When I tried to use Slice, I got this error. I don’t know what’s causing it. What can I do to fix this problem?
Python: Traceback (most recent call last):
File "C:\Users\toyxy\AppData\Roaming\Blender Foundation\Blender\3.2\scripts\addons\DECALmachine\operators\slice.py", line 37, in invoke
sliced = self.slice(context, event, target, cutter)
File "C:\Users\toyxy\AppData\Roaming\Blender Foundation\Blender\3.2\scripts\addons\DECALmachine\operators\slice.py", line 75, in slice
finish_panel_decal(dg, context, panel, target, cutter)
File "C:\Users\toyxy\AppData\Roaming\Blender Foundation\Blender\3.2\scripts\addons\DECALmachine\utils\decal.py", line 1088, in finish_panel_decal
auto_match_material(panel, mat, matchobj=target_eval, face_idx=faceidx)
File "C:\Users\toyxy\AppData\Roaming\Blender Foundation\Blender\3.2\scripts\addons\DECALmachine\utils\material.py", line 1637, in auto_match_material
match_material(decalobj, decalmat, matchmatname=matchmatname, matchmat2name=matchmat2name, matchsubname=matchsubname, debug=debug)
File "C:\Users\toyxy\AppData\Roaming\Blender Foundation\Blender\3.2\scripts\addons\DECALmachine\utils\material.py", line 1680, in match_material
set_decalgroup_from_dict(decalnodegroup, material=materialdict, material2=material2dict, subset=subsetdict)
File "C:\Users\toyxy\AppData\Roaming\Blender Foundation\Blender\3.2\scripts\addons\DECALmachine\utils\material.py", line 1596, in set_decalgroup_from_dict
nodegroup.inputs["Material %s" % i].default_value = material[i]
KeyError: 'bpy_prop_collection[key]: key "Material Subsurface IOR" not found'
Thanks for the reply! However, after changing the Addon settings, the problem somehow disappeared. Now it works fine. I don’t know what caused it.
If you report it I can probably tell you what caused it.
Hello, is there any obvious way to add imperfections to info decals that I missed? Or do I have to add it myself? It doesn’t look good if material is all damaged and old, but info decal is perfectly clean.
Thank you for all awesome work so far.
See https://machin3.io/DECALmachine/docs/ in particular this:
The focus of DECALmachine is speed and flexibility in terms of Design and Detailing. Depending on how far you intend to take your designs, and especially if you, intend to use complex shader node setups or do complex texturing such as weathering, floating mesh decals might not be the best workflow, unless you are targeting a deferred rendering solution with mesh decal support, which allows for selective channel blending, instead of just alpha blending as in Blender’s Eeevee and Cycles.
Also, see https://machin3.io/DECALmachine/docs/faq/#can-i-create-decals-for-damage-and-weathering-effects-such-as-those-from-quixel for context.
For info decals however, you can absolutely connect a dirt map to the alpha channel.
v2.6.5 is out! | https://decal.machin3.io - Gumroad, Blendermarket, Documentation
See what’s new .
- fix modal HUDs being drawing off-screen in Blender 3.2.2