Пример #1
0
        private void ribbonButton13_Click(object sender, EventArgs e)
        {
            m_earthRoot.removeChildren();
            imageSurfaceLayerA       = null;
            imageSurfaceLayerB       = null;
            imageSurfaceLayerC       = null;
            imageSurfaceLayerDebug   = null;
            imageSurfaceLayerNoise   = null;
            imageSurfaceLayerAGGLite = null;
            imageSurfaceLayerMBTiles = null;
            imageSurfaceLayerArcGIS  = null;

            vectorSurfaceLayerD = null;

            groupOfEFG          = null;
            vectorSurfaceLayerE = null;
            vectorSurfaceLayerF = null;
            vectorSurfaceLayerG = null;

            tmsImageSurfaceLayerH     = null;
            tmsElevationSurfaceLayerI = null;

            elevSurfaceLayerJ     = null;
            elevSurfaceLayerNoise = null;
        }
Пример #2
0
 private void ribbonButton15_Click(object sender, EventArgs e)
 {
     if (imageSurfaceLayerA != null)
     {
         m_earthRoot.removeChild(imageSurfaceLayerA);
         imageSurfaceLayerA = null;
     }
 }
Пример #3
0
 private void addImageSurfaceLayerDebug()
 {
     if (imageSurfaceLayerDebug == null)
     {
         imageSurfaceLayerDebug            = new ImageSurfaceLayer();
         imageSurfaceLayerDebug.tileSource = new TileSourceDebug();
         m_earthRoot.addChild(imageSurfaceLayerDebug);
     }
 }
Пример #4
0
 private void addImageLayerC()
 {
     if (imageSurfaceLayerC == null)
     {
         imageSurfaceLayerC            = new ImageSurfaceLayer();
         tileSourceGDAL.url            = "E:\\OpenSceneGraph\\data\\download\\dnb_land_ocean_ice.2012.54000x27000_geo_transform.tif";
         imageSurfaceLayerC.tileSource = tileSourceGDAL;
         m_earthRoot.addChild(imageSurfaceLayerC);
     }
 }
Пример #5
0
 private void addTMSImageSurfaceLayerH()
 {
     if (tmsImageSurfaceLayerH == null)
     {
         tmsImageSurfaceLayerH            = new ImageSurfaceLayer();
         tileSourceTMS.url                = "E:\\OpenSceneGraph\\data\\download\\beijing_img\\tms.xml";
         tmsImageSurfaceLayerH.tileSource = tileSourceTMS;
         m_earthRoot.addChild(tmsImageSurfaceLayerH);
     }
 }
Пример #6
0
 private void addImageLayerB()
 {
     if (imageSurfaceLayerB == null)
     {
         imageSurfaceLayerB            = new ImageSurfaceLayer();
         tileSourceGDAL.url            = "E:\\OpenSceneGraph\\data\\download\\world.topo.bathy\\world.topo.bathy.200406.3x86400x43200_translate_tiled.tif";
         imageSurfaceLayerB.tileSource = tileSourceGDAL;
         m_earthRoot.addChild(imageSurfaceLayerB);
     }
 }
Пример #7
0
 private void addImageSurfaceLayerArcGIS()
 {
     if (imageSurfaceLayerArcGIS == null)
     {
         TileSourceArcGIS tileSourceArcGIS = new TileSourceArcGIS();
         tileSourceArcGIS.url               = "http://services.arcgisonline.com/ArcGIS/rest/services/World_Topo_Map/MapServer";
         imageSurfaceLayerArcGIS            = new ImageSurfaceLayer();
         imageSurfaceLayerArcGIS.tileSource = tileSourceArcGIS;
         m_earthRoot.addChild(imageSurfaceLayerArcGIS);
     }
 }
Пример #8
0
        private void addImageSurfaceLayerNoise()
        {
            if (imageSurfaceLayerNoise == null)
            {
                TileSourceNoise noise = new TileSourceNoise();
                noise.resolution = 3185500;
                noise.octaves    = 12;

                imageSurfaceLayerNoise            = new ImageSurfaceLayer();
                imageSurfaceLayerNoise.tileSource = noise;
                m_earthRoot.addChild(imageSurfaceLayerNoise);
            }
        }
Пример #9
0
        private void addImageSurfaceLayerAGGLite()
        {
            if (imageSurfaceLayerAGGLite == null)
            {
                TileSourceAGGLite aggLite = new TileSourceAGGLite();
                FeatureSourceOGR  ogr     = new FeatureSourceOGR();
                ogr.url = "E:\\OpenSceneGraph\\data\\world.shp";
                aggLite.featureSource = ogr;

                imageSurfaceLayerAGGLite            = new ImageSurfaceLayer();
                imageSurfaceLayerAGGLite.tileSource = aggLite;
                m_earthRoot.addChild(imageSurfaceLayerAGGLite);
            }
        }
Пример #10
0
        private void ribbonButton43_Click(object sender, EventArgs e)
        {
            TileSourceAGGLite aggLite = new TileSourceAGGLite();
            FeatureSourceOGR  ogr     = new FeatureSourceOGR();

            ogr.url = "E:\\OpenSceneGraph\\data\\zhengzhou\\440100郑州冬小麦prj.shp";
            //ogr.url = "E:\\OpenSceneGraph\\data\\henan\\dxmall\\河南省冬小麦.shp";

            aggLite.featureSource = ogr;

            ImageSurfaceLayer imageSurfaceLayer = new ImageSurfaceLayer();

            imageSurfaceLayer.tileSource = aggLite;
            m_earthRoot.addChild(imageSurfaceLayer);
        }
Пример #11
0
        private void ribbonButton9_Click(object sender, EventArgs e)
        {
            uint pos = 2;

            //先把引用了pos位置的物体的引用设为null
            IEarthObject earthObject = m_earthRoot.getChild(pos);

            if (earthObject == null)
            {
                return;
            }

            if (earthObject.equal(imageSurfaceLayerA))
            {
                imageSurfaceLayerA = null;
            }
            else if (earthObject.equal(imageSurfaceLayerB))
            {
                imageSurfaceLayerB = null;
            }
            else if (earthObject.equal(imageSurfaceLayerC))
            {
                imageSurfaceLayerC = null;
            }
            else if (earthObject.equal(vectorSurfaceLayerD))
            {
                vectorSurfaceLayerD = null;
            }
            else if (earthObject.equal(groupOfEFG))
            {
                groupOfEFG          = null;
                vectorSurfaceLayerE = null;
                vectorSurfaceLayerF = null;
                vectorSurfaceLayerG = null;
            }

            m_earthRoot.removeChildByPos(pos);
        }
Пример #12
0
 private void addImageLayerC()
 {
     if (imageSurfaceLayerC == null)
     {
         imageSurfaceLayerC = new ImageSurfaceLayer();
         tileSourceGDAL.url = "E:\\OpenSceneGraph\\data\\download\\dnb_land_ocean_ice.2012.54000x27000_geo_transform.tif";
         imageSurfaceLayerC.tileSource = tileSourceGDAL;
         m_earthRoot.addChild(imageSurfaceLayerC);
     }
 }
Пример #13
0
 private void addImageSurfaceLayerArcGIS()
 {
     if (imageSurfaceLayerArcGIS == null)
     {
         TileSourceArcGIS tileSourceArcGIS = new TileSourceArcGIS();
         tileSourceArcGIS.url = "http://services.arcgisonline.com/ArcGIS/rest/services/World_Topo_Map/MapServer";
         imageSurfaceLayerArcGIS = new ImageSurfaceLayer();
         imageSurfaceLayerArcGIS.tileSource = tileSourceArcGIS;
         m_earthRoot.addChild( imageSurfaceLayerArcGIS );
     }
 }
Пример #14
0
 private void addImageSurfaceLayerDebug()
 {
     if (imageSurfaceLayerDebug == null)
     {
         imageSurfaceLayerDebug = new ImageSurfaceLayer();
         imageSurfaceLayerDebug.tileSource = new TileSourceDebug();
         m_earthRoot.addChild( imageSurfaceLayerDebug );
     }
 }
Пример #15
0
        private void addImageSurfaceLayerNoise()
        {
            if( imageSurfaceLayerNoise == null )
            {
                TileSourceNoise noise = new TileSourceNoise();
                noise.resolution = 3185500;
                noise.octaves = 12;

                imageSurfaceLayerNoise = new ImageSurfaceLayer();
                imageSurfaceLayerNoise.tileSource = noise;
                m_earthRoot.addChild( imageSurfaceLayerNoise );
            }
        }
Пример #16
0
 private void addImgLayerA()
 {
     if ( imageSurfaceLayerA == null )
     {
         imageSurfaceLayerA = new ImageSurfaceLayer();
         //tileSourceGDAL.url = "E:\\OpenSceneGraph\\data\\download\\world.topo.bathy\\world.topo.bathy.200406.3x86400x43200_translate_tiled.tif";
         tileSourceGDAL.url = "E:\\OpenSceneGraph\\data\\world.tif";
         imageSurfaceLayerA.tileSource = tileSourceGDAL;
         m_earthRoot.addChild( imageSurfaceLayerA );
     }
 }
Пример #17
0
 private void addTMSImageSurfaceLayerH()
 {
     if ( tmsImageSurfaceLayerH == null )
     {
         tmsImageSurfaceLayerH = new ImageSurfaceLayer();
         tileSourceTMS.url = "E:\\OpenSceneGraph\\data\\download\\beijing_img\\tms.xml";
         tmsImageSurfaceLayerH.tileSource = tileSourceTMS;
         m_earthRoot.addChild( tmsImageSurfaceLayerH );
     }
 }
Пример #18
0
        private void ribbonButton13_Click(object sender, EventArgs e)
        {
            m_earthRoot.removeChildren();
            imageSurfaceLayerA = null;
            imageSurfaceLayerB = null;
            imageSurfaceLayerC = null;
            imageSurfaceLayerDebug = null;
            imageSurfaceLayerNoise = null;
            imageSurfaceLayerAGGLite = null;
            imageSurfaceLayerMBTiles = null;
            imageSurfaceLayerArcGIS = null;

            vectorSurfaceLayerD = null;

            groupOfEFG = null;
            vectorSurfaceLayerE = null;
            vectorSurfaceLayerF = null;
            vectorSurfaceLayerG = null;

            tmsImageSurfaceLayerH = null;
            tmsElevationSurfaceLayerI = null;

            elevSurfaceLayerJ = null;
            elevSurfaceLayerNoise = null;
        }
Пример #19
0
 private void ribbonButton15_Click(object sender, EventArgs e)
 {
     if (imageSurfaceLayerA != null)
     {
         m_earthRoot.removeChild(imageSurfaceLayerA);
         imageSurfaceLayerA = null;
     }
 }
Пример #20
0
        private void ribbonButton43_Click(object sender, EventArgs e)
        {
            TileSourceAGGLite aggLite = new TileSourceAGGLite();
            FeatureSourceOGR ogr = new FeatureSourceOGR();
            ogr.url = "E:\\OpenSceneGraph\\data\\zhengzhou\\440100郑州冬小麦prj.shp";
            //ogr.url = "E:\\OpenSceneGraph\\data\\henan\\dxmall\\河南省冬小麦.shp";

            aggLite.featureSource = ogr;

            ImageSurfaceLayer imageSurfaceLayer = new ImageSurfaceLayer();
            imageSurfaceLayer.tileSource = aggLite;
            m_earthRoot.addChild(imageSurfaceLayer);
        }
Пример #21
0
        private void addImageSurfaceLayerAGGLite()
        {
            if (imageSurfaceLayerAGGLite == null)
            {
                TileSourceAGGLite aggLite = new TileSourceAGGLite();
                FeatureSourceOGR ogr = new FeatureSourceOGR();
                ogr.url = "E:\\OpenSceneGraph\\data\\world.shp";
                aggLite.featureSource = ogr;

                imageSurfaceLayerAGGLite = new ImageSurfaceLayer();
                imageSurfaceLayerAGGLite.tileSource = aggLite;
                m_earthRoot.addChild( imageSurfaceLayerAGGLite );
            }
        }
Пример #22
0
        private void ribbonButton9_Click(object sender, EventArgs e)
        {
            uint pos = 2;

            //先把引用了pos位置的物体的引用设为null
            IEarthObject earthObject = m_earthRoot.getChild(pos);
            if (earthObject == null)
            {
                return;
            }

            if (earthObject.equal(imageSurfaceLayerA))
            {
                imageSurfaceLayerA = null;
            }else if (earthObject.equal(imageSurfaceLayerB))
            {
                imageSurfaceLayerB = null;
            }else if (earthObject.equal(imageSurfaceLayerC))
            {
                imageSurfaceLayerC = null;
            }else if (earthObject.equal(vectorSurfaceLayerD))
            {
                vectorSurfaceLayerD = null;
            }else if (earthObject.equal(groupOfEFG))
            {
                groupOfEFG = null;
                vectorSurfaceLayerE = null;
                vectorSurfaceLayerF = null;
                vectorSurfaceLayerG = null;
            }

            m_earthRoot.removeChildByPos(pos);
        }