/*
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
See https://js.arcgis.com/4.24/esri/copyright.txt for details.
*/
define(["exports","../../../../core/jsonMap"],(function(e,t){"use strict";const o=new t.JSONMap({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryMultiPatch:"multipatch",mesh:"mesh"});function n(e){return o.toJSON(e)}function l(e,t,o){const n=[],l=[];let r=0,i=0;for(const s of e){const e=i;let u=s[0][0],a=s[0][1];n[i++]=u,n[i++]=a;let c=0;for(let t=1;t<s.length;++t){const e=u,o=a;u=s[t][0],a=s[t][1],c+=a*e-u*o,n[i++]=u,n[i++]=a}t(c/2),c>0?(e-r>0&&(o(r,e,n,l),r=e),l.length=0):c<0&&e-r>0?l.push(.5*(e-r)):i=e}i-r>0&&o(r,i,n,l)}function r(e){const{bandCount:t,attributeTable:o,colormap:n,pixelType:l}=e.rasterInfo;return 1===t&&(null!=o||null!=n||"u8"===l||"s8"===l)}e.analyzeRings=l,e.canUseMajorityInterpolationOnDataSource=r,e.toJSONGeometryType=n,Object.defineProperties(e,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})}));
