# PolygonMeasure

绘制面

const wktString = `MULTIPOLYGON (((113.87531596066322 25.258969292199083, 113.87531569086661 25.25923334214508, 113.87512178084557 25.259567631840923, 113.87500944113287 25.259680932029539, 113.87448639093441 25.259334332413687, 113.87407787119685 25.259265171850359, 113.8740866108086 25.259109072026092, 113.87422237066596 25.258862742321753, 113.87478451079687 25.258106282079382, 113.87521084070784 25.257648962429698, 113.87544354118677 25.257244281898124, 113.87551725142009 25.257177382230452, 113.87563286106797 25.25718237166916, 113.87612098069872 25.257022392169631, 113.87639866076984 25.256876981687412, 113.87683561077495 25.256655121636527, 113.87694798106452 25.25665095237963, 113.87724528074523 25.256557771823736, 113.87700083062396 25.256673242076431, 113.87679493084158 25.256810531680856, 113.87658629082478 25.256951721644725, 113.87634337134955 25.257117521556495, 113.87616794059818 25.25726389161531, 113.87593825104955 25.257434781689881, 113.87600281068148 25.25770434178196, 113.87601834107375 25.257771752264716, 113.87614559064662 25.258323921611748, 113.87630695060545 25.258881512072094, 113.87626562136143 25.258937781753275, 113.87592594112937 25.258758572050567, 113.87531596066322 25.258969292199083)))`;
const clampToGround = true;
const promise = GeowayGlobe.PolygonMeasure.measureByWkt({
  viewer,
  wktString,
  clampToGround,
});
promise.then((result) => {
  console.log(result);
});
1
2
3
4
5
6
7
8
9
10

# PolygonMeasure options 构造属性

属性 说明 类型 默认值
viewer 地球实例 Object viewer
positions 绘制区域范围 String Null
clampToGround 是否贴地 Boolean True