Extra/ConvexDecomposition No way to construct a ConvexDecompInterface

Post Reply
Vitulus
Posts: 5
Joined: Thu Dec 20, 2018 10:55 am

Extra/ConvexDecomposition No way to construct a ConvexDecompInterface

Post by Vitulus »

While looking at the source code for https://github.com/kripken/bullet/tree/ ... omposition, which I plan to use to create convex shapes, I notice you can't create a ConvexDecompInterface. There is no demos for this however, I have been trying to work it out by myself. I notice you can create the ConvexBuilder class but it still requires a ConvexDecompInterface. I don't see anyway to get this class.

Is there anyway to initialize this class? I'm really confused.
User avatar
drleviathan
Posts: 849
Joined: Tue Sep 30, 2014 6:03 pm
Location: San Francisco

Re: Extra/ConvexDecomposition No way to construct a ConvexDecompInterface

Post by drleviathan »

ConvexDecompInterface is pure virtual. It defines an interface, hence the Interface part of its name. Pure virtual classes cannot be instantiated. You need to derive your own custom class (say MyConvexDecomp) from it, implement the MyConvexDecomp::ConvexDecompResult() method to do what you want, and instantiate one of those.
Post Reply