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

namespace Ghost.Ufbx;

public unsafe partial struct ufbx_element
{
    /// <summary>
    /// From: <see cref="Api.ufbx_get_prop_element(ufbx_element*, ufbx_prop*, ufbx_element_type)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_element* GetProp(ufbx_prop* prop, ufbx_element_type type)
    {
        return Api.ufbx_get_prop_element(
            (ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this),
            prop,
            type);
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_find_prop_element_len(ufbx_element*, sbyte*, nuint, ufbx_element_type)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_element* FindPropLen(ReadOnlySpan<byte> name, ufbx_element_type type)
    {
        fixed (byte* pname = name)
        {
            return Api.ufbx_find_prop_element_len(
                (ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this),
                (sbyte*)pname,
                (nuint)name.Length,
                type);
        }
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_find_prop_element(ufbx_element*, sbyte*, ufbx_element_type)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_element* FindProp(sbyte* name, ufbx_element_type type)
    {
        return Api.ufbx_find_prop_element(
            (ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this),
            name,
            type);
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_unknown(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_unknown* AsUnknown()
    {
        return Api.ufbx_as_unknown((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_node(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_node* AsNode()
    {
        return Api.ufbx_as_node((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_mesh(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_mesh* AsMesh()
    {
        return Api.ufbx_as_mesh((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_light(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_light* AsLight()
    {
        return Api.ufbx_as_light((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_camera(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_camera* AsCamera()
    {
        return Api.ufbx_as_camera((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_bone(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_bone* AsBone()
    {
        return Api.ufbx_as_bone((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_empty(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_empty* AsEmpty()
    {
        return Api.ufbx_as_empty((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_line_curve(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_line_curve* AsLineCurve()
    {
        return Api.ufbx_as_line_curve((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_nurbs_curve(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_nurbs_curve* AsNurbsCurve()
    {
        return Api.ufbx_as_nurbs_curve((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_nurbs_surface(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_nurbs_surface* AsNurbsSurface()
    {
        return Api.ufbx_as_nurbs_surface((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_nurbs_trim_surface(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_nurbs_trim_surface* AsNurbsTrimSurface()
    {
        return Api.ufbx_as_nurbs_trim_surface((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_nurbs_trim_boundary(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_nurbs_trim_boundary* AsNurbsTrimBoundary()
    {
        return Api.ufbx_as_nurbs_trim_boundary((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_procedural_geometry(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_procedural_geometry* AsProceduralGeometry()
    {
        return Api.ufbx_as_procedural_geometry((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_stereo_camera(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_stereo_camera* AsStereoCamera()
    {
        return Api.ufbx_as_stereo_camera((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_camera_switcher(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_camera_switcher* AsCameraSwitcher()
    {
        return Api.ufbx_as_camera_switcher((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_marker(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_marker* AsMarker()
    {
        return Api.ufbx_as_marker((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_lod_group(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_lod_group* AsLodGroup()
    {
        return Api.ufbx_as_lod_group((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_skin_deformer(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_skin_deformer* AsSkinDeformer()
    {
        return Api.ufbx_as_skin_deformer((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_skin_cluster(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_skin_cluster* AsSkinCluster()
    {
        return Api.ufbx_as_skin_cluster((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_blend_deformer(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_blend_deformer* AsBlendDeformer()
    {
        return Api.ufbx_as_blend_deformer((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_blend_channel(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_blend_channel* AsBlendChannel()
    {
        return Api.ufbx_as_blend_channel((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_blend_shape(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_blend_shape* AsBlendShape()
    {
        return Api.ufbx_as_blend_shape((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_cache_deformer(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_cache_deformer* AsCacheDeformer()
    {
        return Api.ufbx_as_cache_deformer((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_cache_file(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_cache_file* AsCacheFile()
    {
        return Api.ufbx_as_cache_file((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_material(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_material* AsMaterial()
    {
        return Api.ufbx_as_material((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_texture(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_texture* AsTexture()
    {
        return Api.ufbx_as_texture((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_video(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_video* AsVideo()
    {
        return Api.ufbx_as_video((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_shader(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_shader* AsShader()
    {
        return Api.ufbx_as_shader((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_shader_binding(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_shader_binding* AsShaderBinding()
    {
        return Api.ufbx_as_shader_binding((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_anim_stack(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_anim_stack* AsAnimStack()
    {
        return Api.ufbx_as_anim_stack((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_anim_layer(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_anim_layer* AsAnimLayer()
    {
        return Api.ufbx_as_anim_layer((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_anim_value(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_anim_value* AsAnimValue()
    {
        return Api.ufbx_as_anim_value((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_anim_curve(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_anim_curve* AsAnimCurve()
    {
        return Api.ufbx_as_anim_curve((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_display_layer(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_display_layer* AsDisplayLayer()
    {
        return Api.ufbx_as_display_layer((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_selection_set(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_selection_set* AsSelectionSet()
    {
        return Api.ufbx_as_selection_set((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_selection_node(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_selection_node* AsSelectionNode()
    {
        return Api.ufbx_as_selection_node((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_character(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_character* AsCharacter()
    {
        return Api.ufbx_as_character((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_constraint(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_constraint* AsConstraint()
    {
        return Api.ufbx_as_constraint((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_audio_layer(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_audio_layer* AsAudioLayer()
    {
        return Api.ufbx_as_audio_layer((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_audio_clip(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_audio_clip* AsAudioClip()
    {
        return Api.ufbx_as_audio_clip((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_pose(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_pose* AsPose()
    {
        return Api.ufbx_as_pose((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }

    /// <summary>
    /// From: <see cref="Api.ufbx_as_metadata_object(ufbx_element*)" />
    /// </summary>
    [System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.AggressiveInlining)]
    public ufbx_metadata_object* AsMetadataObject()
    {
        return Api.ufbx_as_metadata_object((ufbx_element*)System.Runtime.CompilerServices.Unsafe.AsPointer(ref this));
    }
}
