Skeletal Animation

Post Reply
deityseven
Posts: 1
Joined: Mon Jun 27, 2022 1:42 am

Skeletal Animation

Post by deityseven »

Hello, everybody!
I'm working on a game, but I'm having some problems.
My game is based on c++ and opengl. Use Bullet as the physics engine.
The development environment:
1. Windows10
2. VS2017
3. CMake
Code that is ready to run:
1. Use assimp import an .obj model and display it in a window.
2. Use Bullet's btKinematicCharacterController class control the model to walk forward and jump.
I want the model to do something, like surrender.
The hard part:
1. The .obj model consists of only one mesh, so I can't use constraints on it.
2. I can't use any other model.

I also wonder if the model animation should be implemented using the constraint bullet. Is there any other way to make this easier ?
Or, whether this part of the module should be implemented in another library ?
Thank you for reading so far. :)
User avatar
drleviathan
Posts: 849
Joined: Tue Sep 30, 2014 6:03 pm
Location: San Francisco

Re: Skeletal Animation

Post by drleviathan »

Here are some scenarios of increasing complexity:

(1) Kinematic character always collides like a capsule (or some other simple shape) regardless of their animation state.

(2) Dynamic character always collides like a capsule (or some other simple shape) regardless of their animation state.

(3) Character's collision shape changes to approximate its animation state but it collides kinematically (e.g. cannot be affected by dynamic objects in a physicsy way -- it may still be possible to "trigger" affectations from physics events but the affected behaviors are canned animation).

(4) Character collision shape changes to approximate its animation state and it collides dynamically (e.g. dynamic objects can bump the character and it reacts using physics simulation (ragdoll or physicalliy driven puppet).

Which one do you want to do?

There aren't many utils in Bullet to support any of those. As I recall there is an example btKinematicCharacterController which could maybe be used as a starting point for (1). Otherwise you would have to write your own code or maybe find someone else's working example.
Post Reply