From 0d282215bc1aa922b6aebd19682eb1e60e30d455 Mon Sep 17 00:00:00 2001 From: Mario Zechner Date: Wed, 6 Dec 2023 17:16:47 +0100 Subject: [PATCH] [godot] Fix compilation error with 4.2-stable --- spine-godot/spine_godot/SpineSprite.cpp | 2 +- spine-godot/spine_godot/SpineSprite.h | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/spine-godot/spine_godot/SpineSprite.cpp b/spine-godot/spine_godot/SpineSprite.cpp index c96caaf5d..76866f63c 100644 --- a/spine-godot/spine_godot/SpineSprite.cpp +++ b/spine-godot/spine_godot/SpineSprite.cpp @@ -146,7 +146,7 @@ void SpineMesh2D::update_mesh(const Vector &vertices, uint32_t skin_stride; RS::get_singleton()->mesh_create_surface_data_from_arrays(&surface, (RS::PrimitiveType) Mesh::PRIMITIVE_TRIANGLES, arrays, TypedArray(), Dictionary(), Mesh::ArrayFormat::ARRAY_FLAG_USE_DYNAMIC_UPDATE); RS::get_singleton()->mesh_add_surface(mesh, surface); - RS::get_singleton()->mesh_surface_make_offsets_from_format(surface.format, surface.vertex_count, surface.index_count, surface_offsets, vertex_stride, attribute_stride, skin_stride); + RS::get_singleton()->mesh_surface_make_offsets_from_format(surface.format, surface.vertex_count, surface.index_count, surface_offsets, vertex_stride, normal_tangent_stride, attribute_stride, skin_stride); num_vertices = vertices.size(); num_indices = indices.size(); vertex_buffer = surface.vertex_data; diff --git a/spine-godot/spine_godot/SpineSprite.h b/spine-godot/spine_godot/SpineSprite.h index b0668b82d..a146435bf 100644 --- a/spine-godot/spine_godot/SpineSprite.h +++ b/spine-godot/spine_godot/SpineSprite.h @@ -66,6 +66,7 @@ protected: PackedByteArray vertex_buffer; PackedByteArray attribute_buffer; uint32_t vertex_stride; + uint32_t normal_tangent_stride; uint32_t attribute_stride; #else RID mesh;