How to increase number of vertices of polygon (BOX2D)

Does anyone know how to increase maximum number of vertices for a polygon. Currently default value is 8 but I want at least 30 vertices for a polygon shape. Any help is appreciated 🤓
It should be as easy as changing the constant in the source.

https://github.com/jbox2d/jbox2d/blob/m ... s.java#L91

Although, expect a memory/performance hit if you're increasing it to 30.

Another option is to use a physics editor to generate multiple polygon shapes from the 30 vertices. The R.U.B.E. Box2D editor has a feature for this.

https://www.iforce2d.net/rube/

Physics Editor is another.

https://www.codeandweb.com/physicseditor/
thanks for your reply isaacburns!
I am using Physics Editor by codeandweb but most number of vertices for most of the shapes it generates are greater than 8 (normally in the range of 12-20). Thats why i was looking to increase the number of vertices of the polygon in box2d
Perhaps you are using the hull polygon from the data exported from Physics Editor.

Instead, use the list of convex sub-polygons. These are limited to the default maximum number of vertices (8) in Box2D.

Create a b2PolygonShape from each of these and attach them to the same b2Body.
ok thanks a lot buddy 🙂

Original thread: https://box2d.org/forum/viewtopic.php?t=9967