// // Generated by Brutal.Jolt.Generate; do not edit by hand. #nullable enable using Brutal.Interop; using Brutal.Numerics; namespace Brutal.JoltApi { /// /// /// C++: /// Jolt/Skeleton/Skeleton.h:17 ///
/// class Skeleton : public RefTarget<Skeleton> ///
///
/// /// /// Resource that contains the joint hierarchy for a skeleton /// /// [InteropHandle] public readonly partial struct Skeleton : IDisposable { public static Skeleton Create() => Jolt.PInvoke.Skeleton_Create(); /// /// /// C++: /// Jolt/Skeleton/Skeleton.h:44 ///
/// int GetJointCount() const ///
///
public int GetJointCount() => Jolt.PInvoke.Skeleton_GetJointCount(this); /// /// /// C++: /// Jolt/Skeleton/Skeleton.h:55 ///
/// void CalculateParentJointIndices() ///
///
/// /// /// Fill in parent joint indices based on name /// /// public void CalculateParentJointIndices() => Jolt.PInvoke.Skeleton_CalculateParentJointIndices(this); /// /// /// C++: /// Jolt/Skeleton/Skeleton.h:59 ///
/// bool AreJointsCorrectlyOrdered() const ///
///
/// /// /// Many of the algorithms that use the Skeleton class require that parent joints are in the mJoints array before their children. /// This function returns true if this is the case, false if not. /// /// public bool AreJointsCorrectlyOrdered() => Jolt.PInvoke.Skeleton_AreJointsCorrectlyOrdered(this); /// /// /// C++: /// Jolt/Skeleton/Skeleton.h:62 ///
/// void SaveBinaryState(StreamOut &inStream) const ///
///
/// /// /// Saves the state of this object in binary form to inStream. /// /// public void SaveBinaryState(StreamOut stream) => Jolt.PInvoke.Skeleton_SaveBinaryState(this, stream); /// /// /// C++: /// Jolt/Skeleton/Skeleton.h:65 ///
/// static SkeletonResult sRestoreFromBinaryState(StreamIn &inStream) ///
///
/// /// /// Restore the state of this object from inStream. /// /// /// Throws InvalidOperationException with Jolt's error message when the operation fails. /// /// public static Skeleton sRestoreFromBinaryState(StreamIn stream) { var _handle = Jolt.PInvoke.Skeleton_sRestoreFromBinaryState(stream); if (_handle.IsNull()) throw new InvalidOperationException(Jolt.GetLastError()); return _handle; } public void AddRef() => Jolt.PInvoke.Skeleton_AddRef(this); public void Release() => Jolt.PInvoke.Skeleton_Release(this); public uint GetRefCount() => Jolt.PInvoke.Skeleton_GetRefCount(this); public void Dispose() { if (IsNull()) return; Release(); } } }