如何连接TriangleIndices(又称Triangles)?

时间:2019-03-28 08:49:43

标签: wpf xaml 3d vertex vertices

情况

我在这里为我的“ 3d网格”保留了代码的宁静

  <MeshGeometry3D 
       Positions="0 0 0
                  0 1 0  
                  1 0 0  
                  1 1 0"
       TriangleIndices="0 2 1
                        2 3 1" >
  </MeshGeometry3D>

问题/问题

为什么我不能使用其他顶点来创建三角形 =>我的意思是每当我尝试写{0,2,1,2,3,1}的{0,1,2,2,3,1}时,我看不到第一个三角形。

编辑

这是我的示例图片。 (如果您想了解这种情况,可能会有所帮助)

示例1:{0,2,1,2,3,1}

enter image description here

示例2:{0,1,2,2,3,1}

enter image description here

1 个答案:

答案 0 :(得分:0)

三角形定义不能相交。为了在示例2中有效,第二个trianable应该为2,3,0