命名空间:
SuperMap.Realspace
程序集: SuperMap.Realspace (in SuperMap.Realspace)
版本: dll
程序集: SuperMap.Realspace (in SuperMap.Realspace)
版本: dll
语法
C# |
---|
public class Theme3DRangeItem |
示例
以下代码示范了如何通过三维分段专题图子项来制作三维分段专题图。
下面函数中操作的矢量数据集为安装目录\SampleData\World\下的 world.udb 数据源中的名为 World 的面数据集。
CopyC#
public void TestTheme3DRangeItem(DatasetVector targetDataset, Scene sceneObject) { //进行三维地图场景的设置 sceneObject.Atmosphere.IsVisible = true; //构建三维分段专题图子项,并添加到三维分段专题图中 GeoStyle3D itemStyle1 = new GeoStyle3D(); itemStyle1.FillForeColor = Color.FromArgb(255, 190, 189); Theme3DRangeItem theme3DRangeItem1 = new Theme3DRangeItem(100000000, 120000000, itemStyle1, "大于一亿"); GeoStyle3D itemStyle2 = new GeoStyle3D(); itemStyle2.FillForeColor = Color.FromArgb(255, 235, 189); Theme3DRangeItem theme3DRangeItem2 = new Theme3DRangeItem(10000000, 100000000, itemStyle2, "大于一千万"); GeoStyle3D itemStyle3 = new GeoStyle3D(); itemStyle3.FillForeColor = Color.FromArgb(214, 255, 115); Theme3DRangeItem theme3DRangeItem3 = new Theme3DRangeItem(1000000, 10000000, itemStyle3, "大于一百万"); GeoStyle3D itemStyle4 = new GeoStyle3D(); itemStyle4.FillForeColor = Color.FromArgb(214, 255, 189); Theme3DRangeItem theme3DRangeItem4 = new Theme3DRangeItem(0, 1000000, itemStyle4, "小于一百万"); Theme3DRange theme3DRange = new Theme3DRange(); theme3DRange.AddToHead(theme3DRangeItem1); theme3DRange.AddToHead(theme3DRangeItem2); theme3DRange.AddToHead(theme3DRangeItem3); theme3DRange.AddToHead(theme3DRangeItem4); theme3DRange.RangeExpression = "Pop_1994"; //将三维分段专题图应用到数据中,并显示在三维场景中 Layer3DDataset layer3DDatasetRange = sceneObject.Layers.Add(targetDataset, theme3DRange, true); layer3DDatasetRange.UpdateData(); sceneObject.Refresh(); }
继承层次
System..::.Object
SuperMap.Realspace..::.Theme3DRangeItem
SuperMap.Realspace..::.Theme3DRangeItem