define(["exports","./Cartesian2-6033fa5d","./Cartographic-67e73ef9","./Check-52a7d806","./when-92c6cf3c","./Intersect-b97e930a","./Rectangle-bab7abf0"],(function(t,e,h,i,n,r,o){"use strict";function a(t,e,h,i){this.x=n.u(t,0),this.y=n.u(e,0),this.width=n.u(h,0),this.height=n.u(i,0)}a.packedLength=4,a.pack=function(t,e,h){return i.o.typeOf.object("value",t),i.o.defined("array",e),h=n.u(h,0),e[h++]=t.x,e[h++]=t.y,e[h++]=t.width,e[h]=t.height,e},a.unpack=function(t,e,h){return i.o.defined("array",t),e=n.u(e,0),n.e(h)||(h=new a),h.x=t[e++],h.y=t[e++],h.width=t[e++],h.height=t[e],h},a.fromPoints=function(t,e){if(n.e(e)||(e=new a),!n.e(t)||0===t.length)return e.x=0,e.y=0,e.width=0,e.height=0,e;for(var h=t.length,i=t[0].x,r=t[0].y,o=t[0].x,c=t[0].y,u=1;uh.width?h.width=n:n<0&&(h.width-=n,h.x=e.x),r>h.height?h.height=r:r<0&&(h.height-=r,h.y=e.y),h},a.intersect=function(t,e){i.o.typeOf.object("left",t),i.o.typeOf.object("right",e);var h=t.x,n=t.y,o=e.x,a=e.y;return h>o+e.width||h+t.widtha+e.height?r.S.OUTSIDE:r.S.INTERSECTING},a.equals=function(t,e){return t===e||n.e(t)&&n.e(e)&&t.x===e.x&&t.y===e.y&&t.width===e.width&&t.height===e.height},a.prototype.clone=function(t){return a.clone(this,t)},a.prototype.intersect=function(t){return a.intersect(this,t)},a.prototype.equals=function(t){return a.equals(this,t)},t.f=a}));