Cavifree: your games just got a whole lot more depth!

We are excited to announce our latest open source effort: Cavifree! It’s a screen space post-processing effect for Unity that mimics the “cavity” viewport effect found in Blender. This shader packs quite a punch, enhancing the depth and detail of your scenes by highlighting edges and crevices of objects, giving them a little extra oomph to make them pop!

What’s Cavifree all about?

Cavifree is designed to work with Unity 2022 LTS and Unity 2023, and it supports both the Universal Render Pipeline (URP) and the High Definition Render Pipeline (HDRP). The effect works by calculating the curvature of surfaces and then blending this with the image buffer using a “soft light” technique.

Cavifree showcase

Performance and customization

Now, you might be wondering about performance. Well, Cavifree’s performance depends on the sampling radius you choose. Smaller radii mean better performance, so you can tweak this to find the perfect balance for your game. Here are some benchmarks using a RTX3070 GPU:

1920×1080, Radius 0 px: 0.1 ms/frame
1920×1080, Radius 1 px: 0.5 ms/frame
1920×1080, Radius 2 px: 1.4 ms/frame

You can customize several parameters to get the effect just right, such as Intensity, Radius, Angle Sensitivity, Edge Intensity Multiplier, and Sharpness.

Why we created Cavifree

The inspiration for Cavifree came from a talented 3D artist working on our game “Break, Enter, Repeat”. He shared some stunning screenshots showcasing the cavity effect in Blender, and I knew I had to bring that same vibe to Unity. Our game’s low-poly style was the perfect canvas for this shader, making it a no-brainer to develop Cavifree.

Get started

Ready to dive in? You can find Cavifree’s source code and detailed setup instructions on GitHub. Whether you’re using URP or HDRP, there’s a guide to help you integrate the shader into your project. And if you run into any issues, feel free to open an issue on the GitHub page. So go ahead, give your Unity scenes some extra depth and style with Cavifree. We can’t wait to see what you create!

Login
Loading...
Sign Up

New membership are not allowed.

Loading...