Virtual Resolution, Scaling, and Assets,
Members - Reputation: 140
Posted 26 November 2012 - 05:58 PM
The first thing I'm wondering is, if I allow users of a game to change resolution, by how much do I scale the different sprites/logos/HUD? Is there some sort of formula to this?
Second, let's say I want my game to be crisp/clear in 1080p resolution. How do I create art assets for this resolution? Someone suggested to me that I open up adobe photoshop, create a new document that is 1080p in height. I find that strange, because why would you draw a small character sprite in such a huge window?
If I end up using a virtual resolution, at what point do I scale objects? It seems to me that if I'm drawing everything to a virtual 1280x1024 resolution, but when it is actually displayed on the user set resolution, let's say 800x600, the scaling would have to be done each and every call to a draw which is alot, and would slow things down immensely.
Moderators - Reputation: 39699
Posted 26 November 2012 - 06:18 PM
There are several ways to scale the UI.
For a beginner, I wouldn't worry about it.
Make your game to fit your own screen and only after you have finished the game should you worry about fancy things like scaled UI.
Check out my book, Game Development with Unity, aimed at beginners who want to build fun games fast.
Also check out my personal website at bryanwagstaff.com, where I occasionally write about assorted stuff.
Members - Reputation: 841
Posted 27 November 2012 - 12:21 AM
This can be done even with pen and paper - scetch your level layout, scetch the sprites and mark down pixel sizes. Then you will simply draw your sprites marked size and copy them to screen 1:1.
As of how should the scaling to be done - it really depends on the graphics library you plan to use. If you are directly or indirectly (through library) using GPU acceleration thrn EVERYTHING is scaled in every frame anyways (just sometimes the scale may be 1:1). But even if you are directly drawing everything with CPU, you should not worry about it now.
First technology demo of my game Shinya is out: http://lauris.kaplinski.com/shinya
Khayyam 3D - a freeware poser and scene builder application: http://khayyam.kaplinski.com/