Chipmunk Physics Or Box2D For C++ 2D GameEngine?
-
- Home
- Questions
- Tags
- Users
- Companies
- Labs
- Jobs
- Discussions
- Collectives
-
Communities for your favorite technologies. Explore all Collectives
- Teams
Ask questions, find answers and collaborate at work with Stack Overflow for Teams.
Try Teams for free Explore Teams - Teams
-
Ask questions, find answers and collaborate at work with Stack Overflow for Teams. Explore Teams
Collectives™ on Stack Overflow
Find centralized, trusted content and collaborate around the technologies you use most.
Learn more about CollectivesTeams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
Learn more about TeamsGet early access and see previews of new features.
Learn more about Labs Chipmunk Physics or Box2D for C++ 2D GameEngine? Ask Question Asked 14 years, 7 months ago Modified 13 years, 3 months ago Viewed 5k times 12I'm developing what it's turning into a "cross-platform" 2D Game Engine, my initial platform target is iPhone OS, but could move on to Android or even some console like the PSP, or Nintendo DS, I want to keep my options open.
My engine is developed in C++, and have been reading a lot about Box2D and Chipmunk but still I can't decide which one to use as my Physics Middleware.
Chipmunk appears to have been made to be embedded easily, and Box2D seems to be widely used. Chipmunk is C , and Box2D is C++, but I've heard the API's of Box2D are much worse than chipmunk's API's.
For now I will be using the engine shape creation and collision detection features for irregular polygons (not concave).
I value:
1) Good API's 2) Easy to integrate. 3) Portability.And of course if you notice anything else, I would love to hear it.
Which one do you think that would fit my needs better ?
EDIT: I ended up writing an article about my particular choice, you can find it here
Share Improve this question Follow edited Aug 29, 2010 at 23:02 Goles asked Apr 25, 2010 at 4:05 GolesGoles 11.8k24 gold badges80 silver badges140 bronze badges 3- 1 would be interested to see your final product if it ever got finished? – adam Commented Dec 30, 2010 at 12:56
- Voting to close as too broad / tool rec. – Ciro Santilli OurBigBook.com Commented Apr 15, 2016 at 11:59
- @Goles I can't reach to the site. – Ekrem Dinçel Commented Jun 1, 2020 at 14:55
3 Answers
Sorted by: Reset to default Highest score (default) Trending (recent votes count more) Date modified (newest first) Date created (oldest first) 6You are right, chipmunk has been developed improving a lot of the places where Box2D falls down.
However, Box2D is definitely the more established platform and from my personal experience when making the decision of which engine to use, I found that Box2D had a much larger community following, so was easier to learn by example.
Share Improve this answer Follow answered Apr 25, 2010 at 8:50 adamadam 22.6k21 gold badges91 silver badges120 bronze badges 1- I have found from personal experience that chipmunk tends to be a bit "quirky". Lots of hacks and tweaks were needed for me to get things right. Of course the same may happen if I were to go to Box2D – eviljack Commented May 6, 2010 at 12:18
I use both, but when I can choose, I go for chipmunk, it has much better API, and was much easier to learn...
But that was because I learned it without need for a community, the manual is completly fine.
UPDATE: My current game is using Box2D, and I wish I used Chipmunk with it... Mostly because Box2D has two serious issues, that are exacerbated on my game: First, it has a REALLY OLD bug where objects "snag" on corners, my game is a breakout game, so when the ball is "rolling" along a wall, sometimes it snag and is flung away from the wall, lots of people asked why my game physics looks "random".
The other issues that Box2D have, is how it store objects, Chipmunk use a spatial hash, and Box2D use a binary tree, my game was having MASSIVE slowdowns in levels with lots of objects, I asked Erin (author of Box2D) the reason, and he explained that because Box2D uses binary tree, if you place objects in a grid (like I said, my game is a breakout clone! everything is in a grid!) the tree gets unbalanced, and Box2D slows down. The solution for my game was make some levels into a "checkerboard" pattern to avoid this problem.
So, for all tile-based games, I will just use Chipmunk, Box2D REALLY is unsuitable for those (because the "snag" on tile corner bug, and the slowdown bug with tile grid)
Share Improve this answer Follow edited Jul 7, 2010 at 20:32 answered May 4, 2010 at 3:14 speederspeeder 6,2765 gold badges36 silver badges51 bronze badges 1- Actually I think not needing a community is quite nice, I started with Box2d today... I will evaluate both myself, and stick with the one I find the best :-), thanks for the comment! – Goles Commented May 4, 2010 at 5:50
Chipmunk is straight C, while Box2D is C++. There is also a new set of Objective-C bindings for Chipmunk, but they are not free to use commercially.
As I understand it, Chipmunk does not support Continuous Collision Detection, but Box2D does. This is important to prevent "tunneling" (objects passing slightly through eachother when moving at high speeds)
At the end of the day, from what I hear, they're both great. If you prefer C++ to C or need continuous collision detection, you should probably choose Box2D.
If you'd rather use a pure C library, go with Chipmunk.
I personally use Box2D and my experience has been fantastic so far.
Also, I think Box2D has a different (possibly larger) set of joint types, so that could be something to consider...
Share Improve this answer Follow answered Aug 29, 2011 at 22:53 dudeskidudeski 1411 silver badge2 bronze badges Add a comment |Your Answer
Reminder: Answers generated by artificial intelligence tools are not allowed on Stack Overflow. Learn more
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Draft saved Draft discardedSign up or log in
Sign up using Google Sign up using Email and Password SubmitPost as a guest
Name EmailRequired, but never shown
Post Your Answer DiscardBy clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.
Not the answer you're looking for? Browse other questions tagged
or ask your own question.- The Overflow Blog
- Your docs are your infrastructure
- Featured on Meta
- More network sites to see advertising test [updated with phase 2]
- We’re (finally!) going to the cloud!
- Call for testers for an early access release of a Stack Overflow extension...
Linked
6 For collision detection only, is Chipmunk or Box2d the better tool? 2 Best games/physics engines to use? 0 How to make the collision detection in iphone sdkRelated
2 cocos2d iphone - game architecture: physics VS. code simulated sprite behaviors 3 Developing A Simple Game without using Game Engines? 5 Conceptual iPhone 2d game dev question. Quartz? Cocos2d? Chipmunk? Box2d? 2 Is Box2D the best solution for my iphone game scenario? 6 For collision detection only, is Chipmunk or Box2d the better tool? 0 iOS - Cocos2d, Box2d or Chipmunk 0 iOS + Cocos2D: Simple Colission/Bounce (do I need box2d/chipmunk?) 0 Should Cocos2d be used or create own code in C 0 Chipmunk / Box2D tutorials that DON'T involve cocos2d 1 Chipmunk Physics/Cocos2d/Objective-c - cpSpaceBBQueryHot Network Questions
- How can I politely decline a request to join my project by a free rider professor
- If Occam's razor supports naturalism over theism, then why was William of Ockham, its author, a theist and not a naturalist?
- Standard SMD chip resistor with higher power in the same package
- Applying local unitary operator of one qubit on an entangled state
- If scent means a pleasant smell, why do we say "lovely scent" or "sweet scent"?
- Why is a head called a head?
- Are PA and Counting Theory synonymous\bi-interpretable?
- Efficiency of Coaxial Rotors vs Single Rotors (and Contrarotating Propellers)
- How do I remove a hat from my horse?
- Sequence with diagonal lines and circles
- Walks in Nice (Nizza)
- Why is Ukraine's conscription age (still) so high (25)?
- Does the 90 day window for VWP reset for extended stay in Mexico?
- turn wire frame of ico sphere into a cage
- Importing gzipped CSV files in QGIS
- What mechanism could cause a person not to cast a reflection?
- How does this AM modulator work
- A fantasy story with an imp in a box that paints pictures
- Find the Smallest Data Type for a Number
- A statement on concatenation of integers
- If the hard problem of consciousness is unanswerable, is it a hard problem or just a bad question?
- What powers do police have to force people onto trains?
- Hearing the cry of a baby - abandoning practice for action?
- Align TikZ pictures horizontally
To subscribe to this RSS feed, copy and paste this URL into your RSS reader.
lang-cppTừ khóa » Chipmunk Vs Box2d
-
Box2D Vs Chipmunk : R/gamedev - Reddit
-
Chipmunk2D Physics Pro
-
Chipmunk Physics (violet) Vs Box2D Physics (green) - YouTube
-
Box2D Vs Chipmunk - Compare Differences And Reviews? - LibHunt
-
Chipmunk Vs Box2D - Awesome C++ - LibHunt
-
Chipmunk Physics And Box2D Comparison - TIGSource Forums
-
Box2D, Bullet And Chipmunk? - C++ - Cocos Forums
-
Chipmunk Vs. Box2D - Blitz Community Forum Archive
-
Top 14 Chipmunk Vs Box2d
-
Cocos2d-x Physic: Chipmunk Vs Box2D (1/2) - Minn Game
-
Box2D Or Chipmunk. What Is Easier And Better For 2D Platform Games?
-
Chipmunk Vs. Box2D - Sparrow Forum
-
Chipmunk (software) - Wikipedia