Inspiration: Using decals to emulate wear and tear on materials

  • Made some decals in Sketchup to emulate weathering on flat materials. Just draw some flat rectangles in SketchUp, import the desired imperfection map as transparent .png, make the whole thing a component (don't forget to set the Axes for "Glue to") and save for later use. You can find a bunch of surface imperfection maps on cc0.



    Anyway, this is how the finished project looks like:



  • Thomas Willberger Thank you very much! There's only one thing I just encountered: Decals work perfectly fine at high to mid distances, when coming too close they exhibit some strange behaviours. The viewport looks normal but when rendering the "decaled" surface appears darker than intended. Here's what it's supposed to look like:



    But if I move closer to focus on some of the details and hit render this happens:



    If I rotate the camera up and look down it looks like this. It would seem this behaviour has something to do with the camera distance and angle to said decal.


    Another example - here's what it looks like if I move too close. Best to be viewed in full resolution. Check out the dark, almost black surface which represents the shape of the decal in Sketchup:



    If I move away and use a narrower FOV to focus on the stains they look as intended:



    Should I file this as a bug report?

  • At a guess, it's the decal casting a shadow on the surface under it - the fact you don't see it at a distance is an exploit rather than a bug that you do see it closer.

    That's pretty much what I thought too though it seems odd the full shadow is cast when the decal is set to (semi-)transparent. Maybe some of the technical staff could clear this up...

  • At a guess, it's the decal casting a shadow on the surface under it - the fact you don't see it at a distance is an exploit rather than a bug that you do see it closer.


    That's pretty much what I thought too though it seems odd the full shadow is cast when the decal is set to (semi-)transparent. Maybe some of the technical staff could clear this up...

    That's more or less correct, however we're talking about indirect diffuse illumination that is shadowed here and not direct (sun/artificial) light. What's happening is, that when you're further away our optimization rejects your decal geometry (probably due to beeing too small) - that's the same mechanism that becomes obvious in e.g. in mirror surfaces, where reflections of smaller objects further away disappear.


    For reflections we actually do trace against the transparency texture since 2.6, so you can see for example the correct shapes of tree leafs in reflections. However for indirect diffuse light, which is usally very low frequency and you usually can't make out smaller details, we do not use the actual transparency texture, but a procedural one based on the average transparency - this might result in false occlusion in some scenarios as this one.