We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 1904

Summary: SDL does not support native resolution of the iPhone 5
Product: SDL Reporter: Wouter van Oortmerssen <aardappel>
Component: videoAssignee: Sam Lantinga <slouken>
Status: RESOLVED INVALID QA Contact: Sam Lantinga <slouken>
Severity: normal    
Priority: P2    
Version: HG 2.0   
Hardware: iPhone/iPod touch   
OS: iOS 6   

Description Wouter van Oortmerssen 2013-06-07 16:07:19 UTC
When I iterate through the display modes with SDL_GetDisplayMode, I get these options when running on the iPhone 5 hardware:

mode: 960 640
mode: 640 960
mode: 480 320
mode: 320 480

Even if I stubbornly pass the correct resolution of (1136, 640) to SDL_CreateWindow, SDL denies me that, and gives me 960 640 instead. The game appears letterboxed.
Comment 1 Wouter van Oortmerssen 2013-06-10 17:01:55 UTC
apparently, the modes that availableModes will return depends on... whether you have specified a iphone-5 sized launch image (!)

http://stackoverflow.com/questions/12395200/how-to-develop-or-migrate-apps-for-iphone-5-screen-resolution

Wow Apple, that is some impressively messy / unintuitive design.

So I guess this too is not a bug. Hopefully useful to someone else who wonders why they're not getting the correct resolution.