Skip to main content

Panda3D BAM file parser library

Project description

p3bamboo

PyPI version

p3bamboo is a Python library that gives you full access to a Panda3D BAM file's inner structure.

Getting Started

Simply install p3bamboo using pip:

python -m pip install p3bamboo

Loading a BAM file is very simple:

from p3bamboo.BamFile import BamFile

bam = BamFile()

with open('myModel.bam', 'rb') as f:
    bam.load(f)

Writing out a BAM file is also easy:

with open('newModel.bam', 'wb') as f:
    bam.write(f)

To automatically deserialize BAM objects, you must register your own custom BAM object types. For example, to register an object type named Texture:

from p3bamboo.BamFactory import BamFactory
from myproject.Texture import Texture

BamFactory.register_type('Texture', Texture)

If you register your object types properly and load a BAM file afterwards, you'll be able to access your objects using bam.object_map.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for p3bamboo, version 1.0.6
Filename, size File type Python version Upload date Hashes
Filename, size p3bamboo-1.0.6-py3-none-any.whl (7.6 kB) File type Wheel Python version py3 Upload date Hashes View
Filename, size p3bamboo-1.0.6.tar.gz (5.8 kB) File type Source Python version None Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring DigiCert DigiCert EV certificate Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page