Potencially fix nan's on octahedral tangents in RenderingServer

This commit is contained in:
nklbdev 2023-07-01 18:46:52 +05:00
parent c022f52f11
commit 1d16704faf
1 changed files with 3 additions and 3 deletions

View File

@ -647,11 +647,11 @@ SpriteBase3D::SpriteBase3D() {
// Create basic mesh and store format information.
for (int i = 0; i < 4; i++) {
mesh_normals.write[i] = Vector3(0.0, 0.0, 0.0);
mesh_tangents.write[i * 4 + 0] = 0.0;
mesh_normals.write[i] = Vector3(0.0, 0.0, 1.0);
mesh_tangents.write[i * 4 + 0] = 1.0;
mesh_tangents.write[i * 4 + 1] = 0.0;
mesh_tangents.write[i * 4 + 2] = 0.0;
mesh_tangents.write[i * 4 + 3] = 0.0;
mesh_tangents.write[i * 4 + 3] = 1.0;
mesh_colors.write[i] = Color(1.0, 1.0, 1.0, 1.0);
mesh_uvs.write[i] = Vector2(0.0, 0.0);
mesh_vertices.write[i] = Vector3(0.0, 0.0, 0.0);