Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Newcomers AppGameKit Corner / ios and android resolution

Author
Message
Behdadsoft
15
Years of Service
User Offline
Joined: 7th Apr 2009
Location: Tehran-Iran
Posted: 26th Apr 2015 14:10
Hi.

I want make a game for ios and android. but i want build once for all platforms(ios, android).

I search in google and find somethings about ios resolution like below link:

http://www.iosres.com/

I know Androind resolution is (1280 x 800) and according to top link, maximum resolution for ios is (2048 x 1536).

with this knowledge I need know can I use (2048 x 1536) resolution for make android and ios games?

Thanks.
baxslash
Valued Member
Bronze Codemaster
17
Years of Service
User Offline
Joined: 26th Dec 2006
Location: Duffield
Posted: 27th Apr 2015 09:37
You don't need to worry about the resolution of the device really, you need to think about how you handle the aspect ratio. For example some devices are wider than others.

I normally use a virtual resolution that is more or less the same across all devices, so using your example sizes I would make my game 1024x768 for a device that is 2048x1536 and 1024x640 on a device that is 1280x600. Then I would scale sprites based on the width (1024) to ensure that physics and movement values are consistent across devices.

I hope that helps!

Using AppGameKit V2 Tier 1
Behdadsoft
15
Years of Service
User Offline
Joined: 7th Apr 2009
Location: Tehran-Iran
Posted: 1st May 2015 11:15 Edited at: 1st May 2015 11:16
Quote: "Then I would scale sprites based on the width (1024) to ensure that physics and movement values are consistent across devices."


how to do it?

if directly I use 2048x1536 resolution for all devices (ios, android), there is any problem?
baxslash
Valued Member
Bronze Codemaster
17
Years of Service
User Offline
Joined: 26th Dec 2006
Location: Duffield
Posted: 1st May 2015 11:36
Well if you use a set scale then your app will stretch / squash on some devices which can look bad but that's up to you.

If you keep a constant width or height (such as 1024) then using a hard coded (fixed) size for all sprites will keep things behaving consistently IE. Physics. That way you don't have to calculate the physics scale for example which is a pain to get just right!

Using AppGameKit V2 Tier 1
Behdadsoft
15
Years of Service
User Offline
Joined: 7th Apr 2009
Location: Tehran-Iran
Posted: 1st May 2015 12:14 Edited at: 4th May 2015 15:22
if possible I want understand how can do this work.

thanks.
Behdadsoft
15
Years of Service
User Offline
Joined: 7th Apr 2009
Location: Tehran-Iran
Posted: 21st May 2015 19:07 Edited at: 21st May 2015 19:13
Quote: "I would make my game 1024x768 for a device that is 2048x1536 and 1024x640 on a device that is 1280x600. Then I would scale sprites based on the width (1024) to ensure that physics and movement values are consistent across devices."


@baxslash

can you give me simple example that how to rescale sprite on across devices?
Note: I use Percentage system for my games.

I set my setup.agc to (1024 * 768) and used SetDisplayAspect( -1 ) in my project.

Thanks
MASTER OF PUPPETS
20
Years of Service
User Offline
Joined: 9th Jun 2004
Location: Trapped Under Ice
Posted: 26th May 2015 02:04
Are you allowing screen rotation to change between landscape and portrait? Or are you setting up your app for strictly one or the other full time?

|,,|, ,|,,|
Behdadsoft
15
Years of Service
User Offline
Joined: 7th Apr 2009
Location: Tehran-Iran
Posted: 28th May 2015 23:09
Quote: "Are you allowing screen rotation to change between landscape and portrait?"


No, I don't allowing Screen rotation to change between landscape and portrait.
AdamGM
9
Years of Service
User Offline
Joined: 13th Jun 2015
Location:
Posted: 14th Jun 2015 22:11
Why would you set your aspect to -1? Wouldn't a new device be 1.5 to 1.7 ish?

Login to post a reply

Server time is: 2024-11-23 10:12:41
Your offset time is: 2024-11-23 10:12:41