Shader experiment of the day:
When hex tiling is used to hide texture repetition, the coordinates are usually rotated per tile. That works great for chaotic surfaces without a noticeable directionality, but doesn't work for textures where the orientation matters. So I added a switch to just offset the coordinates randomly instead of rotating them. And for brick walls, tiles, etc, there is the option to use stepped offsets, so that the tiles are still aligned to the same grid:
#gamedev #Unreal
@haukethiessen That looks great. And it doesn’t cost too much in terms of ALU ?
@nick It depends. I'm using dithering for the UVs, so I only have to sample each texture once. Without this optimization, you need to sample each texture 3 times, so in combination with several layers or parallax mapping, this can become costly. The dithering can be noticeable, depending on how contrasty the texture is