mkrebser / GPUInstance

Instancing & Animation library for Unity3D
Other
228 stars 44 forks source link

Enabling/Disabling Animations For Certain Bones #2

Closed CybeRockStudio closed 2 years ago

CybeRockStudio commented 2 years ago

Hi There

Really Powerful Tool You Have Created Here I'm Very Happy With How Stable It Is

My Question Is How Can I Enable/Disable Some Bones Per Animation To Achieve Some Sort Of Animation Blending

Kind Regards & Thanks For Taking Time To Answer Me

CybeRockStudio commented 2 years ago

And Yes,

How Do I Change Animations At Runtime?

CybeRockStudio commented 2 years ago

Hi There After About 3 Hrs Digging I Found Answers To My Solutions 💯

CybeRockStudio commented 2 years ago

one last question if i may ask

is animation transitioning implementable witht his approach?

CybeRockStudio commented 2 years ago

and if it is can you give me a guide on how to do it?

mkrebser commented 2 years ago

You would have to refactor the compute shaders to implement blending.

You would need a second set of animation parameters (animation Id, speed, looping) and blend parameters.

In the compute shaders you would calculate two local bone animations - and lerp between them

On Fri, Jun 3, 2022, 12:12 PM TheCybeRock @.***> wrote:

and if it is can you give me a guide on how to do it?

— Reply to this email directly, view it on GitHub https://github.com/mkrebser/GPUInstance/issues/2#issuecomment-1146141861, or unsubscribe https://github.com/notifications/unsubscribe-auth/AES73IGFMTT7ZTNFW4QG7P3VNIVG7ANCNFSM5XX724GQ . You are receiving this because you are subscribed to this thread.Message ID: @.***>

CybeRockStudio commented 2 years ago

hey thanks for the guidance