diff options
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Region/Physics/Meshing/Mesh.cs | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/OpenSim/Region/Physics/Meshing/Mesh.cs b/OpenSim/Region/Physics/Meshing/Mesh.cs index 5a565ff..719e364 100644 --- a/OpenSim/Region/Physics/Meshing/Mesh.cs +++ b/OpenSim/Region/Physics/Meshing/Mesh.cs | |||
@@ -296,12 +296,22 @@ namespace OpenSim.Region.Physics.Meshing | |||
296 | primMesh = null; | 296 | primMesh = null; |
297 | } | 297 | } |
298 | 298 | ||
299 | public void Append(Mesh newMesh) | 299 | public void Append(IMesh newMesh) |
300 | { | 300 | { |
301 | foreach (Vertex v in newMesh.vertices) | 301 | Mesh newMesh2; |
302 | if (newMesh is Mesh) | ||
303 | { | ||
304 | newMesh2 = (Mesh)newMesh; | ||
305 | } | ||
306 | else | ||
307 | { | ||
308 | return; | ||
309 | } | ||
310 | |||
311 | foreach (Vertex v in newMesh2.vertices) | ||
302 | vertices.Add(v); | 312 | vertices.Add(v); |
303 | 313 | ||
304 | foreach (Triangle t in newMesh.triangles) | 314 | foreach (Triangle t in newMesh2.triangles) |
305 | Add(t); | 315 | Add(t); |
306 | } | 316 | } |
307 | 317 | ||