iPhone support?


Thanks for the reply rdb, my plan was to compile it for the nokia n900 platform seeing as I’ve got a scratchbox system set up and the actual device. I’ll compile the dependencies missing first and then tackle panda, like ODE & openal-soft which haven’t been ported to Maemo yet. maemo.org/ essentially it is nokia’s debian-based linux for internet tablets and smartphones.

The hardware is identical to the beagle board (OMAP3/PowerVR SGX) so I’m hoping it shouldn’t be too difficult to port. Thanks again rdb.


Ah, okay. If the hardware is similar indeed it shouldn’t be too much effort. I cross-compile Panda3D myself with the codesourcery toolchain. I started without much thirdparty packages, and when I got it working, added those other libraries. If you want, email me and I’ll send you my Config.pp file that I used for cross-compilation.


I’m considering using Panda3D for iPhone development, but I’m not clear on how difficult that will be. What is the general process required to create an iPhone app using Panda? I would prefer to take the straight-and-narrow (non-jailbroken) path.

If possible, I’m planning to load Collada files, use OpenGLES 2.0, and develop in C++.

Thanks for any help,


We haven’t actually made a lot of forward progress on the fully-productized iPhone app development process yet. That is to say, we’re in the same state today that we were when this was discussed in this thread: the code is there, and I do have a Panda app running on my (non-jailbroken) iPod touch, but it’s not easy to develop for yet.

We hope to get this finished within the next few months.



What needs to be done before you can officially release the iPhone version?


There’s been a delay due to Apple’s new iPhone Developer License, which explicitly forbids the use of any language other than C, C++, or Objective-C (which presumably includes Python).

Feel free to write a nasty letter to Steve Jobs.



Do you have confirmation on that? Because I thought Apple simply did not want other languages to be compiled into native iPhone code. Since the Panda3D engine is written in C++ and the Python is interpreted it should be fine.

I don’t know, I’m no expert on Apple’s user agreements.


There’s a lot of speculation on the net as to what Apple really and truly has in mind, but this phrase is hard to get around:

“Applications must be originally written in Objective-C, C, C++”

There are no clarifications forthcoming from Apple, so I guess any doubts will be resolved when the new license goes into effect and we can see what they actually do forbid and what they don’t.



I agree that the new Apple license is very strict. But the truth is that it’s so strict that they can’t possibly enforce it as written–or nearly half of the top games on iPhone would need to be kicked out of the store.

Also, since C++ is a permitted language, could you potentially release Panda3d as a C+±only engine? Or is it too tightly integrated with Python to be able to disable that integration?

Technically even that would be against the rules (“no compatibility layer”). But that part of the rules is simply insane, and frankly impossible to enforce entirely.

Yes you could pick a particular engine and exclude it (using “anti-virus”-like signature techniques, for example), but you’re not going to get every developer to completely rewrite every game for iPhone that exists on other platforms. So everyone will have a compatibility layer for their own games.

But if the Python integration is too tightly bound in with the rest, then I guess you’re right–in that I personally wouldn’t want the extra overhead of a Python interpreter in my iPhone game (or on Android).

Too bad Panda 3d doesn’t use Lua instead. Much lower overhead, and faster to boot.


There’s no marriage of Panda3D and Python. It should be possible to write a C++ iPhone app using Panda3D. It’s not entirely clear to me whether this falls under the definition of using a “compatibility layer” (since Panda is open source, you can copy the entire library into your application source code folder–and then it becomes part of your application itself, not a separate layer).

That said, I’ve used Python to develop experimental apps for the iPhone, and it works fine, from a technical standpoint. But this has been hashed to death: Apple’s license is not about technical restrictions, it’s about market share.

Whether it’s realistic for Apple to eliminate nearly half of the top games in the App store is also kind of beside the point. It appears that Apple thinks this is a worthwhile sacrifice for their own business needs, and they might well be right.

Whether this new agreement is enforceable in practice or not is irrelevant for the purposes of declaring Panda3D’s iPhone support. If developing for iPhone using Panda3D would violate Apple’s developer agreement, then Panda3D cannot provide (legitimate) iPhone support.

Of course, we can continue to provide illegitimate iPhone support. That’s less exciting to developers, of course.



That’s excellent.

Sorry, yes, I have to agree on all counts. No need to rehash.

As I mentioned, a C+±only game based on Panda 3d would be hard for them to detect, and as you mentioned, it may not even be in violation of their agreement.

Yes, but…a lot of this is beside the point for me, since I want to write Android games, and I don’t want to use Python, so I’m looking at potentially using your OpenGL ES support and parts of your 3d pipeline. The ability to rebuild my game(s) for iPhone would be a bonus, but not strictly necessary.

Is all of the OpenGL ES support you mentioned above available in the current source package, and/or CVS? And the iPhone support that does exist–is that already checked in as well, or is that only on your system?


Everything is in CVS.

If you get a working Android port going, we’d love to know about it, and share it with the world. :slight_smile:




Looks like Panda3D for the iPhone is possible again.


Hmm, that’s good news, though maybe not good enough: “an Application may use embedded interpreted code . . . if such use is solely for providing minor features or functionality.”

Certainly writing the application entirely in Python would constitute more than “minor features or functionality.”

This change seems to be directed at apps that use internal embedded interpreters to drive a small part of the game logic, and is meant to specifically exclude games that are entirely written in a language such as Python.

Also, it is increasingly clear that the philosophical drive of Apple’s licensing is to forbid the use of multi-platform development tools, such as Panda3D. Apple wants to limit developers to using tools that support only Apple products.



The real test is if they continue to allow Unity3D games to be approved. If so there should be no problem allowing Panda3D games. In Unity3D the JavaScript/C# is compiled directly into native ARM code.

Anyway. I’m really a complete newbie when it comes to compiling stuff. Are there any basic steps you can give me that would allow me to compile Panda for the iPhone on my MacBook?

If I can’t use Python I’ll use C++. But I would like to play around with Panda3D on the iPhone. Ideally if I cannot use Python I’d like to interface with Panda3D directly in Objective-C.

I figure it won’t hurt to try :slight_smile:


Hum, well, a lot of the momentum on the Panda3D/iPhone project has been lost recently. You can still build it for iPhone, but it will be an effort, and it might not be the best place to get started if you’re not already experienced with building large C++ projects.

You need to use ppremake to build for iPhone. You could start by getting the Panda3D source and first using ppremake to build it for your local development environment. If that goes well, then try to build it for iPhone.

To do this, install the iPhone Developers SDK from Apple, and add:

#define BUILD_IPHONE iPhoneOS
#define HAVE_GLES 1
#define GLES_LIBS

to your Config.pp. You’ll also need to obtain build any third-party tools you want, like libjpeg or libpng, for iPhone. But you can omit these at first, just to get started. You might need to explicitly turn all of these off with “#define HAVE_JPEG” and so on for each package.

If you want to run Python apps, you’ll also have to compile the Python interpreter for iPhone. This is surprisingly difficult, because the Python codebase isn’t designed for cross-compilation (it wants to build the interpreter and then immediately run it to build some more, but this isn’t possible in a cross-compilation environment).

If you want to run just C++ or Objective-C apps, though, you should be able to do this directly from the Panda build.



Hi, thought I should point out that sometime today (or yesterday) apple released a statement saying

this is from ipodtouchfans

this means we could in theory develop panda applications for the iphone, which would be especially cool if we can manage to get python to work on it, as well.Panda would be like the only competitor to the “Unreal Engine on Iphone” demon god thingy…

would be neat :smiley:[/url]


Oh! This is huge! Apple has rejoined the land of the sane. And, yes, it appears that Panda3D + Python is once more legitimately allowed on the iPhone.

Let’s let the iPhone project resume. :slight_smile:



That means no packages for iphone, right?

Also, are you sure you can trust them? By their stupid tactics they can restrict it again after few months.


This is great news. I think Panda3D would be a great open-source alternative to some of the already existing engines out there.

I doubt it. I think they learned from their antics with Adobe. They took a lot of bad press for it, I don’t think they’ll want to repeat that. Let’s try not to be pessimistic and take what we can get 8)