🎉 Celebrating 25 Years of GameDev.net! 🎉

Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!

Multi-resolution assets and adding "oomph" to your palette

Started by
1 comment, last by Scouting Ninja 6 years, 8 months ago

Howdy!

I'm creating my own graphics assets, but being much more of a coder than an artist, I'm struggling with a few issues. This is NOT a mobile game (that is, I'm targeting PC), so the problems may likely be less pronounced than what I'm experiencing during development.

In music there is a step that comes after you create your track (called mastering), which takes the final mix and modifies it in such a way that it sounds "equally good" on as many setups as possible. This means making the track sound good in a studio (eg the equivalent of a calibrated 4K display or cinema), a home setting (a basic 1080p monitor), when streaming (some older sub-FHD laptop) and in case some individuals want to listen to it on an old phone with only one speaker - eg in mono (let's say this is a 800x600 4:3 CRT monitor).

I'm having essentially the same problem, but with resolutions and palette. 

- my orginial assets target 4K, but look muddy when used in some arbitrary lower resolution, which is not a multiple of 1080p (I suppose a common example might be 1377x768). I'm guaranteeing the same pixel aspect in my game code, but the bilinear downscaling gets rid of most accents and edges, making everything blurry and blended together. I can add a resolution-dependent detail map to some things (eg the ground) to restore some fidelity, but this won't work with objects. Do you manually tailor your assets for two or three common resolutions and have the game pick the best match at runtime?

- what do you use to control your palette? I feel like there should be a tool for this (at least for people such as myself who are not very good at art design). I have access to Photoshop and realize I could set up my swatches, but since I'm not working on some retro shooter, the color depth at my disposal is still 24 bits. This is too much, because my assets tend to have this uncanny valley effect where they're similar in tonality, but don't really jibe together in-game. Any suggestions as to how to limit my palette without resorting to 8 bits? Or is it just a matter of "git gud"? :) 

Advertisement
On 10/11/2017 at 10:53 AM, irreversible said:

my orginial assets target 4K, but look muddy when used in some arbitrary lower resolution, which is not a multiple of 1080p

You are looking for mip maps and mipmaps blending.

The way this works is that you start with a very large image say 4K. Then using your UI tool you build a scalable UI, you can keep it simple and only scale by percentage if you want.

A mipmap will provide you with half of each texture so 4k->2K->1K->512->256->128->64->32->16->8->4->2->1

Now if you worked on 4096*4096 then scaled to 1080p(1920*1200) your X would find the two nearest 2K and 1K then work out the percentage: 1920/ 2048 = 0.94- 0.5= 0.44*2=0.88 (Because 1024 =0.5 of 2048)  and lerp (2048, 1024, 0.88) between the two textures using the percent. The same would happen to Y 1200/2048 = (0.59-0.5)*2 = 0.17 and lerp(2048, 1024, 0.17).

So your new image would be (0.88 of 2048, 0.17 of 2048) and the rest of the texture would be 1024.

 

Confusing? Your in luck just Download Unreal or Unity and the engine will already have UI scaling tools and mipmap blending. All you would need to do is check the box that reads mipmaps and the engine will do this for you on auto.

This topic is closed to new replies.

Advertisement