My results compiling for iOS7

Previous topic - Next topic

mrplant

I have been doing a lot of testing with my app.

Here is my setup.

I run Mountain Lion. As an Apple developer I wanted to install iOS7 and the associated Xcode beta - therefore I am running iOS 7 Beta 3 on my iPhone 5 and iPad 3. I am running Xcode5-DP3.

I cannot use Xcode 4 to compile any more as the iOS7 devices are too new for it and are not recognised.

I wanted to use GLBASIC 10.283 to compile my Game.

First some background info.

I have my game Rock Crush compiled and on the App store for few years now - last update earlier this year.

When I first installled iOS7 - betas 1 and 2 - I ran this App store version of Rock Crush to see how it ran.

It had a major issue in that I pan sound far left and far right in my game - when the man moved left to right all was ok - moving right to left - I failed to hear him walk.

I did a lot of research - eventually noticing that when I plugged in a set of stereo headphones this issue cleared up.

I concluded that there was a problem in the first beta that game sound was using the left channel audio instead of mixing it down for the iphone and ipad internal speaker. strangely music playback didnt have this issue.

Anyway, I reported this bug to Apple and it got sorted in Beta 3.

I can now run my app store version of the game on iOS 7 devices with no problem.

The problem begins when I want to do a new version!

I will keep this short.

I compile with version 10.283 and then into Xcode 5.

The app runs with what looks like a green rectangle in the upper right hand corner and the screen is reported by the app at the wrong size.

For example, this code:

GETSCREENSIZE XRes,YRes // Get Screen size as defined in Project Settings.

comes back with a YRes 40 pixels short on both the iPad and iPhone.

This pushes the bottom off the app off the device screen. There is a horrible green rectangle at the top right and a feint white line on the last pixel line of the screen along the bottom. All ugly.

I did a quick fix and added 40 pixels back on for my rescaling codes benefit but the result was even worse - same lines and green by the way.

I then put on 11.414 beta and got once I was able to compile it (*I had a few issues but thats not for here), i got the same results - screenshot attached.

I am doing all this now as I need to know this will still work in a month or so's time - at the moment I am stuck as I cannot fix this myself.

I have done a lot of hours of testing but the problem here lies in GLBASIC or within Apples SDK.

I suppose what I am trying to say is I need someone more qualified to work out if this affects all apps or if it is a bug that needs reported to Apple.

To my  mind- if ROCK CRUSH compiled for ios6 works on ios7 which it does - there shouldnt really be these issues compiling it for IOS7.

Comments very welcome.

One last thing.. Please bear in mind this occurs on both GLBASIC 10 and 11 betas. Xcode 5 is in beta. iOS 7 is in beta...

mrplant

Here is an iPhone5 screenshot - note I have edited this in photoshop and added myself a purple coloured border top and bottom - to show up clearer the exact problem along the bottom row of the app. Notice how the green rectangle is now red on the iPhone.
None of my device backgrounds are those colours by the way.

I had added the 40 pixels on to this version so it reported 640 in the app by the way - but its like the whole screen is still offset from the top despite the app itself using 0 as the offset.

DaCarSoft

Strange...    :S

Can you test in iPad if the orientation of the green rectangle changes depending on the devices's orientation at the time you launch the game?

For example:

Close your game forcing it from the "multitasking" menu
Put your iPad in portrait (you have to see your screen and icons in portrait)
Launch your game
Observe if the rectangle orientation or position changes

Close your game forcing it from the "multitasking" menu
Put your iPad in landscape (you have to see your screen and icons in landscape)
Launch your game
Observe if the rectangle orientation or position changes

Also, could you try to launch my keyboard wrapper and see if the rectangle changes its position???
Like here: http://www.glbasic.com/forum/index.php?topic=6706.msg54083#msg54083


Tell us what happens, please :)
"Si quieres resultados distintos... no hagas siempre lo mismo" - Albert Einstein.

mrplant

Hi there. I will report back as soon as Apple brings their dev website back up and I can restore my devices to iOS7 again! I got so fed up I removed iOS7 to get some work done on the game update.

mrplant

Hi. I have installed iOS 7 Beta 4 which came out Monday. I compiled same app using new Xcode 5 beta 4 that came out same day.
Results are in attached screenshots - the core of the problem seems to be that the iPad for example is reporting its screen height (when landscape for example) at exactly 40 pixels out - this is the size of the status bar on retina ipad.
Id imagine that figure to be 20 on iPad 1 and iPad 2.
The green blob is still there which is like a remnant of the battery meter.
In short although I have checked all the xcode settings are set to hide the status bar - the app does not seem able to do this properly on iOS 7 for some reason.
Tomorrow when I have more time I will again attempt to force the app to use the correct screen dimensions and report back what happens. I notice that this time the game screen is smaller both on x and y - which is correct considering it is getting fed wrong height info.

I will also do the tests you wanted above and report back as well.

[The game was compiled using the current release version of GLBASIC not the new v11 beta here.]

mrplant

Ok Sorry for delay there.
Here is latest screenshots on ipad3. I am using the latest ios7 beta 5 from Monday. XCode same is Xcode 5 preview 5. GLBasic is 10.283.

I have typed in the INFO command in my game to show what size of screen the app thinks it is running on - always been correct until ios7!!

Anwyay, as you can see in the first screenshot the y res is 40 pixels short again and is showing what looks like the status bar or part of it.

my code to get the screen size is :

   GETSCREENSIZE XRes,YRes // Get Screen size as defined in Project Settings.

nothing strange there. My rescale code then rescales the graphics accordingly. The first screenshot shows the y value is 40 pixels short.

To try and force a fix again, I used the following code:

      XRes = 2048
      YRes = 1536   

which are the correct iPAD retina dimensions.

Again,  the second screenshot shows the results... Despite forcing the app to use this size, the status bar is again pushing down the screen of the bottom - in effect there is nothing I can do from withing GLBASIC itself to sort this.

It could be iCade code related... not sure..

Comments welcome. Going to try latest GLBASIC beta next.

mrplant

In reply to DaCarSoft:

Can you test in iPad if the orientation of the green rectangle changes depending on the devices's orientation at the time you launch the game?

For example:

Close your game forcing it from the "multitasking" menu
Put your iPad in portrait (you have to see your screen and icons in portrait)
Launch your game
Observe if the rectangle orientation or position changes

I have tested and here is a screenshot when launched in portrait mode.
Again, looks like a 40 pixel area at the top of the screen - with the green bar again. Once again there is a feint line along the bottom pixel row of the screen also.
Hard to see in this screenshot but it is there! shows up better with a black background.

mrplant

Also, to answer the second part of DaCarSoft's question:

Also, could you try to launch my keyboard wrapper and see if the rectangle changes its position???
Like here: http://www.glbasic.com/forum/index.php?topic=6706.msg54083#msg54083


Tell us what happens, please

ok. I have compiled your library and source code demo under ios7.
Screenshots below of the portrait and landscape results..
Glad to say it was a clean project and the results where the same as the corruption I am seeing on Rock Crush.
Again, it may be hard to see but on both versions there is that feint 1 pixel line at the bottom of the screen.

hope that helps..

PS. nice work ;-)

mrplant

Important: Further investigations tonight...

I managed to get my iDevices to be recognised at last by the older XCode 4.6.3
It used to say the connected device uses too new an iOS version to use with this version of Xcode.

I discovered if I used the devices for development first with Xcode 5.0 Preview 5 in the Organiser window, then shut down Xcode 5 and started Xcode 4 again, it finally gave me a green light on my iDevices.

I compiled and ran my game and it ran exactly as it did on iOS 6.x

These so called issues I have been highlighting here therefore, aren't iOS7 per se, they are actually issues or bugs in Xcode 5.0

I will report these issues to Apple so they can look into them.

MrTAToad


mrplant

True.. problem is - is it a bug or a feature?

Its starting to look like a change in behaviour..

I'll keep my eye on it..

DaCarSoft

Definitively I have to test that thing under iOS 7.

Also, it is interesting to see if Apple will reply to your post about that bug.

If I have some news I will post here.


Thanks for testing, I wanted to see if that symbol could move or dissapear when using native iOS controls.


"Si quieres resultados distintos... no hagas siempre lo mismo" - Albert Einstein.

DaCarSoft

#12
Finally, I solved it!

I have tested it and it is not a bug of Xcode or iOS...   It is a change in the way that you need to hide the status bar for an application under Xcode 5.

The easy solution to solve it, for Xcode 5 is to add a parameter for the info.plist of the project by adding:

View controller-based status bar appearance        Boolean      NO

You can add it directly by creating a new value or copying and paste similar values from Xcode.

You can also add the parameter with a text editor:

<key>UIViewControllerBasedStatusBarAppearance</key>
<false/>
"Si quieres resultados distintos... no hagas siempre lo mismo" - Albert Einstein.

mrplant

DaCarSoft - I love you and want to have your babies!!  :blink: :blink: :blink: :-* :-* :-* :-* ;/ ;/ ;/ :) :) :) <3 <3

Seriously - one line in a .plist file?

Awesome work my friend!!!

Thank You for figuring this out - makes perfect sense to how everything was behaving!

Will test myself shortly but you have nailed it I reckon!

mrplant

I take it this will roll into the next GLBASIC 11 beta?  :-[