ArcGIS Desktop

  • ArcGIS Pro
  • ArcMap

  • My Profile
  • 帮助
  • Sign Out
ArcGIS Desktop

ArcGIS Online

专为贵组织打造的制图平台

ArcGIS Desktop

全面的专业性 GIS

ArcGIS Enterprise

面向企业的 GIS

ArcGIS for Developers

用于构建位置感知应用程序的工具

ArcGIS Solutions

适用于行业的免费模板地图和应用程序

ArcGIS Marketplace

获取适用于组织的应用程序和数据

  • 文档
  • 支持
Esri
  • 登录
user
  • 我的个人资料
  • 登出

ArcMap

  • 主页
  • 入门
  • 地图
  • 分析
  • 管理数据
  • 工具
  • 扩展模块

生成细分曲面

  • 描述
  • 使用
  • 语法
  • 代码示例
  • 环境
  • 许可信息

描述

生成完全覆盖给定范围的正多边形细分面格网的面要素类。该细分曲面可以是三角形、正方形或六边形。

使用

  • 要确保整个输入范围被细分面格网覆盖,可有意使输出要素的范围超出输入范围。这样做的原因是细分面格网的边缘不总是直线,且如果用输入范围限制格网,可能会出现间隙。

  • 输出要素中包含 GRID_ID 字段。GRID_ID 字段可为输出要素类中的每个要素提供唯一的 ID。ID 的格式为 A-1、A-2、B-1、B-2 等等。这便于利用按属性选择图层工具中的查询选择行和列。例如,使用 GRID_ID like 'A-%' 选择列 A 中的所有要素,或使用 GRID_ID like '%-1' 选择行 1 中的所有要素。

  • 要创建不包括细分曲面要素的格网(不与另一数据集中的要素相交),请使用按位置选择图层工具选择包含源要素的输出面,并使用复制要素工具生成所选输出要素的永久副本,并将其复制到新的要素类。

语法

GenerateTessellation(Output_Feature_Class, Extent, {Shape_Type}, {Size}, {Spatial_Reference})
参数说明数据类型
Output_Feature_Class

包含细分面格网的输出数据集的路径和名称。

Feature Class
Extent

细分曲面将覆盖的范围。该范围可以是当前可见区域、数据集的范围或手动输入值。

Extent
Shape_Type
(可选)

细分曲面的形状类型。

  • HEXAGON —边长相等的正六边形。
  • SQUARE —边长相等的正四边形。
  • TRIANGLE —正三角形。目前仅支持等边三角形。
String
Size
(可选)

构成细分曲面的每个形状的大小。

Areal Unit
Spatial_Reference
(可选)

输出数据集投影到的空间参考。如果未提供空间参考,则输出将被投影到输入范围的空间参考中。如果空间参考也不存在,则输出将被投影到 GCS_WGS_1984。

Spatial Reference

代码示例

GenerateTessellation 示例 1(Python 窗口)

以下 Python 窗口脚本演示了如何在即时模式下使用 GenerateTesselation 工具。

import arcpy
tessellation_extent = arcpy.Extent(0.0, 0.0, 10.0, 10.0)
spatial_ref = arcpy.SpatialReference(4326)
arcpy.GenerateTessellation_management(r"C:\data\project.gdb\hex_tessellation", tessellation_extent, "HEXAGON", "100 SquareMiles", spatial_ref)
GenerateTessellation 示例 2(独立脚本)

以下独立 Python 脚本可演示如何以编程方式从要素类提取范围,以及如何使用该范围填充 GenerateTessellation 工具的参数。

# Name: GenerateDynamicTessellation.py
# Purpose: Generate a grid of squares over the envelope of a provided feature class.
# Import modules
import arcpy 
# Set paths of features
my_feature = r"C:\data\project.gdb\myfeature"
output_feature = r"C:\data\project.gdb\sqtessellation"
# Describe the input feature and extract the extent
description = arcpy.Describe(my_feature)
extent = description.extent
# Find the width, height and linear unit used by the input feature class' extent
# Divide the width and height value by three
# Multiply the divided values together and specify an area unit from the linear unit
# Should result in a 4x4 grid covering the extent. (Not 3x3 since the squares hang over the extent.)
w = extent.width
h = extent.height
u = extent.spatialReference.linearUnitName
area = "{size} Square{unit}s".format(size=w/3 * h/3, unit=u)
# Use the extent's spatial reference to project the output
spatial_ref = extent.spatialReference
arcpy.GenerateTessellation_management(output_feature, extent, "SQUARE", area, spatial_ref)

环境

  • 默认输出 Z 值
  • M 分辨率
  • M 容差
  • 输出 M 值域
  • 输出 XY 值域
  • 输出 Z 值域
  • 输出坐标系
  • 当前工作空间
  • 地理变换
  • 临时工作空间
  • 输出包含 M 值
  • 输出包含 Z 值
  • XY 分辨率
  • XY 容差
  • Z 分辨率
  • Z 容差
  • 随机数生成器
  • 范围

许可信息

  • Basic: 是
  • Standard: 是
  • Advanced: 是

相关主题

  • 采样工具集概述

ArcGIS Desktop

  • 主页
  • 文档
  • 支持

ArcGIS 平台

  • ArcGIS Online
  • ArcGIS Desktop
  • ArcGIS Enterprise
  • ArcGIS for Developers
  • ArcGIS Solutions
  • ArcGIS Marketplace

关于 Esri

  • 关于我们
  • 招贤纳士
  • Esri 博客
  • 用户大会
  • 开发者峰会
Esri
分享您的想法。
Copyright © 2019 Esri. | 隐私政策 | 法律声明