I mean, i have a client with an standard app developed (simple app with some documents and some photos) and they want to integrate a 3d interactive inside the app, is that possible? (even if it’s necessary to rewrite the entire app in the xcode project from unity).
I’ve managed to sneak in a RootViewController to my unity3d app by modifying the code in the AppController’s OpenEAGL_UnityCallback function. I’m only overlaying simple views, temporarily and with unity paused. I’m not sure what performance would be like shoehorning a complex app in via that method but it should be possible at least.
Well we made AppController available to you to do exactly that
For 3.4 we fiddled a little with it so it should be far easier to integrate native things (will come out soon, but no ETA)
Ya, you can definitely do it, although maybe not in the way you’re thinking. For instance, if you’re thinking that you would have a Obj-c app that would call Unity as-needed and on-demand, then maybe not. But, you can have Unity running and still have the full functionality of Obj-c-based dev available to you, too.
My experience is that Unity needs to run and do it’s own thing on startup, but you can definitely override once it’s up. For instance with Gears, Unity starts up first, but the first Unity loaded scene initiates a obj-c class which then gets me fully back into Obj-c world. I don’t let Unity take control again until the user actually loads in a gameplay level. Almost all UI and other non-game functionality is Obj-c, and Unity just handles the game elements itself with the Obj-c stuff determining what works when. Although I limited myself mostly to just UI stuff, there’s no reason you couldn’t do anything you normally would do on the Obj-c side, including 2D animations, etc. You will have a performance hit on your Obj-c stuff if you don’t pause the Unity system in the background though (and even then, there will still be a small performance hit.)
There’s probably a way to make Unity load “on-demand” and perhaps even unload, but I don’t know how, nor may it be worth it (unless you’re really memory constrained in what you’re doing on the Obj-c side or wishing to do some very fancy animations or other transforms.)