1 decade ago by wands
Need some advice here. I'm trying to work on my next game. But I've no idea how to actually implement the code to maintain aspect ratio across multiple devices.
If I were to work on an aspect ratio of 3:2 (example IPhone 4 resolution). Then of course it won't fit full screen on other resolutions like Samsung's devices.
At the same time, I'll need to scale up the canvas as well. How much to scale? Even if I scale it up, there will be gaps at the edges of the screen.
Or since there will be gaps, should I keep it that way as there is no other way?
The game needs to maintain it's aspect ratio due to game balancing purpose.
I did search around the forum here and google around. But don't seem to provide a more definitive answer.
Any kind souls here could advise how I should go about it?
If I were to work on an aspect ratio of 3:2 (example IPhone 4 resolution). Then of course it won't fit full screen on other resolutions like Samsung's devices.
At the same time, I'll need to scale up the canvas as well. How much to scale? Even if I scale it up, there will be gaps at the edges of the screen.
Or since there will be gaps, should I keep it that way as there is no other way?
The game needs to maintain it's aspect ratio due to game balancing purpose.
I did search around the forum here and google around. But don't seem to provide a more definitive answer.
Any kind souls here could advise how I should go about it?