Today's Learning Unreal post is the fourth and final part of a mini-sub series about creating shaders in Unreal. You can find the previous part on custom shaders here.
The topic of today's post is how to create a paint filter shader, which can be used to make a game look more like a painting. As always, if you want to follow along with the same tutorial that I'm using, you can find it here.
As with the previous posts, I'll first start by providing an unaltered image of the scene that you can use for comparison.
The main algorithm used to create a paint filter is called the Kuwahara Filter, which is another type of convolution operation that both smooths an image and preserves the hardness of the edges. The tutorial I linked above does a much better job of explaining the specific details of how it works better than I ever could, so take a look at that if you want to know more. If not, you can just take a look at the final product here:
Just like in the previous post, this type of shader is also a custom shader, which uses the Custom Node to add the complex HLSL code necessary to fully implement the Kuwahara filter.
A notable part of the process is that the kernels used by the Kuwahara filter were aligned with the pixel's local orientation by performing another convolution pass beforehand using the Sobel edge detection technique.
I'm not sure if this is easier or harder than actually just painting.
Comments