Kaboom's VRC Decal System

CAD$7+
0 ratings

Have you ever wanted to put a texture absolutely anywhere, but haven't really been able to get it quite right in your UVs? Or maybe, you have a logo you want featured prominently in your world, but it doesn't conform very well to your walls? Perhaps you just simply want to break up your world textures, but don't want to have an individual texture on each object?

Maybe, like me, you come from Unreal Engine, or another version of Unity using the HDRP or URP pipeline, where we have access to decals already and you just want to work with them again?

Have I got the solution for you!

Introducing: Kaboom's Decal Shader! A simple projection based setup built on the Unity Legacy pipeline that allows you to place a texture / decal anywhere you want. With a myriad of different texture settings, most use cases should easily be covered for the average user in the basic material.

Example video: https://twitter.com/KyusoWhitescale/status/1630328547985203246?s=20

How do I use this thing? You can drag the decal Prefab into your scene and just put it anywhere you like. You can also simply apply the material to any mesh and let it do its work. You will need to turn off all of the lighting information related to your mesh if you don't want lights to bake shadows floating in the air of your sphere and the like. I.E. Receive Shadows, Cast shadows, and Contribute Global Illumination should all be turned off. I turned off light and reflection probes as well to be safe and prevent it the decals from messing with any lighting.

If your object is having some distortion issues, try clicking on the "Projection Direction" check box to change the projection orientation. Adjusting the mask settings will let you change how much the decal will fade towards the edges of the mask in general, this can be switched between a box mask and a spherical one. Alpha and Emissive intensity are self explanatory. "Use Albedo Emissive" Is a way of saving on some texture memory. If you do not have a basic emissive texture, or they are separate textures and you need to have the decal show, you can use the albedo as an emissive layer as well. Decal UV offset will adjust the tiling position of the texture, letting you shift tiled textures around to better suit your needs, or to help with repetition. See images for details.



"Why does the decal appear on my feet?" You have discovered one of the quirks of decals in general! They will project on to essentially anything. I will be coming up with a way of getting around this if possible, though it will be more computationally expensive to do so. Unreal decals do this by default, and it is an issue with most decal systems, however the solution is to simply scale your decal enough that it doesn't really matter much, by making it so small that the texture doesn't show above your feet. Just keep this in mind when putting the material on to any mesh willy nilly. You can use this to your advantage too, if you wanted to have say, light rays coming down from a tree top and to have that show on top of your players. Or maybe caustics in water shining light. There are pros and cons to have it project on to players and not project.


Do let me know if you have any specific feature requests. I would like to get proper lighting information but I doubt I can do anything like that in the VRC forward Renderer. However, I have some ideas for getting faked lighting information in there, so stay tuned for updates in the future.

TODO:

Lighting information.
Secondary Detail Mask on the Alpha.

Far future: Include player model rejection so projected decals do not go on top of player mesh. (likely needing custom depth)

Take a look at my twitter for more shader work and other things I may release. You can also reach out there for support if you encounter odd bugs or other problems.

https://twitter.com/KyusoWhitescale


Licensing:

This is really the usual. Do not redistribute the contents of this shader pack, do not re-sell the contents of this package.

CAD$
I want this!

The decal shader, sphere prefab with the material applied (and scaled).

Size
52.3 KB
Copy product URL
CAD$7+

Kaboom's VRC Decal System

0 ratings
I want this!