The Making Of A Bucket: Optimising Texture Space

I guess welcome to our first ever blog! Here you will find the ramblings of the lead programmer for Laireon Games as I try to bring the project Aiyana to market.

Aiyanas Logo


For those of you who don’t know about Aiyana, check out our Twitter https://twitter.com/laireon.

Alright so onto the show and we are starting off with how we made this glorious bucket.

Its just a bucket but ok…

Ok so, its a bucket… but this lil’ guy is special because it has decently high details despite its texture being only 256 by 256, here it is below.

Why Optimise

So your first question might be, you’re making a PC game why bother going so low? Well we are making a game similar to Minecraft, which means the more block types we have the better but drawing lots of textures can be expensive. To get around this we use something called Texture Arrays which are pretty similar to texture atlases but with some key advantages.

More info about Texture Arrays here if you’re curious: https://docs.unity3d.com/Manual/SL-TextureArrays.html

However, one of the main tradeoffs of using this technique is that all your textures in the array must be the same size and this leaves us with 2 options.

1: We combine our buckets into the chunks mesh. This means it must have a 256 texture (because its the size we went with for our blocks) but its ‘almost free’ to render.

2: We spawn buckets as their own prefab. This means it can have whatever texture it wants but then each bucket needs its own call (this can be GPU instanced) .

In this case using option 2 is by far the easier solution however at what point do these extra draw calls add up? It is this question is why we went with option 1 and decided to optimise this as a test.

The real problem though is that 256 simply wasn’t enough space to get a high detail texture using our current art pipelines which is when I decided to step in and make this new one.

Our UV Map

The technique we used is actually very simple although a bit tricky to implement depending on how you produce your textures. To help explain lets first look at the bucket itself.

Once you see this next video you will spot what we are doing right away.

All we have done here is made smarter use of our texture space. Instead of texturing 12 different panels, we made 4 unique textures and space them out so the bucket doesn’t appear to be tiling or repeating its details at a glance. This way we get a great trade off, great details at low resolution and without the appearance repeating in an obvious way. If you’re really wanting to push this you could use 1 wooden panel and repeat it but people would spot the pattern which is why we opted for 4.

To make this in your 3D software what you need to do is overlap your UV map so your mesh faces are on top of each other. Here is how ours looked by the end.

What you can’t see so easily here is how the panels overlap since in this case the meshes are the same size so the lines overlap perfectly. However you can get a sense of the madness our artist had to deal with here when you look at the bottom left section which is where the metal rims, bolts, and handle all use the same texture.

Leave a comment

Your email address will not be published. Required fields are marked *