zoukankan      html  css  js  c++  java
  • 利用不同的属性值显示出不同的颜色

    在本节中,注意到三维底图既加入了行政边界的矢量要素图层,也加入了场景要素

    var countries = new FeatureLayer({  //各国矢量边界

      url:"https://services.arcgis.com/P3ePLMYs2RVChkJx/arcgis/rest/services/World_Countries_(Generalized)/FeatureServer",

      renderer:{

        type:"simple",

        symbol:{

          type:"polygon-3d",

          symbolLayers:[{

            type:"fill",

            material:{color:[0,0,0,0]},

            outline:{color:[4,245,248]}

          }]

        }

      }

    });

    var layer = new SceneLayer({

      url:"https://tiles.arcgis.com/tiles/V6ZHFr6zdgNZuVG0/arcgis/rest/services/Airports_PointSceneLayer/SceneServer/layers/0",

      renderer:{

        type:"simple",

        symbol:{

          type:"point-3d",

          symbolLayers:[{

            type:"icon",

            size:1.7

          }]

        },

        visualVariables:[{

          type:"color",

          field:"type_airpport",

          stops:[{

            value:1,

            color:[252,12,245]

          },{

            value:3,

            color:[83,0,244]

          },{

            value:7,

            color:[4,245,248]

          }]

        }]

      }

    })

    var map = new Map({

      layers:[countries,layer]  //哪个图层在第一个,哪一个就覆盖显示

      ground:{

        opacity:0.6,

        surfaceColor:"black"

      }

    });

    var view = new SceneView({

      container:"viewDiv",

      map:map,

      environment:{

        starsEnabled:false,

        atmosphereEnabled:false,

        background:{

          type:"color",

          color:"black"

        }

      }

    })

  • 相关阅读:
    Seafile开源私有云自定义首页Logo图片
    启动seafile报错Error happened during creating seafile admin.
    jupyter的安装和使用(python3版)
    C#学习资料
    服务编排-以docker-swarm为例讲解
    docker swarm架构图
    VMware中安装centos7
    js获取数据:类似xpath
    博客园备份python程序
    解决docker中jenkins运行磁盘满的问题
  • 原文地址:https://www.cnblogs.com/GIS-Yangol/p/10421204.html
Copyright © 2011-2022 走看看