English中文

WebMercatorTilingScheme

new Cesium.WebMercatorTilingScheme(options)

参考几何图形的切片方案 A tiling scheme for geometry referenced to a WebMercatorProjection,每股收益:3857。这是 Google 地图、Microsoft Bing 地图和大多数 ESRI ArcGIS Online 使用的切片方案。 , EPSG:3857. This is the tiling scheme used by Google Maps, Microsoft Bing Maps, and most of ESRI ArcGIS Online.
名称 Name 类型 Type 说明 Description
options object 可选 optional 具有以下属性的对象: Object with the following properties:
名称 Name 类型 Type 默认值 Default 说明 Description
ellipsoid Ellipsoid Ellipsoid.default 可选 optional 其表面正在平铺的椭球体。默认为默认椭球体。 The ellipsoid whose surface is being tiled. Defaults to the default ellipsoid.
numberOfLevelZeroTilesX number 1 可选 optional 图块树的第 0 层 X 方向上的图块数量。 The number of tiles in the X direction at level zero of the tile tree.
numberOfLevelZeroTilesY number 1 可选 optional 瓦片树的第 0 层沿 Y 方向的瓦片数量。 The number of tiles in the Y direction at level zero of the tile tree.
rectangleSouthwestInMeters Cartesian2 可选 optional 切片方案覆盖的矩形的西南角(以米为单位)。如果不指定该参数或矩形NortheastInMeters,则在经度方向上覆盖整个地球,在纬度方向上覆盖等距离,形成正方形投影。 The southwest corner of the rectangle covered by the tiling scheme, in meters. If this parameter or rectangleNortheastInMeters is not specified, the entire globe is covered in the longitude direction and an equal distance is covered in the latitude direction, resulting in a square projection.
rectangleNortheastInMeters Cartesian2 可选 optional 切片方案覆盖的矩形的东北角(以米为单位)。如果未指定此参数或矩形SouthwestInMeters,则在经度方向上覆盖整个地球,并在纬度方向上覆盖相等的距离,从而形成方形投影。 The northeast corner of the rectangle covered by the tiling scheme, in meters. If this parameter or rectangleSouthwestInMeters is not specified, the entire globe is covered in the longitude direction and an equal distance is covered in the latitude direction, resulting in a square projection.

成员 Members

获取按此切片方案切片的椭球体。 Gets the ellipsoid that is tiled by this tiling scheme.
获取此切片方案使用的地图投影。 Gets the map projection used by this tiling scheme.
获取此切片方案覆盖的矩形(以弧度为单位)。 Gets the rectangle, in radians, covered by this tiling scheme.

方法 Methods

getNumberOfXTilesAtLevel(level)number

获取指定细节级别 X 方向上的图块总数。 Gets the total number of tiles in the X direction at a specified level-of-detail.
名称 Name 类型 Type 说明 Description
level number 详细程度。 The level-of-detail.
返回: Returns:
给定级别 X 方向上的图块数量。 The number of tiles in the X direction at the given level.

getNumberOfYTilesAtLevel(level)number

获取指定细节级别的 Y 方向图块总数。 Gets the total number of tiles in the Y direction at a specified level-of-detail.
名称 Name 类型 Type 说明 Description
level number 详细程度。 The level-of-detail.
返回: Returns:
给定级别 Y 方向上的图块数量。 The number of tiles in the Y direction at the given level.

positionToTileXY(position, level, result)Cartesian2

计算包含给定制图位置的图块的图块 x、y 坐标。 Calculates the tile x, y coordinates of the tile containing a given cartographic position.
名称 Name 类型 Type 说明 Description
position Cartographic 位置。 The position.
level number 瓷砖的细节层次。零是最不详细的。 The tile level-of-detail. Zero is the least detailed.
result Cartesian2 可选 optional 将结果复制到的实例,如果应创建新实例,则为未定义。 The instance to which to copy the result, or undefined if a new instance should be created.
返回: Returns:
指定的“结果”,或者如果“结果”未定义,则包含图块 x、y 坐标的新对象。 The specified 'result', or a new object containing the tile x, y coordinates if 'result' is undefined.

rectangleToNativeRectangle(rectangle, result)Rectangle

将以大地弧度指定的矩形转换为此切片方案的本地坐标系。 Transforms a rectangle specified in geodetic radians to the native coordinate system of this tiling scheme.
名称 Name 类型 Type 说明 Description
rectangle Rectangle 要变换的矩形。 The rectangle to transform.
result Rectangle 可选 optional 将结果复制到的实例,如果应创建新实例,则为未定义。 The instance to which to copy the result, or undefined if a new instance should be created.
返回: Returns:
指定的“结果”,或者如果“结果”未定义,则包含本机矩形的新对象。 The specified 'result', or a new object containing the native rectangle if 'result' is undefined.

tileXYToNativeRectangle(x, y, level, result)Rectangle

将切片 x、y 坐标和级别转换为以切片方案的本机坐标表示的矩形。 Converts tile x, y coordinates and level to a rectangle expressed in the native coordinates of the tiling scheme.
名称 Name 类型 Type 说明 Description
x number 图块的整数 x 坐标。 The integer x coordinate of the tile.
y number 图块的整数 y 坐标。 The integer y coordinate of the tile.
level number 瓷砖的细节层次。零是最不详细的。 The tile level-of-detail. Zero is the least detailed.
result object 可选 optional 将结果复制到的实例,如果应创建新实例,则为未定义。 The instance to which to copy the result, or undefined if a new instance should be created.
返回: Returns:
指定的“结果”,或者如果“结果”未定义,则包含矩形的新对象。 The specified 'result', or a new object containing the rectangle if 'result' is undefined.

tileXYToRectangle(x, y, level, result)Rectangle

将图块 x、y 坐标和级别转换为以弧度表示的制图矩形。 Converts tile x, y coordinates and level to a cartographic rectangle in radians.
名称 Name 类型 Type 说明 Description
x number 图块的整数 x 坐标。 The integer x coordinate of the tile.
y number 图块的整数 y 坐标。 The integer y coordinate of the tile.
level number 瓷砖的细节层次。零是最不详细的。 The tile level-of-detail. Zero is the least detailed.
result object 可选 optional 将结果复制到的实例,如果应创建新实例,则为未定义。 The instance to which to copy the result, or undefined if a new instance should be created.
返回: Returns:
指定的“结果”,或者如果“结果”未定义,则包含矩形的新对象。 The specified 'result', or a new object containing the rectangle if 'result' is undefined.
需要帮助吗?获得答案的最快方法是从社区和团队那里获得答案 Need help? The fastest way to get answers is from the community and team on the Cesium Forum.