Jump to content
Nytro

PhysicsJS (Yes, a JavaScript Physics engine)

Recommended Posts

Posted

[h=1]PhysicsJS (Yes, a JavaScript Physics engine)[/h]

In today's Web Wednesday post we're highlighting something you might think a little oxymoronic, a JavaScript Physics engine.

It's still in an Alpha status, but even so, it's looking pretty cool...

[h=2]PhysicsJS[/h]

A modular, extendable, and easy-to-use physics engine for javascript

image%5B2%5D-174.png

PhysicsJS is still under development (alpha version 0.5.1), and documentation is unfinished. Feel free to use it, just be warned that the API is in flux and better documentation is on its way! (
!)

[h=4]Features[/h]

  • Use as an
    AMD Module (requireJS)
    , or
    global namespace
    .

  • Modular
    ! Only load what you need. The core library is only 31k minified.

  • Extendable
    ! Don’t like the collision detection algorithm? Replace it with your own!

  • Not tied to a specific renderer. Display it in
    DOM
    ,
    HTML5 Canvas
    , or whatever…

  • Easy! It’s a library
    written IN javascript
    … not C compiled into javascript. The syntax is familiar for javascript developers.

  • Extensions to support
    points
    ,
    circles
    , and arbitrary
    convex polygons
    .

  • Extensions to support
    constant gravity
    ,
    newtonian gravity
    ,
    collisions
    , and
    verlet constraints
    .

The fastest way to get a feel for what's possible is by checking out the Demos.

[h=2]Demos[/h]image%5B5%5D-102.png

There's even documentation already too.

[h=2]https://github.com/wellcaffeinated/PhysicsJS/wiki[/h]

Introductory documentation can be found on the
. The wiki contains more advanced usage instructions.

Due to the newness of this library, documentation is non-exhaustive. If there are any points of confusion, please feel free to log an issue or
. You can also edit the wiki yourself to fill in the gaps. Any help with documenting is appreciated.

[h=4]Topics[/h]

And the source is officially available too;

[h=2]https://github.com/wellcaffeinated/PhysicsJS[/h]image%5B9%5D-46.png

Sursa: PhysicsJS (Yes, a JavaScript Physics engine) | Coding4Fun Blog | Channel 9

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...