1

I wanted a quick way of displaying the range of stuff in my game, so I thought: do it with decals around it! Fast and easy!

However, the parts of the decals that are transparent do not appear completely transparent during gameplay. They darken or lighten the parts they are on top of.

You can clearly see here a "square" around the blue circle in the picture (I marked with red the full decal and with orange what should be fully transparent).

The decal is a blue circle and the corners of the .png are fully transparent.

This is my material: Material used for the decal

This is my texture: Texture used in the material of the decal

This is the object with the URP Decal Projector: Configuration of the GameObject casting the decal

Does anybody know why this happens?

Guillem Poy
  • 391
  • 5
  • 18
  • Just to eliminate something in the shader as a variable have you tried using the standard shader / standard particle shader with mode set to either Fade or Transparent, rather than your Shader Graph shader? Also (dumb question, just checking everything) have you checked the alpha layer in the file, if it has one? Is it completely black for transparency? If no alpha layer, are those pixels actually 100% transparent? Lastly, I guess you want clamp, not repeat in the import settings. – Absinthe Jun 29 '22 at 10:26
  • 1
    @Absinthe First, thanks for your time! The shader that I am using for the decals is the standard one. It is unclear to me why it is classified under "shader graph" (might have been done with it). I haven't found any other shader that will work using URP. The image seems to have the proper alpha channel with 100% transparency. I did change from repeat to clamp without any difference. You can see the instructions I followed here: https://docs.unity3d.com/Packages/com.unity.render-pipelines.universal@12.0/manual/renderer-feature-decal.html – Guillem Poy Jun 29 '22 at 10:53

1 Answers1

2

I found the solution by switching the "Automatic" technique of the decals in the Forward Renderer to any other. I opted for the "Screen Space" since in the documentation seemed better: https://docs.unity3d.com/Packages/com.unity.render-pipelines.universal@12.0/manual/renderer-feature-decal.html#:~:text=Feature%2C%20Inspector%20view.-,Technique,-Select%20the%20rendering

enter image description here

Guillem Poy
  • 391
  • 5
  • 18
  • Thank you for saving me the headache of fiddling with every single option here! Man URP has been a whole buncha headaches.... – cjcurrie Aug 31 '22 at 14:51