summaryrefslogtreecommitdiffstats
path: root/scene/resources/mesh_data_tool.cpp
diff options
context:
space:
mode:
authorfjordyo <fjordyo0707@gmail.com>2019-08-24 10:27:22 +0800
committerfjordyo <fjordyo0707@gmail.com>2019-08-24 10:27:22 +0800
commit4c28053eade1d5aa93edaea89218718a196f5380 (patch)
tree0881b5aacb10531283c7b33b6960ef84b979ae46 /scene/resources/mesh_data_tool.cpp
parent791d7f78b52f5b828aa5541897e12c6a1861ef6f (diff)
downloadredot-engine-4c28053eade1d5aa93edaea89218718a196f5380.tar.gz
Fix the edges of the mesh vertex
Diffstat (limited to 'scene/resources/mesh_data_tool.cpp')
-rw-r--r--scene/resources/mesh_data_tool.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/scene/resources/mesh_data_tool.cpp b/scene/resources/mesh_data_tool.cpp
index 7cd765fb5d..0c39c3cbb1 100644
--- a/scene/resources/mesh_data_tool.cpp
+++ b/scene/resources/mesh_data_tool.cpp
@@ -165,11 +165,12 @@ Error MeshDataTool::create_from_surface(const Ref<ArrayMesh> &p_mesh, int p_surf
e.vertex[0] = edge.x;
e.vertex[1] = edge.y;
edges.push_back(e);
+ v[j]->edges.push_back(face.edges[j]);
+ v[(j + 1) % 3]->edges.push_back(face.edges[j]);
}
edges.write[face.edges[j]].faces.push_back(fidx);
v[j]->faces.push_back(fidx);
- v[j]->edges.push_back(face.edges[j]);
}
faces.push_back(face);