// <auto-generated>
// This file is generated by Ghost.NativeWrapperGen. Do not edit manually.
// </auto-generated>

namespace Ghost.Ufbx;

public unsafe partial struct ufbx_anim : System.IDisposable
{
    /// <summary>
    /// From: <see cref="Api.ufbx_evaluate_prop_len(ufbx_anim*, ufbx_element*, sbyte*, nuint, double)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_prop EvaluatePropLen(ufbx_element* element, ReadOnlySpan<byte> name, double time)
    {
        fixed (byte* pname = name)
        {
            return Api.ufbx_evaluate_prop_len(
                (ufbx_anim*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this),
                element,
                (sbyte*)pname,
                (nuint)name.Length,
                time);
        }
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_evaluate_prop(ufbx_anim*, ufbx_element*, sbyte*, double)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_prop EvaluateProp(ufbx_element* element, sbyte* name, double time)
    {
        return Api.ufbx_evaluate_prop(
            (ufbx_anim*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this),
            element,
            name,
            time);
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_evaluate_prop_flags_len(ufbx_anim*, ufbx_element*, sbyte*, nuint, double, uint)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_prop EvaluatePropFlagsLen(ufbx_element* element, ReadOnlySpan<byte> name, double time, uint flags)
    {
        fixed (byte* pname = name)
        {
            return Api.ufbx_evaluate_prop_flags_len(
                (ufbx_anim*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this),
                element,
                (sbyte*)pname,
                (nuint)name.Length,
                time,
                flags);
        }
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_evaluate_prop_flags(ufbx_anim*, ufbx_element*, sbyte*, double, uint)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_prop EvaluatePropFlags(ufbx_element* element, sbyte* name, double time, uint flags)
    {
        return Api.ufbx_evaluate_prop_flags(
            (ufbx_anim*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this),
            element,
            name,
            time,
            flags);
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_evaluate_props(ufbx_anim*, ufbx_element*, double, ufbx_prop*, nuint)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_props EvaluateProps(ufbx_element* element, double time, ufbx_prop* buffer, nuint buffer_size)
    {
        return Api.ufbx_evaluate_props(
            (ufbx_anim*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this),
            element,
            time,
            buffer,
            buffer_size);
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_evaluate_props_flags(ufbx_anim*, ufbx_element*, double, ufbx_prop*, nuint, uint)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_props EvaluatePropsFlags(ufbx_element* element, double time, ufbx_prop* buffer, nuint buffer_size, uint flags)
    {
        return Api.ufbx_evaluate_props_flags(
            (ufbx_anim*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this),
            element,
            time,
            buffer,
            buffer_size,
            flags);
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_evaluate_transform(ufbx_anim*, ufbx_node*, double)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_transform EvaluateTransform(ufbx_node* node, double time)
    {
        return Api.ufbx_evaluate_transform(
            (ufbx_anim*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this),
            node,
            time);
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_evaluate_transform_flags(ufbx_anim*, ufbx_node*, double, uint)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_transform EvaluateTransformFlags(ufbx_node* node, double time, uint flags)
    {
        return Api.ufbx_evaluate_transform_flags(
            (ufbx_anim*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this),
            node,
            time,
            flags);
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_evaluate_blend_weight(ufbx_anim*, ufbx_blend_channel*, double)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public float EvaluateBlendWeight(ufbx_blend_channel* channel, double time)
    {
        return Api.ufbx_evaluate_blend_weight(
            (ufbx_anim*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this),
            channel,
            time);
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_evaluate_blend_weight_flags(ufbx_anim*, ufbx_blend_channel*, double, uint)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public float EvaluateBlendWeightFlags(ufbx_blend_channel* channel, double time, uint flags)
    {
        return Api.ufbx_evaluate_blend_weight_flags(
            (ufbx_anim*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this),
            channel,
            time,
            flags);
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_free_anim(ufbx_anim*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public void Dispose()
    {
        Api.ufbx_free_anim((ufbx_anim*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_retain_anim(ufbx_anim*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public void Retain()
    {
        Api.ufbx_retain_anim((ufbx_anim*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }
}
