Skip to main content
Help us improve Python packaging – donate today!

SDL2 wrapper with cffi

Project Description

pysdl2-cffi is a Python wrapper for SDL2 written using cffi, featuring:

  • A cffi + dlopen interface to the underlying SDL2 libraries.
  • Automatically generated, consistent helper functions for SDL2, SDL_image, SDL_mixer, and SDL_ttf that hide most allocation and dereferencing.
  • Useful docstrings on every function, including the C function signature and (for SDL2 only) the library’s original doxygen documentation reformatted as Sphinx restructured text.
  • A small collection of libSDL2’s original example / test programs converted to Python using Eric S. Raymond’s ctopy.

The goal is to provide a flat, consistent, faithful-to-C binding with some more-Pythonic renaming and conveniences.

This wrapper won’t contain anything that doesn’t directly translate to part of the library’s API. The goal is to be a dependency for something like pygame, not a replacement.

This library is developed on Linux and OS X; not yet tested on Windows.

This library is licensed under the GPLv2 or (at your option) any later version.

Install with pip, or download from https://pypi.python.org/pypi/pysdl2-cffi

Source hosted at https://bitbucket.org/dholth/pysdl2-cffi

Documentation hosted at https://pythonhosted.org/pysdl2-cffi

Release history Release notifications

History Node

0.8.0

History Node

0.7.0

History Node

0.6.0

History Node

0.5.1

This version
History Node

0.5.0

History Node

0.4.0

History Node

0.3.1

History Node

0.3.0

History Node

0.2.0

History Node

0.1.0

History Node

0.0.2

History Node

0.0.1

Download files

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

Filename, size & hash SHA256 hash help File type Python version Upload date
pysdl2_cffi-0.5.0-py2.py3-none-any.whl (108.8 kB) Copy SHA256 hash SHA256 Wheel py2.py3 Sep 4, 2014
pysdl2-cffi-0.5.0.tar.gz (188.3 kB) Copy SHA256 hash SHA256 Source None Sep 4, 2014

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging CloudAMQP CloudAMQP RabbitMQ AWS AWS Cloud computing Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page