{ "info": { "author": "Henry S. Harrison", "author_email": "henry.schafer.harrison@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 3 - Alpha", "Intended Audience :: Developers", "License :: OSI Approved :: BSD License", "Operating System :: OS Independent", "Programming Language :: Python", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.3", "Programming Language :: Python :: 3.4", "Topic :: Multimedia :: Graphics", "Topic :: Utilities" ], "description": "========\npyglet2d\n========\n\nPolygon primitives for `pyglet`_.\n\n+--------------------+-------------------+---------------+\n| | |travis-badge| | | |version-badge| | | |git-badge| |\n| | |coverage-badge| | | |license-badge| | | |hg-badge| |\n+--------------------+-------------------+---------------+\n\n.. |travis-badge| image:: http://img.shields.io/travis/hsharrison/pyglet2d.png?style=flat\n :alt: Travis-CI Build Status\n :target: https://travis-ci.org/hsharrison/pyglet2d\n\n.. |coverage-badge| image:: http://img.shields.io/coveralls/hsharrison/pyglet2d.png?style=flat\n :alt: Coverage Status\n :target: https://coveralls.io/r/hsharrison/pyglet2d\n\n.. |version-badge| image:: http://img.shields.io/pypi/v/pyglet2d.png?style=flat\n :alt: PyPi Package\n :target: https://pypi.python.org/pypi/pyglet2d\n\n.. |license-badge| image:: http://img.shields.io/badge/license-BSD-blue.png?style=flat\n :alt: License\n :target: https://pypi.python.org/pypi/pyglet2d\n\n.. |git-badge| image:: http://img.shields.io/badge/repo-git-lightgrey.png?style=flat\n :alt: Git Repository\n :target: https://github.com/hsharrison/pyglet2d\n\n.. |hg-badge| image:: http://img.shields.io/badge/repo-hg-lightgrey.png?style=flat\n :alt: Mercurial Repository\n :target: https://bitbucket.org/hharrison/pyglet2d\n\n\nThis package provides a ``Shape`` object that can be acts as an interface between the libraries `polygon`_ and `pyglet`_.\nThe former provides numerical routines for handling shapes, and the latter can process OpenGL bindings.\nWith pyglet2d, you can incorporate 2D shapes into your applications without having to write your own OpenGL calls.\n\nFeatures\n========\n\n- In addition to the standard constructor (from a list or array of points), four others are provided:\n ``Shape.regular_polygon``, ``Shape.circle``, ``Shape.rectangle``, and ``Shape.from_dict``.\n The latter is a specification-based constructor that is easy to use with JSON or YAML.\n- ``Shape`` has two methods that are useful as `pyglet`_ callbacks: ``Shape.draw`` and ``Shape.update``.\n A ``Shape`` can be given a velocity and/or an angular velocity, and it will be updated accordingly when ``Shape.update`` is called.\n- A ``Shape`` can be manipulated using the methods ``Shape.scale``, ``Shape.rotate``, ``Shape.flip_x``, ``Shape.flip_y``, ``Shape.flip``, and ``Shape.translate``, or with in-place arithmetic (e.g. ``shape += [5, 0]``).\n- Alternatively, setting the properties ``Shape.center`` and ``Shape.radius`` will translate and scale the shape, respectively.\n- Clipping operations provided by `polygon`_ are bound to the operators \\|, +, (union), & (intersection), - (difference), and ^ (xor).\n- Additional `polygon`_ methods can be accessed directly from the ``Shape.poly`` attribute, where the ``Polygon`` object is stored.\n- Shortcuts are provided to `polygon`_ functions via the boolean methods ``Shape.overlaps(other)`` and ``Shape.covers(other)``.\n\nExample\n=======\n\nSee ``tests/graphics_demo.py`` for a usage example.\nThis script also serves as a test.\nRun it to make sure that your graphics pipeline is working correctly::\n\n python tests/graphics_demo.py\n\nRequirements\n============\n\n- Python >= 3.3\n- `pyglet`_ >= 1.2alpha1. This must be manually installed as it is not on PyPi.\n- `polygon`_ >= 3\n- `numpy`_\n\nInstallation\n============\n\n::\n\n pip install pyglet2d --upgrade\n\nDocumentation\n=============\n\nhttps://pyglet2d.readthedocs.org/\n\nDevelopment\n===========\n\nTo run the all tests run::\n\n tox\n\n.. _pyglet: http://www.pyglet.org/index.html\n.. _polygon: http://www.j-raedler.de/projects/polygon/\n.. _numpy: http://www.numpy.org/\n\n\nChangelog\n=========\n\n0.2.1 (2014-07-27)\n------------------\n\n* All in-place operations now return the ``Shape``, allowing operations to be chained.\n\n0.2.0 (2014-07-27)\n------------------\n\n* Added optional arguments ``y_factor`` and ``center`` to ``Shape.scale``.\n* Implemented ``Shape.rotate``.\n* Implemented angular velocity.\n* Argument ``start_angle`` in ``Shape.regular_polygon`` is now in radians.\n* ``graphics_test.py`` renamed to ``graphics_demo.py``.\n* Implement ``Shape.flip_x``, ``Shape.flip_y``, and ``Shape.flip``.\n* Explicitly set the ``Polygon3`` data style to ``STYLE_NUMPY``.\n* Implement ``Shape`` union and difference with the addition and subtraction operators.\n* Don't throw an error when comparing the equality of shapes with different numbers of vertices.\n\n0.1.2 (2014-07-26)\n------------------\n\n* Fixed Shape docstring.\n* Changed docs from napoleon to numpydoc.\n\n0.1.1 (2014-07-26)\n------------------\n\n* Mocking of graphics calls to pyglet, for testing without a display (e.g., on Travis).\n* Fixed intersphinx links in docs.\n* Fixed coveralls.io integration.\n\n0.1.0 (2014-07-25)\n------------------\n\n* First release on PyPI.", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/hsharrison/pyglet2d", "keywords": "2D,geometry,graphics,shape,shapes,polygon,polygons,pyglet,opengl", "license": "BSD", "maintainer": null, "maintainer_email": null, "name": "pyglet2d", "package_url": "https://pypi.org/project/pyglet2d/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/pyglet2d/", "project_urls": { "Download": "UNKNOWN", "Homepage": "https://github.com/hsharrison/pyglet2d" }, "release_url": "https://pypi.org/project/pyglet2d/0.2.1/", "requires_dist": null, "requires_python": null, "summary": "2D shape primitives for pyglet.", "version": "0.2.1" }, "last_serial": 1177750, "releases": { "0.1.0": [ { "comment_text": "", "digests": { "md5": "eb053c79285a397e85c0f5f458e9f93b", "sha256": "96732d73f1f87928624fe71b6632625fa94328f5b41650061906212d6ff0e6aa" }, "downloads": -1, "filename": "pyglet2d-0.1.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "eb053c79285a397e85c0f5f458e9f93b", "packagetype": "bdist_wheel", "python_version": "3.4", "requires_python": null, "size": 8080, "upload_time": "2014-07-26T07:20:48", "url": "https://files.pythonhosted.org/packages/46/c4/11efde6cfd4a0413f53692dc12320363c96bd1e8e0cc11b2a2d7ce3d04ea/pyglet2d-0.1.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "81243da886f35db7acbab2a6a441879e", "sha256": "41f17b04e24ba77c27303d56062c988a182ba343517da22596b902cb7722061e" }, "downloads": -1, "filename": "pyglet2d-0.1.0.tar.gz", "has_sig": false, "md5_digest": "81243da886f35db7acbab2a6a441879e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 13452, "upload_time": "2014-07-26T07:20:45", "url": "https://files.pythonhosted.org/packages/bd/25/fc556c22fd5b8b203e78b7b901ebc1d01b68577d2223a4ae914971b3de65/pyglet2d-0.1.0.tar.gz" } ], "0.1.1": [ { "comment_text": "", "digests": { "md5": "24168b98fa8b449f134854c9d52df27a", "sha256": "0f19cbccd252183ca93aba92a5e4dee36615e9ad6546a857bed52566e8666205" }, "downloads": -1, "filename": "pyglet2d-0.1.1-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "24168b98fa8b449f134854c9d52df27a", "packagetype": "bdist_wheel", "python_version": "3.4", "requires_python": null, "size": 8250, "upload_time": "2014-07-26T20:17:01", "url": "https://files.pythonhosted.org/packages/02/30/bbb43397bba2859a2fd3a3ff6d84ccf7948844fd6c41e33ebd12651dbb1f/pyglet2d-0.1.1-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "a59722d697037d9d2d21b054dc0fc0c4", "sha256": "11c2851b9734d853db70afdb459fad62ba9153ced0eeda48ed5095d5ed7f69d1" }, "downloads": -1, "filename": "pyglet2d-0.1.1.tar.gz", "has_sig": false, "md5_digest": "a59722d697037d9d2d21b054dc0fc0c4", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14033, "upload_time": "2014-07-26T20:16:58", "url": "https://files.pythonhosted.org/packages/bf/08/2e357ac596b8dd0ecc42501ddc0a397df77d7798d5185a1306aef15666a3/pyglet2d-0.1.1.tar.gz" } ], "0.1.2": [ { "comment_text": "", "digests": { "md5": "0e7d68af133662eee428d5f5c42e83d1", "sha256": "66bfaf5a3527a0cae67c1496a436ceb65bc1ae48b7147f54ed4b4f2f7857d5a2" }, "downloads": -1, "filename": "pyglet2d-0.1.2-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "0e7d68af133662eee428d5f5c42e83d1", "packagetype": "bdist_wheel", "python_version": "3.4", "requires_python": null, "size": 8310, "upload_time": "2014-07-27T01:05:50", "url": "https://files.pythonhosted.org/packages/14/86/02a4f9fb20ae385b13dd5dd4fece95ad4f1524c6fc78e95fe7f75b72b437/pyglet2d-0.1.2-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "651e94921831d52018e8f9ffcbd9a9d8", "sha256": "a6c2ddc21b6b3e46b686ce3c2baa1b544f5ab2963261c3c9ef15ae25651379a8" }, "downloads": -1, "filename": "pyglet2d-0.1.2.tar.gz", "has_sig": false, "md5_digest": "651e94921831d52018e8f9ffcbd9a9d8", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14077, "upload_time": "2014-07-27T01:05:47", "url": "https://files.pythonhosted.org/packages/66/49/28af10497e80dcb85e68ed0a18d7a08f8e8883ce49b2207bf2164ed3dc75/pyglet2d-0.1.2.tar.gz" } ], "0.2.0": [ { "comment_text": "", "digests": { "md5": "250a1c88d518a5b1cf683e2c33de8265", "sha256": "01159cc62d58f2f0f0c8f7588ac5ed1a2fe8af5bf4a20ce3d096eb38218a5712" }, "downloads": -1, "filename": "pyglet2d-0.2.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "250a1c88d518a5b1cf683e2c33de8265", "packagetype": "bdist_wheel", "python_version": "3.4", "requires_python": null, "size": 9370, "upload_time": "2014-07-27T18:31:04", "url": "https://files.pythonhosted.org/packages/cf/a0/3a2d082375eb43568073e825ed7b04e4ba6efe650578d6651d343b15c931/pyglet2d-0.2.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "e3cc915f7fb8c903acf58ed39a65d471", "sha256": "2aee2288d3c5c6d920ed29d88d02e16b72d9bef7df25514628a0971d218b3259" }, "downloads": -1, "filename": "pyglet2d-0.2.0.tar.gz", "has_sig": false, "md5_digest": "e3cc915f7fb8c903acf58ed39a65d471", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 16223, "upload_time": "2014-07-27T18:31:01", "url": "https://files.pythonhosted.org/packages/da/53/95558e610f639688fede6cce752323b08ce336840d6197e8e4045658f6fe/pyglet2d-0.2.0.tar.gz" } ], "0.2.1": [ { "comment_text": "", "digests": { "md5": "f88bc1b2ca5e126e2f9da27567bb956a", "sha256": "f4a55f0871a2cc1628fb1f4eabfb0f70e6fcf9d98dfdd15515030b4919c16846" }, "downloads": -1, "filename": "pyglet2d-0.2.1-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "f88bc1b2ca5e126e2f9da27567bb956a", "packagetype": "bdist_wheel", "python_version": "3.4", "requires_python": null, "size": 9465, "upload_time": "2014-07-27T19:22:18", "url": "https://files.pythonhosted.org/packages/f2/9b/22f7b079732c59d1200bc6bfaff6f777828f82c31dd13b79a5681a4a6dc8/pyglet2d-0.2.1-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "407cae038d7177796ba9572f046842af", "sha256": "3afc2517392d2023a58526e2af21320692a91c36290069f4118b3d4fcbe2b98f" }, "downloads": -1, "filename": "pyglet2d-0.2.1.tar.gz", "has_sig": false, "md5_digest": "407cae038d7177796ba9572f046842af", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 16281, "upload_time": "2014-07-27T19:22:15", "url": "https://files.pythonhosted.org/packages/38/eb/c19e645d4cfb8195cb1217888d31d0079d41ba7ed2a1147ba6d4ef414d41/pyglet2d-0.2.1.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "f88bc1b2ca5e126e2f9da27567bb956a", "sha256": "f4a55f0871a2cc1628fb1f4eabfb0f70e6fcf9d98dfdd15515030b4919c16846" }, "downloads": -1, "filename": "pyglet2d-0.2.1-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "f88bc1b2ca5e126e2f9da27567bb956a", "packagetype": "bdist_wheel", "python_version": "3.4", "requires_python": null, "size": 9465, "upload_time": "2014-07-27T19:22:18", "url": "https://files.pythonhosted.org/packages/f2/9b/22f7b079732c59d1200bc6bfaff6f777828f82c31dd13b79a5681a4a6dc8/pyglet2d-0.2.1-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "407cae038d7177796ba9572f046842af", "sha256": "3afc2517392d2023a58526e2af21320692a91c36290069f4118b3d4fcbe2b98f" }, "downloads": -1, "filename": "pyglet2d-0.2.1.tar.gz", "has_sig": false, "md5_digest": "407cae038d7177796ba9572f046842af", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 16281, "upload_time": "2014-07-27T19:22:15", "url": "https://files.pythonhosted.org/packages/38/eb/c19e645d4cfb8195cb1217888d31d0079d41ba7ed2a1147ba6d4ef414d41/pyglet2d-0.2.1.tar.gz" } ] }