docs/android/dokka/filament-android/com.google.android.filament/-renderable-manager/-builder/skinning.md
//filament-android/com.google.android.filament/RenderableManager/Builder/skinning
[main]
open fun skinning(skinningBuffer: SkinningBuffer, boneCount: Int, offset: Int): RenderableManager.Builder
Enables GPU vertex skinning for up to 255 bones, 0 by default.
Skinning Buffer mode must be enabled.
Each vertex can be affected by up to 4 bones simultaneously. The attached VertexBuffer must provide data in the BONE_INDICES slot (uvec4) and the BONE_WEIGHTS slot (float4).
See also setSkinningBuffer, setBonesAsMatrices or setBonesAsQuaternions, which can be called on a per-frame basis to advance the animation.
this Builder object for chaining calls
main
| skinningBuffer | null to disable, otherwise the SkinningBuffer to use |
| boneCount | 0 to disable, otherwise the number of bone transforms (up to 255) |
| offset | offset in the SkinningBuffer |
| setSkinningBuffer |
| SkinningBuffer |
[main]
open fun skinning(boneCount: Int): RenderableManager.Builder
[main]
open fun skinning(boneCount: Int, bones: Buffer): RenderableManager.Builder
Enables GPU vertex skinning for up to 255 bones, 0 by default.
Skinning Buffer mode must be disabled.
Each vertex can be affected by up to 4 bones simultaneously. The attached VertexBuffer must provide data in the BONE_INDICES slot (uvec4) and the BONE_WEIGHTS slot (float4).
See also setBonesAsMatrices, which can be called on a per-frame basis to advance the animation.
main
| boneCount | Number of bones associated with this component |
| bones | A FloatBuffer containing boneCount transforms. Each transform consists of 8 float. float 0 to 3 encode a unit quaternion w+ix+jy+kz stored as x,y,z,w. float 4 to 7 encode a translation stored as x,y,z,1 |
| SkinningBuffer |