I noticed, the manual has a chapter about asset encryption. ( panda3d.org/manual/index.php … Multifiles )
It’s particularly intresting as many 3rd party off-the-shelf 3d model packs require this in their license. However if the password is in a “.py” file, anybody can see it with a simple text editor.
Is there a way to comply with such licenses? I think this is an important issue with commercial projects.
(Not even speaking about protecting the developers’ work/ enabling client side cheating of antilag prediction systems etc.)
The password isn’t in a simple .py file and can’t easily be found with a text editor, but it is necessary to download the password as part of the application, and it won’t take long for anyone looking for it to actually find it.
This kind of thing always amounts to obfuscation only, and should never be confused with actual security. I think it’s naive for a license to insist that the contents be obfuscated on a user’s hard disk, but I guess they didn’t ask my opinion.
Still, the option is available to use. I don’t know what licenses you’re referring to, specifically, but a license can only require obfuscation at best. Any license that actually requires true protection of assets can never be complied with, not in Panda or in any other engine. If a program can decode the assets, so can a human examining the program.
I’ve seen it on 3drt ( the3dmodelstore.com/License.txt ), and as far as I remember at turbosquid (not sitewide, but artist’s own requirement) too.
The manual says:
from pandac.PandaModules import Multifile
mf = Multifile()
That’s only an example to show you the mechanics of how it works, and you can write your code to be as sneaky as you like. But note that even if you do write that code exactly, .py files are not generally distributed with an application (they certainly don’t appear in p3d files). Instead, compiled .pyc files are distributed, which cannot easily be inspected with a text editor.
Anyway, the licenses you linked require only lame obfuscation, so even using the simple example code above would comply.
Oh, I see. I haven’t looked into the p3d packing tools. Thanks for pointing it out.