Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Screen Dimensions misreported by Unity

Discussion in 'iOS and tvOS' started by ElectricAnt, May 24, 2012.

  1. ElectricAnt

    ElectricAnt

    Joined:
    Jul 13, 2010
    Posts:
    28
    Hello,

    I was wondering if someone else would verify that screen dimensions are misreported on iPhone4, iPod Touch4, and 3GS while in LandscapeLeft (which is actually iOS LandscapeRight, but that is a different story). Their widths and heights are swapped. i.e. on 3GS in Landscape Unity reports 320x480 instead of the expected 480x320. On iPhone4 and iPod Touch 4 dimensions reported as 640x960 instead of expected 960x640. iPad 2 reports proper dimensions. These are the only devices I have to currently test on so not sure about the others.

    Also could someone else verify that iPhoneGeneration is reported as Unknown when checking for iPhoneGeneration.iPhone4. The device type will return an 'iPhone' string, but the generation always returns 'Unknown'.

    I had to switch to the hackish sreen res check to load my appropriate GUIs for multiple devices because the iPhone Generation.iPhone4 doesnt work, now I cannot use either way to check for a non-iPad resolution. I have filed bugs for both of the above, FYI.

    The misreporting of resolution is new for me as of 3.5.2f2. The iPhoneGeneration bug I noticed in 3.5+.

    Thanks for checking and reporting.
     
    Last edited: May 24, 2012
  2. ElectricAnt

    ElectricAnt

    Joined:
    Jul 13, 2010
    Posts:
    28