Using Views & ViewControllers with SDL2 on iOS

Hi,

I am currently integrating the Apple GameCenter with my iOS app. The reason I built the app with SDL2, is that I am developing the Android version concurrently.

However, GameCenter uses a lot of iOS specific view controllers. An example call is

[self presentModalViewController:mmvc animated:YES];

What would be the best way to do this with SDL2. I am willing and able to mess with the SDL2 source code to get this to work, but if anyone can give a few pointers before I jump into the deep end, it would be very welcome.

Best,
Gorm-------------------------------------------------------
Currently working on M.U.L.E. Returns (http://mulereturns.com/)

Theres already a thread about this but I made a quick template from an old code I was testing with

heres an example that uses SDL with Game Center and also interacts with a UIView and a button. https://dl.dropbox.com/u/32670362/GameCenterTemplate.zip

gormlai wrote:> Hi,

I am currently integrating the Apple GameCenter with my iOS app. The reason I built the app with SDL2, is that I am developing the Android version concurrently.

However, GameCenter uses a lot of iOS specific view controllers. An example call is

[self presentModalViewController:mmvc animated:YES];

What would be the best way to do this with SDL2. I am willing and able to mess with the SDL2 source code to get this to work, but if anyone can give a few pointers before I jump into the deep end, it would be very welcome.

Best,
Gorm


Currently working on M.U.L.E. Returns (http://mulereturns.com/)

Hi Steve,

Sorry for taking so long to reply to this, but I got it to work, and it was rightfully pretty straightforward. I had seen some other hacks elsewhere, but using the callback SDL_iPhoneSetAnimationCallback works like a charm. Once I am done with my current project, I wouldn’t mind documenting this on the website.

Cheers,
GormOn Monday, August 6, 2012 at 2:50 PM, stevo5800 wrote:

Theres already a thread about this but I made a quick template from an old code I was testing with

heres an example that uses SDL with Game Center and also interacts with a UIView and a button. https://dl.dropbox.com/u/32670362/GameCenterTemplate.zip

gormlai wrote:
Hi,

I am currently integrating the Apple GameCenter with my iOS app. The reason I built the app with SDL2, is that I am developing the Android version concurrently.

However, GameCenter uses a lot of iOS specific view controllers. An example call is

[self presentModalViewController:mmvc animated:YES];

What would be the best way to do this with SDL2. I am willing and able to mess with the SDL2 source code to get this to work, but if anyone can give a few pointers before I jump into the deep end, it would be very welcome.

Best,
Gorm


Currently working on M.U.L.E. Returns (http://mulereturns.com/)


SDL mailing list
SDL at lists.libsdl.org (mailto:SDL at lists.libsdl.org)
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org