define(["exports","./arrayRemoveDuplicates-18786327","./Matrix2-ccd5b911","./when-4bbc8319","./ComponentDatatype-93750d1a","./PolylinePipeline-8457214f"],function(e,f,A,C,w,P){"use strict";var i={};var b=new A.Cartographic,M=new A.Cartographic;function E(e,i,t,r){var a=(i=f.arrayRemoveDuplicates(i,A.Cartesian3.equalsEpsilon)).length;if(!(a<2)){var n=C.defined(r),o=C.defined(t),l=new Array(a),s=new Array(a),h=new Array(a),g=i[0];l[0]=g;var p=e.cartesianToCartographic(g,b);o&&(p.height=t[0]),s[0]=p.height,h[0]=n?r[0]:0;for(var u,c,d=s[0]===h[0],y=1,v=1;v