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.

AppGameKit Classic Chat / Getting the device supported resolution.

Author
Message
JORGEMAL
14
Years of Service
User Offline
Joined: 2nd Aug 2009
Location:
Posted: 24th Oct 2011 16:56
Is there a command in the BASIC language to get the resolution capacity of the device where a game is running? I have been reading the documentation and I do not find it. What I see is GetDeviceHeight and GetDeviceWidth, but such commands return the value of the actual resolution, not the one that is supported by the device.

For example, if my game is running on an iPhone, I would like to get that it supports a resolution of 960 x 640; or if my game is running on an iPad I would like to get that it supports a resolution of 1024 x 768.

Respectfully,
Jorge Maldonado
MikeHart
AGK Bronze Backer
20
Years of Service
User Offline
Joined: 9th Jun 2003
Location:
Posted: 24th Oct 2011 17:59
If you don't supply the resolution inside the config file, then these commands should report the actual resolution.
LeeBamber
TGC Lead Developer
24
Years of Service
User Offline
Joined: 21st Jan 2000
Location: England
Posted: 27th Oct 2011 19:26
The SETUP.INI is merely for the Desktop apps which want to create a window at some point. For other platforms, just use GetDisplayWidth/GetDisplayHeight to know the actual resolution of the device, and then you can lay your app out according to that size as you see fit after calling SetVirtualResolution with those dimensions.

I drink tea, and in my spare time I write software.

Login to post a reply

Server time is: 2024-04-23 19:47:18
Your offset time is: 2024-04-23 19:47:18