{"Entry":{"collection":"func","key":"polygon","name":"polygon","aliases":[],"metadata":{"changed_in":[],"changes":[{"descriptions_changed":true,"doc_overhaul":false,"from":"7.2","group_changed":null,"signatures":{"added":[],"removed":[]},"status":"changed","to":"7.3"},{"descriptions_changed":true,"doc_overhaul":false,"from":"7.3","group_changed":null,"signatures":{"added":[],"removed":[]},"status":"changed","to":"7.4"},{"descriptions_changed":false,"doc_overhaul":true,"from":"12","group_changed":null,"signatures":{"added":[],"removed":[]},"status":"changed","to":"13"}],"content_hash":"ae557a83fbd36e2f54295df371fbb745c1c4822149582683444650a49f027452","first_version":"7.1","group":"geometry","group_label":"Geometric Functions And Operators","groups":["geometry"],"imported_at":"2026-09-27T17:57:28.648419+08:00","last_version":"20","name":"polygon","name_key":"polygon","position":10018,"present_in":["7.1","7.2","7.3","7.4","8.0","8.1","8.2","8.3","8.4","9.0","9.1","9.2","9.3","9.4","9.5","9.6","10","11","12","13","14","15","16","17","18","19","20"],"signature":"polygon ( box ) → polygon","signature_count":4,"slug":"polygon","source_rev":"b7bd9cda","summary":"Converts box to a 4-point polygon.","summary_zh":""}},"Definition":{"Collection":"func","Key":"polygon","SourceDatabase":"center","Version":"18","SourceTable":"func","SourceKey":"polygon","SourceRevision":"b7bd9cda","Facts":{"description":"Converts box to a 4-point polygon.","description_html":"Converts box to a 4-point polygon.","description_zh":"","description_zh_html":"","doc":{"anchor":"FUNCTIONS-GEOMETRY-CONV-TABLE","file":"functions-geometry.html","slug":"18"},"group":"geometry","group_label":"Geometric Functions And Operators","lang":"en","layout":"table-new","pages":["functions-geometry.html"],"prose_only":false,"signatures":[{"description":"Converts box to a 4-point polygon.","description_html":"Converts box to a 4-point polygon.","description_zh":"","description_zh_html":"","examples":[{"expr":"polygon(box '(1,1),(0,0)')","result":"((0,0),(0,1),(1,1),(1,0))"}],"html":"\u003ccode class=\"function\"\u003epolygon\u003c/code\u003e ( \u003ccode class=\"type\"\u003ebox\u003c/code\u003e ) → \u003ccode class=\"returnvalue\"\u003epolygon\u003c/code\u003e","returns":"polygon","text":"polygon ( box ) → polygon","zh_from":""},{"description":"Converts circle to a 12-point polygon.","description_html":"Converts circle to a 12-point polygon.","description_zh":"","description_zh_html":"","examples":[{"expr":"polygon(circle '\u003c(0,0),2\u003e')","result":"((-2,0),​(-1.7320508075688774,0.9999999999999999),​(-1.0000000000000002,1.7320508075688772),​(-1.2246063538223773e-16,2),​(0.9999999999999996,1.7320508075688774),​(1.732050807568877,1.0000000000000007),​(2,2.4492127076447545e-16),​(1.7320508075688776,-0.9999999999999994),​(1.0000000000000009,-1.7320508075688767),​(3.673819061467132e-16,-2),​(-0.9999999999999987,-1.732050807568878),​(-1.7320508075688767,-1.0000000000000009))"}],"html":"\u003ccode class=\"function\"\u003epolygon\u003c/code\u003e ( \u003ccode class=\"type\"\u003ecircle\u003c/code\u003e ) → \u003ccode class=\"returnvalue\"\u003epolygon\u003c/code\u003e","returns":"polygon","text":"polygon ( circle ) → polygon","zh_from":""},{"description":"Converts circle to an n-point polygon.","description_html":"Converts circle to an \u003cem class=\"replaceable\"\u003e\u003ccode\u003en\u003c/code\u003e\u003c/em\u003e-point polygon.","description_zh":"","description_zh_html":"","examples":[{"expr":"polygon(4, circle '\u003c(3,0),1\u003e')","result":"((2,0),​(3,1),​(4,1.2246063538223773e-16),​(3,-1))"}],"html":"\u003ccode class=\"function\"\u003epolygon\u003c/code\u003e ( \u003ccode class=\"type\"\u003einteger\u003c/code\u003e, \u003ccode class=\"type\"\u003ecircle\u003c/code\u003e ) → \u003ccode class=\"returnvalue\"\u003epolygon\u003c/code\u003e","returns":"polygon","text":"polygon ( integer, circle ) → polygon","zh_from":""},{"description":"Converts closed path to a polygon with the same list of points.","description_html":"Converts closed path to a polygon with the same list of points.","description_zh":"","description_zh_html":"","examples":[{"expr":"polygon(path '((0,0),(1,1),(2,0))')","result":"((0,0),(1,1),(2,0))"}],"html":"\u003ccode class=\"function\"\u003epolygon\u003c/code\u003e ( \u003ccode class=\"type\"\u003epath\u003c/code\u003e ) → \u003ccode class=\"returnvalue\"\u003epolygon\u003c/code\u003e","returns":"polygon","text":"polygon ( path ) → polygon","zh_from":""}],"zh_from":""},"ManualEvidence":{"doc":{"anchor":"FUNCTIONS-GEOMETRY-CONV-TABLE","file":"functions-geometry.html","slug":"18"}},"MeasuredEvidence":{}},"Text":{"Collection":"func","Key":"polygon","SourceDatabase":"pgweb","Version":"18","Locale":"zh-Hans","Title":"polygon","Summary":"将框转换为4点多边形。","BodyHTML":"将框转换为4点多边形。\u003cpre\u003epolygon ( box ) → polygon\u003c/pre\u003e将框转换为4点多边形。\u003cpre\u003epolygon ( circle ) → polygon\u003c/pre\u003e将圆转换为12点多边形。\u003cpre\u003epolygon ( integer, circle ) → polygon\u003c/pre\u003e将圆转换为\u003cem\u003e\u003ccode\u003en\u003c/code\u003e\u003c/em\u003e点多边形。\u003cpre\u003epolygon ( path ) → polygon\u003c/pre\u003e将封闭路径转换为具有相同点列表的多边形。","SourceRevision":"ca936764","ContentHash":"8c5c531ee7e65c58433553dd8a2aeddc5e1d2818a240494e1bfac97072e0a7b3","Payload":{"description_zh":"将框转换为4点多边形。","description_zh_html":"将框转换为4点多边形。","signatures":[{"description_zh":"将框转换为4点多边形。","description_zh_html":"将框转换为4点多边形。","returns":"polygon","text":"polygon ( box ) → polygon","zh_from":"doc"},{"description_zh":"将圆转换为12点多边形。","description_zh_html":"将圆转换为12点多边形。","returns":"polygon","text":"polygon ( circle ) → polygon","zh_from":"doc"},{"description_zh":"将圆转换为n点多边形。","description_zh_html":"将圆转换为\u003cem class=\"replaceable\"\u003e\u003ccode\u003en\u003c/code\u003e\u003c/em\u003e点多边形。","returns":"polygon","text":"polygon ( integer, circle ) → polygon","zh_from":"doc"},{"description_zh":"将封闭路径转换为具有相同点列表的多边形。","description_zh_html":"将封闭路径转换为具有相同点列表的多边形。","returns":"polygon","text":"polygon ( path ) → polygon","zh_from":"doc"}],"zh_from":"doc"}},"RequestedLocale":"zh-Hans","Fallback":false,"Versions":["10","11","12","13","14","15","16","17","18","19","20","7.1","7.2","7.3","7.4","8.0","8.1","8.2","8.3","8.4","9.0","9.1","9.2","9.3","9.4","9.5","9.6"],"Locales":["en","zh-Hans"],"Signatures":[{"Version":"18","Ordinal":0,"Hash":"dd5f17aaa2f4f5c447e492c79ee273c6b3f4c86dbeb03ef521ade3da3e88f4d9","Text":"polygon ( box ) → polygon","Returns":"polygon","Payload":{"description":"Converts box to a 4-point polygon.","description_html":"Converts box to a 4-point polygon.","description_zh":"","description_zh_html":"","examples":[{"expr":"polygon(box '(1,1),(0,0)')","result":"((0,0),(0,1),(1,1),(1,0))"}],"html":"\u003ccode class=\"function\"\u003epolygon\u003c/code\u003e ( \u003ccode class=\"type\"\u003ebox\u003c/code\u003e ) → \u003ccode class=\"returnvalue\"\u003epolygon\u003c/code\u003e","returns":"polygon","text":"polygon ( box ) → polygon","zh_from":""}},{"Version":"18","Ordinal":1,"Hash":"35ba25d44a0e3ede5fe4f21161cd80b789d7f10c0a779f289403bb426eaf5ce3","Text":"polygon ( circle ) → polygon","Returns":"polygon","Payload":{"description":"Converts circle to a 12-point polygon.","description_html":"Converts circle to a 12-point polygon.","description_zh":"","description_zh_html":"","examples":[{"expr":"polygon(circle '\u003c(0,0),2\u003e')","result":"((-2,0),​(-1.7320508075688774,0.9999999999999999),​(-1.0000000000000002,1.7320508075688772),​(-1.2246063538223773e-16,2),​(0.9999999999999996,1.7320508075688774),​(1.732050807568877,1.0000000000000007),​(2,2.4492127076447545e-16),​(1.7320508075688776,-0.9999999999999994),​(1.0000000000000009,-1.7320508075688767),​(3.673819061467132e-16,-2),​(-0.9999999999999987,-1.732050807568878),​(-1.7320508075688767,-1.0000000000000009))"}],"html":"\u003ccode class=\"function\"\u003epolygon\u003c/code\u003e ( \u003ccode class=\"type\"\u003ecircle\u003c/code\u003e ) → \u003ccode class=\"returnvalue\"\u003epolygon\u003c/code\u003e","returns":"polygon","text":"polygon ( circle ) → polygon","zh_from":""}},{"Version":"18","Ordinal":2,"Hash":"998c0cebbd71e3ba55464a51035c18f39214066681c7a04bbb5547d2bc4f241f","Text":"polygon ( integer, circle ) → polygon","Returns":"polygon","Payload":{"description":"Converts circle to an n-point polygon.","description_html":"Converts circle to an \u003cem class=\"replaceable\"\u003e\u003ccode\u003en\u003c/code\u003e\u003c/em\u003e-point polygon.","description_zh":"","description_zh_html":"","examples":[{"expr":"polygon(4, circle '\u003c(3,0),1\u003e')","result":"((2,0),​(3,1),​(4,1.2246063538223773e-16),​(3,-1))"}],"html":"\u003ccode class=\"function\"\u003epolygon\u003c/code\u003e ( \u003ccode class=\"type\"\u003einteger\u003c/code\u003e, \u003ccode class=\"type\"\u003ecircle\u003c/code\u003e ) → \u003ccode class=\"returnvalue\"\u003epolygon\u003c/code\u003e","returns":"polygon","text":"polygon ( integer, circle ) → polygon","zh_from":""}},{"Version":"18","Ordinal":3,"Hash":"bb62e985377e3c19d2b6f965392be7160b93204ecbb3f8bcff351438cf428fa5","Text":"polygon ( path ) → polygon","Returns":"polygon","Payload":{"description":"Converts closed path to a polygon with the same list of points.","description_html":"Converts closed path to a polygon with the same list of points.","description_zh":"","description_zh_html":"","examples":[{"expr":"polygon(path '((0,0),(1,1),(2,0))')","result":"((0,0),(1,1),(2,0))"}],"html":"\u003ccode class=\"function\"\u003epolygon\u003c/code\u003e ( \u003ccode class=\"type\"\u003epath\u003c/code\u003e ) → \u003ccode class=\"returnvalue\"\u003epolygon\u003c/code\u003e","returns":"polygon","text":"polygon ( path ) → polygon","zh_from":""}}],"Spellings":null,"SQLState":null,"Evidence":null}
