Elements: Difference between revisions

From OLPC
Jump to navigation Jump to search
(info update with git checkout command)
(+ todo)
Line 20: Line 20:


git clone git://git.assembla.com/elements.git
git clone git://git.assembla.com/elements.git



== More Informations ==
== More Informations ==
Line 25: Line 26:
* A lively and open development and support team is having fun improving and helping out :)
* A lively and open development and support team is having fun improving and helping out :)
* The Box2D compatible version of '''Elements''' will come these days. In the meantime the Chipmunk engine is almost fully supported by the [[Elements/Chipmunk|previous version]] of Elements.
* The Box2D compatible version of '''Elements''' will come these days. In the meantime the Chipmunk engine is almost fully supported by the [[Elements/Chipmunk|previous version]] of Elements.


== To Do ==
* For the list of open tasks, please have a look at our tickets page: http://www.assembla.com/spaces/elements/tickets


== Feature Request ==
What features would you like to have implemented? :)
* ''add here''




Line 34: Line 44:
* Ken (SWIG interface, API)
* Ken (SWIG interface, API)
''The team is open for anyone to join :)''
''The team is open for anyone to join :)''



== Screenshots ==
== Screenshots ==

Revision as of 20:56, 24 March 2008

Elements banner1.jpg


About

The Elements project is all about free and easy 2D physics for python -- with main attention on:

  1. An easy-to-use, fast 2D physics API
  2. Examples and documentation on how to use the API
  3. Providing the examples as bundles, as they are already interesting and fun
  4. Speed optimization (also with an eye on the XO laptop :)
  5. Development of ideas for education and playful-learning


Browse Source | Assembla Space | Elements.xo (old, 195 kb) | box2d xo demo | Documentation
IRC: #elements on irc.freenode.net
git clone git://git.assembla.com/elements.git


More Informations

  • Source-Code is GPL licensed - so do with it what you want! Even eat it :)
  • A lively and open development and support team is having fun improving and helping out :)
  • The Box2D compatible version of Elements will come these days. In the meantime the Chipmunk engine is almost fully supported by the previous version of Elements.


To Do


Feature Request

What features would you like to have implemented? :)

  • add here


Team

The team is open for anyone to join :)


Screenshots

(from Elements/Screenshots)

Screenshot1.png Screenshot2.png

Screenshot3.png Screenshot4.png


Pygame Example

The typical usage in pygame can look like this:

      import pygame
      from pygame.locals import *
      from pygame.color import *   

      from elements import *
       
      pygame.init()
      screen = pygame.display.set_mode((800, 800))
      clock = pygame.time.Clock()

      world = elements()
      world.add_wall((100, 200), (300, 200))
         
      # Main Game Loop:
      while running:
         # Event Handling
         # Maybe calling world.add_ball(event.pos) or world.add_square(event.pos)
         # ...

         screen.fill((255,255,255))

         # Update & Draw World
         world.update()
         world.draw(screen)

         # Flip Display
         pygame.display.flip()
          
         # Try to stay at 50 FPS
         clock.tick(50)