zoukankan      html  css  js  c++  java
  • Multipatch转Geometry转PointCollection转TriangleFan

    众所周知,Multipatch是ArcGIS独创的数据结构,叫“面片”。可以根据点集按照一定的顺序连成。那么反过来我们也可以根据面片生成点集。

                    IGeometryCollection GeoCollection = new MultiPatchClass();
                    IPointCollection TriStripPoints = new TriangleStripClass();
                    object Missing = Type.Missing;
    
                    for (int i = 0; i < division; i++)
                    {
                        VectorCross.Rotate(Angle, VectorPipe);//旋转底面上的向量
                        IPoint PntA = ConstructPnt3D(FromPnt.X + VectorCross.XComponent, FromPnt.Y + VectorCross.YComponent, FromPnt.Z + VectorCross.ZComponent, sr);
                        IPoint PntB = ConstructPnt3D(ToPnt.X + VectorCross.XComponent, ToPnt.Y + VectorCross.YComponent, ToPnt.Z + VectorCross.ZComponent, sr);
                        TriStripPoints.AddPoint(PntA, ref Missing, ref Missing);
                        TriStripPoints.AddPoint(PntB, ref Missing, ref Missing);
                        //MessageBox.Show(PntA.X + "," + PntA.Y + "," + PntA.Z + ";" + PntB.X + "," + PntB.Y + "," + PntB.Z);
                    }
                    TriStripPoints.AddPoint(TriStripPoints.get_Point(0), ref Missing, ref Missing);
                    TriStripPoints.AddPoint(TriStripPoints.get_Point(1), ref Missing, ref Missing);
                    GeoCollection.AddGeometry(TriStripPoints as IGeometry, ref Missing, ref Missing);
                    IGeometry GeoPipe3D = GeoCollection as IGeometry;
                    GeoPipe3D.SpatialReference = sr;
                    return GeoPipe3D;

    巷道+管道-ArcScene

  • 相关阅读:
    Mockito
    输入一个链表,输出该链表中倒数第k个结点。
    序列化
    全排列
    PostgreSQL libpq学习指南二
    PostgreSQL libpq 客户端接口(一)
    PostgreSQL 中的shared buffer
    通过 Unwrapper 解密 DBMS 程序包
    openGuassDB介绍及安装实践
    PostgreSQL中的ACID特性介绍
  • 原文地址:https://www.cnblogs.com/2008nmj/p/14341121.html
Copyright © 2011-2022 走看看