Skip to content

A small application used to test, compare and benchmark various physics libraries for Javascript.

Notifications You must be signed in to change notification settings

isaac-mason/Javascript-Physics-Library-Tests

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

41 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Javascript Physics Library Tests

A small application used to test, compare and benchmark various physics libraries for Javascript.
View it online here: https://cmann1.github.io/Javascript-Physics-Library-Tests/

So far there are three different demos for each library; I've tried to keep the demos as similar as possible across engines to allow them to be easily compared.

Demos

  • Basic - Randomly creates simple bodies.
  • Constraints - Compares similar constraints available in each engine.
  • Ragdoll - How well does each engine handle rag dolls?
  • Stress - Creates a large number of bodies - a good way to measure the performance of each engine.

A lot of these tests have been adapted from the Nape and Box2DFlash websites.

Libraries

  • Nape - http://napephys.com/
    • Complete with lots of features
    • Possibly the best performance and accuracy in stress test
    • Very large file size
    • Ported from AS3/Haxe
    • Lacks an organised Javascript port
    • Updated within the last year or two (as of Nov 2016)
  • Box2DWeb - https://github.com/hecht-software/box2dweb
    • Complete
    • Good performance on the stress test - similar to Nape
    • Ported from C++/AS3
    • Last updated one or two years ago (as of Nov 2016)
  • p2.js - http://schteppe.github.io/p2.js/
    • Complete
    • Poor performance on the stress test
    • Updated within the last few months (as of Nov 2016)
  • Matter.js - http://brm.io/matter-js/
    • Incomplete - lacks support for many constraints
    • Poor performance on the stress test
    • Updated recently (as of Nov 2016)
  • PhysicsJs http://wellcaffeinated.net/PhysicsJS/
    • Incomplete - lacks support for many constraints
    • Cannot handle the stress test
    • Seems like it was last updated 2 years ago (as of Nov 2016)

About

A small application used to test, compare and benchmark various physics libraries for Javascript.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 97.6%
  • TypeScript 2.2%
  • Other 0.2%