JannisX11 / blockbench

Blockbench - A low poly 3D model editor
https://www.blockbench.net
GNU General Public License v3.0
3.07k stars 272 forks source link

Inverse Kinematic Animation Export result is bugged out if root or main body model is rotated #2185

Open DrageonDB opened 5 months ago

DrageonDB commented 5 months ago

What are you trying to do, and what do you expect to happen?

Step to reproduce:

  1. Download this model (blockbench file)
  2. Open this model
  3. Compare wolf animation both Blockbench and Sketchfab result
  4. Then try to export as gltf and see in GLTF viewer

This is my model that affected: https://skfb.ly/oPLzG (Whulvk Werewolf Lycan)

My note: I think this bug is related to rotated model as root or main body, then it causes Blockbench inverse kinematics to render incorrectly.

Expected Results: These model animations result are same after export, inverse kinematic bug I think in Blockbench, but not after export.

What happens instead?

This model animation was bugged out after export

Model format in which the issue occurs

Generic Model

Blockbench variant

Program

Blockbench version

4.9.3

Operating System

Windows 11 22H2

Installed Blockbench plugins

No response

daniel-oliveira1401 commented 5 months ago

I have a similar issue, but in my case, what is happening is that whenever i animate using IK, the bones affected by the animation have their rotation missing the last frame. For example, below is the end of the output for a given bone for 5s animation:

                                            "4.5": [0.00047, 0.27986, 0.19296],
                    "4.5417": [0.00046, 0.2764, 0.19036],
                    "4.5833": [0.00045, 0.27323, 0.18797],
                    "4.625": [0.00044, 0.27035, 0.18581],
                    "4.6667": [0.00043, 0.26778, 0.18388],
                    "4.7083": [0.00042, 0.2655, 0.18217],
                    "4.75": [0.00042, 0.26353, 0.18069],
                    "4.7917": [0.00041, 0.26186, 0.17944],
                    "4.8333": [0.00041, 0.2605, 0.17841],
                    "4.875": [0.0004, 0.25944, 0.17762],
                    "4.9167": [0.0004, 0.25869, 0.17705],
                    "4.9583": [0.0004, 0.25825, 0.17672]

It generates up to timecode 4.9583 and then doesn't generate the last frame (timecode 5.0). This issue is not only for the output created with exporting the animation, but for the keyframes generated using the "Bake Inverse Kinematics" as well (it only generates keyframes up to timecode 4.9583 for my 5s animation)