Skip to content

Python Multi-Media API

Latest

Choose a tag to compare

@PycraftDeveloper PycraftDeveloper released this 21 Aug 20:13
· 112 commits to main since this release

PMMA logo

Python Multi-Media API (PMMA)

PyPI - Wheel Python 3.8 Python 3.9 Python 3.10 Python 3.11 Windows Linux macOS GitHub commit activity GitHub commits since latest release

PMMA is a Python module targeted at helping you build applications in the Python programming language. It does this by providing its own tools covering areas like 2D graphics, noise generation, audio and video playback, event handling, text rendering and much more. The API has two fundamental goals; to make application development in Python easier, whilst also focusing on improving the performance and efficiency of the end result. The API is also being engineered with compatibility with other python modules, like Pygame, PIL and Numpy and is ideal for prototyping, application development, simulations, graphics intensive tasks and game development.

Features

PMMA 5 is here! Here is a list of all the changes since our last version, PMMA 4.2.2:

  • We have taken over 40% of the core API and migrated it into C++. This provides massive improvements to performance and memory and opens doors to additional features in future. In testing, PMMA 5 averages 97.53x faster than PMMA 4 is rendering as a worse case scenario, and is often able to exceed that ratio in typical application rendering scenarios.
  • We have made the installation and setup process for PMMA even easier, by providing pre-compiled versions of the API instead of relying on the end-user to compile the API themselves, its now just pip install pmma and go!
  • We have introduced an early preview of our text rendering API that will see extensive work over the lifetime of PMMA 5 and continued maintenance beyond.
  • We have significantly improved the interface for Perlin and Fractal Brownian motion and introduced AVX2 and AVX-512 acceleration that is automatically used on supported platforms.
  • We have significantly improved the interface for shape rendering, enabling color and position values to be dynamically generated (from random, Perlin noise or Fractal Brownian motion)
  • We have added the animations API, which has replaced the transitions API and will also see extensive work over the lifetime of PMMA 5 and beyond.
  • We have introduced type-hint support across the whole API to make it even easier to use.
  • We have re-worked the events API and in doing so introduced much more customizability.
  • We have made numerous improvements to the logging and profiling API, designed to bring them closer to the passport system, and simplify where logs are stored and managed.
  • We have made numerous smaller bug fixes and improvements to the API and will continue to do so as the API matures.

Features coming soon

With the release of PMMA 5 we enter a new era for the API. To date each major revision of the API has seen a major architecture rework, with PMMA 5 we believe the underlying structure for the API is now at its best. This means we can focus on building out PMMA from now on with new and improved features. This is the official release of PMMA 5 but we are not done with this generation of the API, as we will be migrating from OpenGL to BGFX, introducing themes and widgets support, collisions for 2D shapes, expanding our animations API and introducing physics and features that didn't make it into the launch of PMMA 5 through minor revisions in the near future.

PMMA 6 will then begin the process of introducing 3D graphics and a slew of supporting features to the API, whilst putting additional focus on building backwards compatibility and reliability.

Documentation

The documentation for PMMA is something we are committed to and are going to begin working on following the release of this major version of PMMA. The documentation for PMMA can be found here

Issues At Launch

The release of PMMA 5 brings with it plenty of new features which we explored earlier. However some features are missing from this launch and will be re-introduced as a priority. In most cases these features need additional attention that is better given post-launch, like for example video rendering which is absent from PMMA 5.0.0 as it will be reworked after our transition from OpenGL to the BGFX graphics API (it didn't make much sense with our limited team size to rework these areas twice, for the launch of PMMA 5 and again for the transition.)
Additionally, some features like the Camera component will not be returning for the duration of PMMA 5 as they serve no purpose in this update and will only become useful with the release of PMMA 6.

Finally, this is a major architecture change and it will take some time to identify and diagnose every potential issue - if you encounter a problem feel free to let us know here as a small team any feedback would be invaluable.

Final Points

Did you find something that didn't work as expected or think could be improved, please either raise it as an issue here and we will make amendments to the API. Alternatively, as a small team if you want to help contribute that would be equally invaluable!