@arcgis/core 4.33.0-next.20250226 → 4.33.0-next.20250227
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/esri/core/workers/RemoteClient.js +1 -1
- package/assets/esri/core/workers/chunks/{2716394f121804d93b4e.js → 4253438dd3045566892d.js} +1 -1
- package/assets/esri/core/workers/chunks/823bf95f42cc42f20e22.js +1 -0
- package/assets/esri/core/workers/chunks/ae25c6108918d37e61bf.js +1 -0
- package/assets/esri/core/workers/chunks/{feb656f172ec9fe64752.js → af005704f23088db3ded.js} +1 -1
- package/assets/esri/core/workers/chunks/{dea40706ca4e37d5c6e2.js → d4d011eea16a89a5aad9.js} +1 -1
- package/core/sql/StandardizedFunctions.js +1 -1
- package/core/sql/WhereClause.js +1 -1
- package/core/sql/sqlCompareUtils.js +1 -1
- package/geometry/SpatialReference.js +1 -1
- package/layers/SubtypeGroupLayer.js +1 -1
- package/package.json +1 -1
- package/support/popupUtils.js +1 -1
- package/support/revision.js +1 -1
- package/symbols/cim/animationUtils.js +1 -1
- package/views/2d/engine/webgl/animations/utils.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/GraphShaderModule.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/animated/AnimatedMarkerShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/dotDensity/DotDensityPointShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/dotDensity/DotDensityPolygonShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/markers/MarkerShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/BitmapShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/BlendShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/ComplexFillShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/ComplexOutlineFillShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/FillShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/GradientFillShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/GradientStrokeShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/GridShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/HeatmapAccumulateShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/HeatmapResolveShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/LineShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/MagnifierShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/OpacityShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/OutlineFillShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/OverlayShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/PatternFillShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/PatternOutlineFillShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/TestShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/TexturedLineShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/RasterColorizerLUTShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/RasterColorizerShadedReliefShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/RasterColorizerStretchShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/AspectShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/BandArithmeticShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/ColormapToRGBShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/CompositeBandShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/ComputeChangeShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/ContrastBrightnessShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/ConvolutionShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/CurvatureShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/ExtractBandShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/FocalStatisticsShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/GrayscaleShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/HillshadeShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/LocalShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/MaskShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/NDVIShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/RemapShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/ReprojectShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/ShadedReliefShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/SlopeShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/StretchShader.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/text/TextShader.js +1 -1
- package/views/3d/interactive/visualElements/OutlineVisualElement.js +1 -1
- package/views/3d/layers/support/FeatureTileFetcher3D.js +1 -1
- package/views/3d/layers/support/FeatureTileFetcher3DContext.js +1 -1
- package/views/3d/webgl-engine/lib/ComponentUtils.js +1 -1
- package/views/3d/webgl-engine/lib/Renderer.js +1 -1
- package/views/View.js +1 -1
- package/views/webgl/capabilities.js +1 -1
- package/widgets/Feature/FeatureRelationship.js +1 -1
- package/widgets/Feature/FeatureUtilityNetworkAssociationList.js +1 -1
- package/widgets/Feature/FeatureUtilityNetworkAssociations.js +1 -1
- package/widgets/Feature.js +1 -1
- package/widgets/FeatureForm/FeatureFormUtilityNetworkAssociations/FeatureFormUtilityNetworkAssociationList.js +1 -1
- package/widgets/FeatureForm/FeatureFormUtilityNetworkAssociations/UtilityNetworkAssociationItemList.js +1 -1
- package/widgets/FeatureTable.js +1 -1
- package/widgets/Features/FeaturesDrillIn.js +1 -1
- package/widgets/Legend/support/ActiveLayerInfo.js +1 -1
- package/widgets/OrientedImageryViewer/OrientedImageryViewerViewModel.js +1 -1
- package/widgets/OrientedImageryViewer/adapters/sketch/DataCaptureAdapter.js +1 -1
- package/widgets/OrientedImageryViewer/components/ImageOverlays.js +1 -1
- package/widgets/OrientedImageryViewer/dataCaptureUtils.js +1 -1
- package/widgets/OrientedImageryViewer/symbols.js +1 -1
- package/widgets/OrientedImageryViewer.js +1 -1
- package/widgets/support/UtilityNetworkAssociations/utilityNetworkUtils.js +1 -1
- package/assets/esri/core/workers/chunks/66338f008ff0992ffca2.js +0 -1
- package/assets/esri/core/workers/chunks/d5ebe6b7cd9c8e40b386.js +0 -1
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as t,a as
|
|
5
|
+
import{_ as t,a as r}from"../../../../../../../chunks/tslib.es6.js";import{location as e,uniform as o,input as s}from"../../GraphShaderModule.js";import{greaterThan as i,Float as a,ifElse as l,Vec4 as n}from"../../graph/glsl.js";import{BaseHittestVertexInput as p}from"./AFeatureShader.js";import{getLineFragmentColor as m}from"./LineShader.js";import{LocalTileOffset as f}from"./LocalTileOffset.js";import{MosaicInfo as h}from"./MosaicInfo.js";import{OutlineFillVertexInput as u,OutlineFillFragmentInput as d,OutlineFillShader as c,getOutlineFillVertexData as j}from"./OutlineFillShader.js";import{getPatternFillVertexData as g,getPatternFillFragmentColor as v}from"./PatternFillShader.js";class y extends u{}t([e(9,n)],y.prototype,"tlbr",void 0),t([e(10,a)],y.prototype,"inverseRasterizationScale",void 0);class S extends d{}class x extends c{constructor(){super(...arguments),this.type="PatternOutlineFillShader"}vertex(t,r){return{...j(this,t,r),...g(this,t)}}fragment(t){const{isOutline:r}=t,e=i(r,new a(.5)),o=m(t,this.antialiasingControls.blur),s=v(t,this.mosaicInfo),n=l(e,o,s),p=l(e,new a(1/255),new a(0));return this.getFragmentOutput(n,t,p)}}t([o(h)],x.prototype,"mosaicInfo",void 0),t([o(f)],x.prototype,"localTileOffset",void 0),t([r(0,s(y)),r(1,s(p))],x.prototype,"vertex",null),t([r(0,s(S))],x.prototype,"fragment",null);export{S as PatternOutlineFillFragmentInput,x as PatternOutlineFillShader,y as PatternOutlineFillVertexInput};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as o,a as t}from"../../../../../../../chunks/tslib.es6.js";import{uniform as e,UniformGroup as r,location as s,GraphShaderModule as
|
|
5
|
+
import{_ as o,a as t}from"../../../../../../../chunks/tslib.es6.js";import{uniform as e,UniformGroup as r,location as s,GraphShaderModule as p,option as l,define as i,VertexInput as d,FragmentOutput as n,input as a,FragmentInput as c}from"../../GraphShaderModule.js";import{FixedArray as v,Float as y,equal as f,ifElse as u,Int as h,Vec4 as x,and as m,lessThan as w,greaterThan as g,Vec2 as C,Vec3 as b}from"../../graph/glsl.js";class j extends r{}o([e(y)],j.prototype,"zoomLevel",void 0);class k extends r{getColor(o){const t=this.validValues.findIndex((t=>f(t,o)));return u(f(t,new h(-1)),this.colorFallback,this.color)}}o([e(x)],k.prototype,"color",void 0),o([e(x)],k.prototype,"colorFallback",void 0),o([e(v.ofType(y,4))],k.prototype,"validValues",void 0);class z extends d{}o([s(0,C)],z.prototype,"pos",void 0),o([s(1,b)],z.prototype,"id",void 0),o([s(2,y)],z.prototype,"bitset",void 0),o([s(3,C)],z.prototype,"offset",void 0),o([s(4,y)],z.prototype,"size",void 0),o([s(5,x)],z.prototype,"color",void 0);class D extends c{}class F extends p{constructor(){super(...arguments),this.type="TestShader"}vertex(o){const{size:t,offset:e,pos:r}=o;let s=o.color;this.dataDrivenColor&&(s=this.dataDrivenColor.getColor(new y(1)));const p=e.multiply(t);return{glPosition:new x(r.add(p),0,1),color:s,offset:e}}fragment(o){const t=new n,{offset:e}=o;return t.discard=m(g(e.x,new y(-.5)),g(e.y,new y(-.5)),w(e.x,new y(.5)),w(e.y,new y(.5))),this.returnRed?t.fragColor=new x(1,0,0,1):t.fragColor=o.color,t}}o([l(k)],F.prototype,"dataDrivenColor",void 0),o([e(j)],F.prototype,"view",void 0),o([i],F.prototype,"returnRed",void 0),o([t(0,a(z))],F.prototype,"vertex",null),o([t(0,a(D))],F.prototype,"fragment",null);export{k as DataDrivenColorByValueMatch,F as TestShader};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as t,a as e}from"../../../../../../../chunks/tslib.es6.js";import{pt2px as i}from"../../../../../../../core/screenUtils.js";import{dashSdfRasterizationScale as
|
|
5
|
+
import{_ as t,a as e}from"../../../../../../../chunks/tslib.es6.js";import{pt2px as i}from"../../../../../../../core/screenUtils.js";import{dashSdfRasterizationScale as s,dashSdfDistanceNormalization as o}from"../../../../../../../symbols/cim/constants.js";import{location as a,uniform as r,input as l}from"../../GraphShaderModule.js";import{max as n,Float as p,fract as c,mix as m,Vec2 as u,texture2D as d,cond as y,equal as h,sqrt as f,pow as w,clamp as b,Vec4 as g,ifElse as x,greaterThan as v,dot as D}from"../../graph/glsl.js";import{BaseHittestVertexInput as S}from"./AFeatureShader.js";import{bitsetLineScaleDash as j,bitsetLineIsSdf as A,bitsetGenericConsiderAlphaOnly as z}from"./constants.js";import{LineVertexInput as F,LineFragmentInput as T,LineShader as _,getLineVertexData as L,getLineAntialiasing as I}from"./LineShader.js";import{MosaicInfo as C}from"./MosaicInfo.js";import{getBit as O,rgba2float as P}from"./utils.js";class W extends F{}t([a(9,p)],W.prototype,"accumulatedDistance",void 0),t([a(10,u)],W.prototype,"segmentDirection",void 0),t([a(11,p)],W.prototype,"offsetAlongLine",void 0),t([a(12,p)],W.prototype,"capType",void 0),t([a(13,g)],W.prototype,"tlbr",void 0);class R extends T{}class H extends _{constructor(){super(...arguments),this.type="TexturedLineShader"}_getDistanceRatio(t,e){const s=O(t.bitset,j);return s.multiply(n(e,new p(.25)).multiply(new p(2))).add(new p(1).subtract(s).multiply(i(1)))}_getSDFAlpha(t){const{halfWidth:e,normal:i,tlbr:a,patternSize:r,accumulatedDistance:l,offsetAlongLine:x,dashToPx:v,capType:D}=t,S=r.x.divide(s).multiply(v),j=c(l.add(x).divide(S)),A=m(a.xy,a.zw,new u(j,.5)),z=P(d(this.mosaicInfo.texture,A)).multiply(2).subtract(1).multiply(o).multiply(v),F=i.y.multiply(e),T=y([h(D,new p(1)),z.subtract(e)],[h(D,new p(2)),f(w(n(z,new p(0)),new p(2)).add(F.multiply(F))).subtract(e)],[!0,z]),_=b(new p(.25).subtract(T),new p(0),new p(1));return new g(_)}_getPatternColor(t){const{halfWidth:e,normal:i,color:s,accumulatedDistance:o,patternSize:a,sampleAlphaOnly:r,tlbr:l}=t,n=a.y.multiply(new p(2).multiply(e).divide(a.x)),y=c(o.divide(n)),h=new p(.5).multiply(i.y).add(new p(.5)),f=m(l.xy,l.zw,new u(h,y));let w=d(this.mosaicInfo.texture,f);return null!=this.visualVariableColor&&(w=x(v(r,new p(.5)),new g(s.a),s)),w}vertex(t,e){const{segmentDirection:i,tlbr:s,bitset:o}=t,a=L(this,t),r=t.accumulatedDistance.divide(this.view.displayZoomFactor).add(D(i,a.scaledOffset)),l=new u(s.z.subtract(s.x),s.w.subtract(s.y)),n=s.divide(this.mosaicInfo.size.xyxy),c=O(o,A),m=O(o,z),d=x(v(c,new p(.5)),this._getDistanceRatio(t,a.scaledHalfWidth),new p(1));return{...a,tlbr:n,patternSize:l,accumulatedDistance:r,isSDF:c,sampleAlphaOnly:m,dashToPx:d,offsetAlongLine:t.offsetAlongLine,capType:t.capType,...this.maybeRunHittest(t,e,a.halfWidth)}}fragment(t){const{color:e,opacity:i,isSDF:s}=t,o=I(t,this.antialiasingControls.blur),a=x(v(s,new p(.5)),this._getSDFAlpha(t),this._getPatternColor(t)),r=e.multiply(i).multiply(o).multiply(a);return this.getFragmentOutput(r,t)}}t([r(C)],H.prototype,"mosaicInfo",void 0),t([e(0,l(W)),e(1,l(S))],H.prototype,"vertex",null);export{R as TexturedLineFragmentInput,H as TexturedLineShader,W as TexturedLineVertexInput};
|
package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/RasterColorizerLUTShader.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as
|
|
5
|
+
import{_ as r}from"../../../../../../../../chunks/tslib.es6.js";import{uniform as o}from"../../../GraphShaderModule.js";import{Float as s}from"../../../graph/glsl.js";import{BaseRasterColorizerShader as t}from"./BaseRasterColorizerShader.js";import{lookupColor as e,ColormapConfig as i}from"./lut.js";class p extends t{constructor(){super(...arguments),this.type="RasterColorizerLUTShader"}_colorize(r){const o=this._getPixel(r);return e(o,new s(1),this.colormapConfig,!1)}}r([o(i)],p.prototype,"colormapConfig",void 0);export{p as RasterColorizerLUTShader};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as o}from"../../../../../../../../chunks/tslib.es6.js";import{define as i,uniform as r,option as t}from"../../../GraphShaderModule.js";import{Vec4 as e,clamp as s,Float as l,Vec3 as a}from"../../../graph/glsl.js";import{BaseRasterColorizerShader as p}from"./BaseRasterColorizerShader.js";import{rgb2hsv as n,hsv2rgb as
|
|
5
|
+
import{_ as o}from"../../../../../../../../chunks/tslib.es6.js";import{define as i,uniform as r,option as t}from"../../../GraphShaderModule.js";import{Vec4 as e,clamp as s,Float as l,Vec3 as a}from"../../../graph/glsl.js";import{BaseRasterColorizerShader as p}from"./BaseRasterColorizerShader.js";import{rgb2hsv as n,hsv2rgb as h}from"./colorConversion.js";import{lookupColor as m,ColormapConfig as c}from"./lut.js";import{getSurfaceValues as d,hillshade as f,HillshadeConfig as u}from"./surface.js";class g extends p{constructor(){super(...arguments),this.type="RasterColorizerShadedReliefShader",this.applyColormap=!1,this.isMultidirectional=!1}_colorize(o){const{texture:i}=this.config,r=d(i,o,this.config.srcImageSize),t=f(r,this.hillshadeConfig,this.isMultidirectional);if(!this.applyColormap)return new e(t.x,t.x,t.x,t.a);const{minValue:p,maxValue:c}=this.hillshadeConfig,u=this._getPixel(o),g=c.subtract(p),x=u.r.subtract(p),y=s(x.divide(g),new l(0),new l(1)),C=m(new e(y,y,y,1),new l(255),this.colormapConfig),j=n(C.xyz),w=h(new a(j.xy,t.x));return new e(w,C.a.multiply(t.a))}}o([i],g.prototype,"applyColormap",void 0),o([i],g.prototype,"isMultidirectional",void 0),o([r(u)],g.prototype,"hillshadeConfig",void 0),o([t(c)],g.prototype,"colormapConfig",void 0);export{g as RasterColorizerShadedReliefShader};
|
package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/RasterColorizerStretchShader.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as o}from"../../../../../../../../chunks/tslib.es6.js";import{define as t,uniform as r,option as s}from"../../../GraphShaderModule.js";import{Vec4 as i,Float as
|
|
5
|
+
import{_ as o}from"../../../../../../../../chunks/tslib.es6.js";import{define as t,uniform as r,option as s}from"../../../GraphShaderModule.js";import{Vec4 as i,Float as e}from"../../../graph/glsl.js";import{BaseRasterColorizerShader as p}from"./BaseRasterColorizerShader.js";import{lookupColor as a,ColormapConfig as m}from"./lut.js";import{stretch as h,StretchConfig as l}from"./stretch.js";class n extends p{constructor(){super(...arguments),this.type="RasterColorizerStretchShader",this.isMultiband=!0,this.applyColormap=!1,this.useGamma=!1,this.noOp=!1}_colorize(o){const t=this._getPixel(o);if(this.noOp)return t;let r=h(t,this.stretchConfig,this.useGamma);if(this.isMultiband)return r;if(r=new i(r.rrr,r.a),this.applyColormap){const o=this.useGamma?255:1;r=a(r,new e(o),this.colormapConfig)}return r}}o([t],n.prototype,"isMultiband",void 0),o([t],n.prototype,"applyColormap",void 0),o([t],n.prototype,"useGamma",void 0),o([t],n.prototype,"noOp",void 0),o([r(l)],n.prototype,"stretchConfig",void 0),o([s(m)],n.prototype,"colormapConfig",void 0);export{n as RasterColorizerStretchShader};
|
package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/AspectShader.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as e}from"../../../../../../../../../chunks/tslib.es6.js";import{uniform as t,UniformGroup as
|
|
5
|
+
import{_ as e}from"../../../../../../../../../chunks/tslib.es6.js";import{uniform as t,UniformGroup as s}from"../../../../GraphShaderModule.js";import{Vec2 as i,negate as r,sign as l,abs as o,Float as p,step as m,mod as d,atan as a,mix as c,Vec4 as n}from"../../../../graph/glsl.js";import{getSurfaceValues as u,computeDeltaZ as y}from"../surface.js";import{BaseRasterProcessorShader as f}from"./BaseRasterProcessorShader.js";class h extends s{}e([t(i)],h.prototype,"cellSize",void 0);class g extends f{constructor(){super(...arguments),this.type="AspectShader"}_process(e){const{texture:t}=this.config,s=u(t,e,this.config.srcImageSize),f=new i(1).divide(this.aspectConfig.cellSize.multiply(8)),{x:h,y:g}=y(s,f),w=r(g),S=s[9].multiply(l(o(h).add(o(w)))),j=o(l(h)),x=new p(3.14159265359),v=new p(0),z=m(v,w).multiply(.5).multiply(x).add(m(w,v).multiply(1.5).multiply(x)),C=d(new p(2.5).multiply(x).add(a(w,r(h))),new p(2).multiply(x)),_=c(z,C,j).multiply(180).divide(x);return new n(_,_,_,S)}}e([t(h)],g.prototype,"aspectConfig",void 0);export{g as AspectShader};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as t}from"../../../../../../../../../chunks/tslib.es6.js";import{uniform as s,define as u,option as r,UniformGroup as l}from"../../../../GraphShaderModule.js";import{Vec4 as
|
|
5
|
+
import{_ as t}from"../../../../../../../../../chunks/tslib.es6.js";import{uniform as s,define as u,option as r,UniformGroup as l}from"../../../../GraphShaderModule.js";import{Vec4 as i,pow as a,Float as e,sqrt as d,Mat3 as p,Vec3 as c}from"../../../../graph/glsl.js";import{oneMinus as m}from"../../utils.js";import{BaseRasterProcessorShader as n}from"./BaseRasterProcessorShader.js";import{roundOutput as o,invertValue as y}from"./math.js";class b extends l{}t([s(p)],b.prototype,"bandIndexMat3",void 0);class h extends l{}t([s(c)],h.prototype,"adjustments",void 0);class x extends n{constructor(){super(...arguments),this.type="BandArithmeticShader",this.isOutputRounded=!1}_process(t){const s=this._getPixel(t),u=this.bandArithmeticConfig.bandIndexMat3.multiply(s.rgb),r=this._processIndex(u),l=new i(r,r,r,s.a);return this.isOutputRounded?o(l):l}_processIndex(t){const{r:s,g:u}=t,r=this.adjustmentConfig?.adjustments;switch(this.indexType){case"ndxi":{const t=s.subtract(u),r=s.add(u);return t.multiply(y(r))}case"sr":return s.multiply(y(u));case"ci":return s.multiply(y(u)).subtract(1);case"savi":{const{x:t}=r,l=s.subtract(u),i=s.add(u).add(t);return l.multiply(y(i)).multiply(t.add(1))}case"tsavi":{const{x:t,y:l,z:i}=r,a=i.multiply(t.multiply(t).add(1)).subtract(l.multiply(t)),e=t.multiply(s.subtract(t.multiply(u)).subtract(l)),d=l.multiply(s).add(u).add(a);return e.multiply(y(d))}case"msavi":{const t=s.multiply(2).add(1),r=t.multiply(t).subtract(s.subtract(u).multiply(8));return t.subtract(d(r)).multiply(.5)}case"gemi":{const t=s.multiply(s).subtract(u.multiply(u)).multiply(2).add(s.multiply(1.5)).add(u.multiply(.5)),r=s.add(u).add(.5),l=t.multiply(y(r)),i=l.multiply(m(l.multiply(.25))),a=u.subtract(.125).multiply(y(m(u)));return i.subtract(a)}case"pvi":{const{x:t,y:l}=r,i=d(t.multiply(t).add(1));return s.subtract(u.multiply(t)).subtract(l).multiply(y(i))}case"vari":{const s=t.g.subtract(t.r),u=t.g.add(t.r).subtract(t.b);return s.multiply(y(u))}case"rtvicore":return s.subtract(u).multiply(100).subtract(s.subtract(t.b).multiply(10));case"bai":{const t=a(new e(.1).subtract(u),new e(2)),r=a(new e(.06).subtract(s),new e(2));return y(t.add(r))}case"evi":{const r=t.b,l=s.add(u.multiply(6)).subtract(r.multiply(7.5)).add(1);return s.subtract(u).multiply(2.5).multiply(y(l))}case"wndwi":{const{r:s,g:u,b:l}=t,i=r.x,a=i.multiply(u),e=i.multiply(l),d=s.add(a).add(l).subtract(e);return s.subtract(a).subtract(l).add(e).multiply(y(d))}case"mtvi":{const r=t.b,l=a(s.multiply(2).add(1),new e(2)),i=s.multiply(6).subtract(d(u).multiply(5)),p=d(l.subtract(i).subtract(.5)),c=s.subtract(r).multiply(1.2),m=u.subtract(r).multiply(2.5);return c.subtract(m).multiply(1.5).multiply(y(p))}default:return s}}}t([u],x.prototype,"indexType",void 0),t([u],x.prototype,"isOutputRounded",void 0),t([s(b)],x.prototype,"bandArithmeticConfig",void 0),t([r(h)],x.prototype,"adjustmentConfig",void 0);export{x as BandArithmeticShader};
|
package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/ColormapToRGBShader.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as o}from"../../../../../../../../../chunks/tslib.es6.js";import{uniform as r}from"../../../../GraphShaderModule.js";import{Float as s,Vec4 as t}from"../../../../graph/glsl.js";import{lookupColor as e,ColormapConfig as p}from"../lut.js";import{BaseRasterProcessorShader as i}from"./BaseRasterProcessorShader.js";class m extends i{_process(o){const r=this._getPixel(o),p=e(r,new s(1),this.colormapConfig,!1);return new t(p.xyz.multiply(255),p.a)}}o([r(p)],m.prototype,"colormapConfig",void 0);export{m as ColormapToRGBShader};
|
|
5
|
+
import{_ as o}from"../../../../../../../../../chunks/tslib.es6.js";import{uniform as r}from"../../../../GraphShaderModule.js";import{Float as s,Vec4 as t}from"../../../../graph/glsl.js";import{lookupColor as e,ColormapConfig as p}from"../lut.js";import{BaseRasterProcessorShader as i}from"./BaseRasterProcessorShader.js";class m extends i{constructor(){super(...arguments),this.type="ColormapToRGBShader"}_process(o){const r=this._getPixel(o),p=e(r,new s(1),this.colormapConfig,!1);return new t(p.xyz.multiply(255),p.a)}}o([r(p)],m.prototype,"colormapConfig",void 0);export{m as ColormapToRGBShader};
|
package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/CompositeBandShader.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{Vec4 as s}from"../../../../graph/glsl.js";import{BaseRasterProcessorShader as r}from"./BaseRasterProcessorShader.js";import{MultiRasterMixin as e}from"./MultiRasterMixin.js";class t extends(e(r)){_process(r){const{a:e,b:t,c:
|
|
5
|
+
import{Vec4 as s}from"../../../../graph/glsl.js";import{BaseRasterProcessorShader as r}from"./BaseRasterProcessorShader.js";import{MultiRasterMixin as e}from"./MultiRasterMixin.js";class t extends(e(r)){constructor(){super(...arguments),this.type="CompositeBandShader"}_process(r){const{a:e,b:t,c:o,alpha:a}=this._getRasterValues(r);return new s(e,t,o,a)}}export{t as CompositeBandShader};
|
package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/ComputeChangeShader.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as t}from"../../../../../../../../../chunks/tslib.es6.js";import{define as o,uniform as
|
|
5
|
+
import{_ as t}from"../../../../../../../../../chunks/tslib.es6.js";import{define as o,uniform as e}from"../../../../GraphShaderModule.js";import{max as r,abs as s,Vec4 as i}from"../../../../graph/glsl.js";import{BaseRasterProcessorShader as a}from"./BaseRasterProcessorShader.js";import{DomainRangeConfig as p}from"./LocalShader.js";import{invertValue as m,getRangeClipFactor as d,roundOutput as n}from"./math.js";import{MultiRasterMixin as u}from"./MultiRasterMixin.js";class h extends(u(a)){constructor(){super(...arguments),this.type="ComputeChangeShader",this.isOutputRounded=!1}_process(t){const{a:o,b:e,alpha:a}=this._getRasterValues(t);let p=o.subtract(e);"relative-difference"===this.method&&(p=p.multiply(m(r(s(o),s(e)))));const u=d(p,this.domainRangeConfig.domainRange),h=new i(p,p,p,a).multiply(u);return this.isOutputRounded?n(h):h}}t([o],h.prototype,"method",void 0),t([o],h.prototype,"isOutputRounded",void 0),t([e(p)],h.prototype,"domainRangeConfig",void 0);export{h as ComputeChangeShader};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as t}from"../../../../../../../../../chunks/tslib.es6.js";import{uniform as s,UniformGroup as e}from"../../../../GraphShaderModule.js";import{Float as r,cond as
|
|
5
|
+
import{_ as t}from"../../../../../../../../../chunks/tslib.es6.js";import{uniform as s,UniformGroup as e}from"../../../../GraphShaderModule.js";import{Float as r,cond as o,greaterThan as i,equal as n,sign as d,Vec3 as a,Vec4 as p}from"../../../../graph/glsl.js";import{BaseRasterProcessorShader as l}from"./BaseRasterProcessorShader.js";import{roundOutput as m}from"./math.js";class f extends e{}t([s(r)],f.prototype,"contrastOffset",void 0),t([s(r)],f.prototype,"brightnessOffset",void 0);class h extends l{constructor(){super(...arguments),this.type="ContrastBrightnessShader"}_process(t){const{rgb:s,a:e}=this._getPixel(t),{contrastOffset:l,brightnessOffset:f}=this.contrastBrightnessConfig,h=new r(255),c=new r(128),u=s.multiply(200),g=h.multiply(100),y=h.multiply(2).multiply(f),w=u.subtract(g).add(y),b=o([n(l,new r(-100)),new a(c)],[n(l,new r(100)),d(w).add(1).divide(2).multiply(h)],[i(l,new r(0)),w.divide(new r(100).subtract(l).multiply(2)).add(c)],[!0,w.multiply(l.add(100)).divide(2e4).add(c)]);return m(new p(b,e))}}t([s(f)],h.prototype,"contrastBrightnessConfig",void 0);export{h as ContrastBrightnessShader};
|
package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/ConvolutionShader.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as o}from"../../../../../../../../../chunks/tslib.es6.js";import{uniform as t,define as e,UniformGroup as r}from"../../../../GraphShaderModule.js";import{FixedArray2D as s,Float as i,Vec2 as n,reduce2D as l,Vec4 as a,texture2D as p,clamp as c}from"../../../../graph/glsl.js";import{mirror as
|
|
5
|
+
import{_ as o}from"../../../../../../../../../chunks/tslib.es6.js";import{uniform as t,define as e,UniformGroup as r}from"../../../../GraphShaderModule.js";import{FixedArray2D as s,Float as i,Vec2 as n,reduce2D as l,Vec4 as a,texture2D as p,clamp as c}from"../../../../graph/glsl.js";import{mirror as u}from"../surface.js";import{BaseRasterProcessorShader as d}from"./BaseRasterProcessorShader.js";class m extends r{}o([t(s.ofType(i,5,5,!0))],m.prototype,"kernel",void 0),o([t(n)],m.prototype,"clampRange",void 0);class h extends d{constructor(){super(...arguments),this.type="ConvolutionShader",this.rows=3,this.cols=3}_process(o){const{rows:t,cols:e}=this,r=new n(Math.floor(t/2),Math.floor(e/2)),{texture:s,srcImageSize:d}=this.config,m=new i(1).divide(d),{kernel:h}=this.convolutionConfig,g=l(h,{initialValue:new a(0,0,0,1),xRange:[0,t],yRange:[0,e],callback:(t,e,l,c)=>{const d=new n(new i(l),new i(c)).subtract(r).multiply(m),h=p(s,u(o.add(d))),g=h.rgb.multiply(e).add(t.rgb),f=h.a.multiply(t.a);return new a(g,f)}}),{clampRange:f}=this.convolutionConfig;return new a(c(g.rgb,f.x,f.y),1).multiply(g.a)}}o([e],h.prototype,"rows",void 0),o([e],h.prototype,"cols",void 0),o([t(m)],h.prototype,"convolutionConfig",void 0);export{h as ConvolutionShader};
|
package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/CurvatureShader.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as t}from"../../../../../../../../../chunks/tslib.es6.js";import{uniform as r,define as e,UniformGroup as s}from"../../../../GraphShaderModule.js";import{negate as i,dot as o,Vec3 as a,Vec4 as
|
|
5
|
+
import{_ as t}from"../../../../../../../../../chunks/tslib.es6.js";import{uniform as r,define as e,UniformGroup as s}from"../../../../GraphShaderModule.js";import{negate as i,dot as o,Vec3 as a,Vec4 as u,Float as d}from"../../../../graph/glsl.js";import{getSurfaceValues as p}from"../surface.js";import{BaseRasterProcessorShader as l}from"./BaseRasterProcessorShader.js";class c extends s{}t([r(d)],c.prototype,"zlFactor",void 0);class m extends l{constructor(){super(...arguments),this.type="CurvatureShader"}_process(t){const{texture:r}=this.config,e=p(r,t,this.config.srcImageSize),s=e[3].add(e[5]).multiply(.5).subtract(e[4]),d=e[1].add(e[7]).multiply(.5).subtract(e[4]),{zlFactor:l}=this.curvatureConfig,{curvatureType:c}=this;let m;if("standard"===c)m=i(l).multiply(s.add(d));else{const t=e[2].subtract(e[0]).add(e[6]).subtract(e[8]).divide(4),r=e[5].subtract(e[3]).divide(2),u=e[1].subtract(e[7]).divide(2),p=r.multiply(r),n=u.multiply(u),y=r.multiply(u),f=l.divide(p.add(n));m="profile"===c?o(new a(s,d,t),new a(p,n,y)).multiply(f):o(new a(s,d,i(t)),new a(n,p,y)).multiply(i(f))}return new u(m,m,m,e[9])}}t([e],m.prototype,"curvatureType",void 0),t([r(c)],m.prototype,"curvatureConfig",void 0);export{m as CurvatureShader};
|
package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/ExtractBandShader.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as t}from"../../../../../../../../../chunks/tslib.es6.js";import{uniform as r,UniformGroup as s}from"../../../../GraphShaderModule.js";import{Vec4 as e,Mat3 as o}from"../../../../graph/glsl.js";import{BaseRasterProcessorShader as a}from"./BaseRasterProcessorShader.js";class n extends s{}t([r(o)],n.prototype,"bandIndexMat3",void 0);class d extends a{_process(t){const r=this._getPixel(t),s=this.extractBandConfig.bandIndexMat3.multiply(r.rgb);return new e(s,r.a)}}t([r(n)],d.prototype,"extractBandConfig",void 0);export{d as ExtractBandShader};
|
|
5
|
+
import{_ as t}from"../../../../../../../../../chunks/tslib.es6.js";import{uniform as r,UniformGroup as s}from"../../../../GraphShaderModule.js";import{Vec4 as e,Mat3 as o}from"../../../../graph/glsl.js";import{BaseRasterProcessorShader as a}from"./BaseRasterProcessorShader.js";class n extends s{}t([r(o)],n.prototype,"bandIndexMat3",void 0);class d extends a{constructor(){super(...arguments),this.type="ExtractBandShader"}_process(t){const r=this._getPixel(t),s=this.extractBandConfig.bandIndexMat3.multiply(r.rgb);return new e(s,r.a)}}t([r(n)],d.prototype,"extractBandConfig",void 0);export{d as ExtractBandShader};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as t}from"../../../../../../../../../chunks/tslib.es6.js";import{uniform as e,define as r,UniformGroup as s}from"../../../../GraphShaderModule.js";import{step as a,Float as
|
|
5
|
+
import{_ as t}from"../../../../../../../../../chunks/tslib.es6.js";import{uniform as e,define as r,UniformGroup as s}from"../../../../GraphShaderModule.js";import{step as a,Float as o,mix as n,Vec4 as i,clamp as l,Vec2 as c,texture2D as u,sqrt as p,max as m,min as d,Int as w,block as b}from"../../../../graph/glsl.js";import{mirror as g}from"../surface.js";import{BaseRasterProcessorShader as h}from"./BaseRasterProcessorShader.js";import{invertValue as y}from"./math.js";class f extends s{}t([e(c)],f.prototype,"clampRange",void 0);class _ extends h{constructor(){super(...arguments),this.type="FocalStatisticsShader",this.rows=3,this.cols=3,this.fill=!1}_process(t){const e=this._process1(t),r=a(new o(1),e.a);if(!this.fill)return this._clamp(e.rgb,r);const s=this._getPixel(t),i=n(e.rgb,s.rgb,s.a);return this._clamp(i,r)}_clamp(t,e){const{clampRange:r}=this.focalStatisticsConfig;return new i(l(t,r.x,r.y),1).multiply(e)}_process1(t){const{texture:e,srcImageSize:r}=this.config,{rows:s,cols:a}=this,n=new c(Math.floor(s/2),Math.floor(a/2)),l=new o(1).divide(r),w=this._getPixel(t),{statisticsType:b}=this,h="min"===b||"max"===b?new i(w.rgb,0):new i(0,0,0,0);switch(b){case"min":return this._stat(s,a,h,((r,s,a)=>{const p=new c(new o(s),new o(a)).subtract(n).multiply(l),m=u(e,g(t.add(p))),w=d(r.rgb,m.rgb);return new i(w,r.a.add(m.a))}));case"max":return this._stat(s,a,h,((r,s,a)=>{const p=new c(new o(s),new o(a)).subtract(n).multiply(l),d=u(e,g(t.add(p))),w=m(r.rgb,d.rgb);return new i(w,r.a.add(d.a))}));case"mean":{const r=this._stat(s,a,h,((r,s,a)=>{const p=new c(new o(s),new o(a)).subtract(n).multiply(l),m=u(e,g(t.add(p))),d=r.rgb.add(m.rgb.multiply(m.a));return new i(d,r.a.add(m.a))})),p=r.rgb.multiply(y(r.a));return new i(p,r.a)}case"stddev":{const r=this._stat(s,a,h,((r,s,a)=>{const p=new c(new o(s),new o(a)).subtract(n).multiply(l),m=u(e,g(t.add(p))),d=r.rgb.add(m.rgb.multiply(m.a));return new i(d,r.a.add(m.a))})),m=this._stat(s,a,h,((r,s,a)=>{const p=new c(new o(s),new o(a)).subtract(n).multiply(l),m=u(e,g(t.add(p))),d=r.rgb.add(m.a.multiply(m.rgb).multiply(m.rgb));return new i(d,r.a.add(m.a))})),d=y(m.a),w=p(m.subtract(r.multiply(r).multiply(d)).multiply(d));return new i(w.rgb,r.a)}default:return w}}_stat(t=3,e=3,r,s){const a=new w(0).setMutable().setDebugName("StatColIterator"),o=new w(0).setMutable().setDebugName("StatRowIterator"),n=r.setMutable().setDebugName("StatAccumulator"),l=s(n,a,o).setDebugName("StatPredicate"),c=b({iterX:a,iterY:o,accumulator:n},i,l,(({out:r,iterX:s,iterY:a,accumulator:o,subgraph:n})=>`\n for (${a} = 0; ${a} < ${t}; ${a}++) {\n for (${s} = 0; ${s} < ${e}; ${s}++) {\n \n ${n.body}\n \n ${o} = ${n.varName};\n }\n }\n ${r} = ${o};\n `)).setDebugName("statBody");return c}}t([r],_.prototype,"rows",void 0),t([r],_.prototype,"cols",void 0),t([r],_.prototype,"statisticsType",void 0),t([r],_.prototype,"fill",void 0),t([e(f)],_.prototype,"focalStatisticsConfig",void 0);export{_ as FocalStatisticsShader};
|
package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/GrayscaleShader.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as s}from"../../../../../../../../../chunks/tslib.es6.js";import{uniform as r,UniformGroup as e}from"../../../../GraphShaderModule.js";import{dot as o,Vec4 as t,Vec3 as a}from"../../../../graph/glsl.js";import{BaseRasterProcessorShader as i}from"./BaseRasterProcessorShader.js";class p extends e{}s([r(a)],p.prototype,"weights",void 0);class
|
|
5
|
+
import{_ as s}from"../../../../../../../../../chunks/tslib.es6.js";import{uniform as r,UniformGroup as e}from"../../../../GraphShaderModule.js";import{dot as o,Vec4 as t,Vec3 as a}from"../../../../graph/glsl.js";import{BaseRasterProcessorShader as i}from"./BaseRasterProcessorShader.js";class p extends e{}s([r(a)],p.prototype,"weights",void 0);class c extends i{constructor(){super(...arguments),this.type="GrayscaleShader"}_process(s){const r=this._getPixel(s),{weights:e}=this.grayscaleConfig,a=o(e,r.rgb);return new t(a,a,a,r.a)}}s([r(p)],c.prototype,"grayscaleConfig",void 0);export{c as GrayscaleShader};
|
package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/HillshadeShader.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as s}from"../../../../../../../../../chunks/tslib.es6.js";import{define as i,uniform as r}from"../../../../GraphShaderModule.js";import{Vec4 as
|
|
5
|
+
import{_ as s}from"../../../../../../../../../chunks/tslib.es6.js";import{define as i,uniform as r}from"../../../../GraphShaderModule.js";import{Vec4 as t}from"../../../../graph/glsl.js";import{getSurfaceValues as o,hillshade as e,HillshadeConfig as l}from"../surface.js";import{BaseRasterProcessorShader as a}from"./BaseRasterProcessorShader.js";class h extends a{constructor(){super(...arguments),this.type="HillshadeShader",this.isMultidirectional=!1}_process(s){const{texture:i}=this.config,r=o(i,s,this.config.srcImageSize),l=e(r,this.hillshadeConfig,this.isMultidirectional);return new t(l.rgb.multiply(255),l.a)}}s([i],h.prototype,"isMultidirectional",void 0),s([r(l)],h.prototype,"hillshadeConfig",void 0);export{h as HillshadeShader};
|
package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/LocalShader.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as e}from"../../../../../../../../../chunks/tslib.es6.js";import{UniformGroup as a,uniform as s,define as
|
|
5
|
+
import{_ as e}from"../../../../../../../../../chunks/tslib.es6.js";import{UniformGroup as a,uniform as s,define as t}from"../../../../GraphShaderModule.js";import{Vec4 as n,float as r,equal as i,Float as o,notEqual as c,lessThanEqual as b,lessThan as l,greaterThanEqual as u,greaterThan as p,xor as w,or as k,and as h,bitXor as m,Int as d,bitNot as g,bitRShift as y,bitShift as _,bitOr as f,bitAnd as R,tanh as v,tan as x,sinh as A,sin as O,cosh as j,cos as q,atan as B,ifElse as T,atanh as Z,asinh as M,asin as N,acosh as S,acos as C,abs as V,negate as G,mod as L,sign as P,floor as z,ceil as D,pow as E,exp as F,log2 as H,log as I,sqrt as J,mix as K,Vec2 as Q}from"../../../../graph/glsl.js";import{BaseRasterProcessorShader as U}from"./BaseRasterProcessorShader.js";import{getRangeClipFactor as W,roundOutput as X,invertValue as Y}from"./math.js";import{MultiRasterMixin as $}from"./MultiRasterMixin.js";class ee extends a{}e([s(Q)],ee.prototype,"domainRange",void 0);class ae extends($(U)){constructor(){super(...arguments),this.type="LocalShader",this.isOutputRounded=!1}_process(e){if("conditional"===this.operationName)return this._conditional(e);const{a,b:s,alpha:t}=this._getRasterValues(e),{value:n,alpha:r}=this._compute(a,s,t);return this._processResult(n,r)}_processResult(e,a){const s=W(e,this.domainRangeConfig.domainRange),t=new n(e,e,e,a).multiply(s);return this.isOutputRounded?X(t):t}_compute(e,a,s){const{operationName:t}=this;let n;switch(t){case"plus":n=e.add(a);break;case"minus":n=e.subtract(a);break;case"times":n=e.multiply(a);break;case"divide":case"floatdivide":n=e.multiply(Y(a)),s=s.multiply(r(V(P(a))));break;case"floordivide":n=z(e.multiply(Y(a))),s=s.multiply(r(V(P(a))));break;case"square":n=e.multiply(e);break;case"sqrt":n=J(e);break;case"power":n=E(e,a);break;case"ln":n=T(p(e,new o(0)),I(e),new o(0)),s=s.multiply(this._isAboveZero(e));break;case"log10":n=T(p(e,new o(0)),H(e).multiply(Y(H(new o(10)))),new o(0)),s=s.multiply(this._isAboveZero(e));break;case"log2":n=T(p(e,new o(0)),H(e),new o(0)),s=s.multiply(this._isAboveZero(e));break;case"exp":n=F(e);break;case"exp10":n=E(new o(10),e);break;case"exp2":n=E(new o(2),e);break;case"rounddown":n=z(e);break;case"roundup":n=D(e);break;case"int":n=P(e).multiply(z(V(e)));break;case"mod":n=L(e,a);break;case"negate":n=G(e);break;case"abs":n=V(e);break;case"acos":{const a=this._isAbsBiggerThanOne(e);n=T(a,new o(0),C(e)),s=T(a,new o(0),s);break}case"acosh":n=S(e);break;case"asin":{const a=this._isAbsBiggerThanOne(e);n=T(a,new o(0),N(e)),s=T(a,new o(0),s);break}case"asinh":n=M(e);break;case"atan":n=B(e);break;case"atanh":{const a=this._isAbsBiggerThanOne(e);n=T(a,new o(0),Z(e)),s=T(a,new o(0),s);break}case"atan2":n=B(e,a);break;case"cos":n=q(e);break;case"cosh":n=j(e);break;case"sin":n=O(e);break;case"sinh":n=A(e);break;case"tan":n=x(e);break;case"tanh":n=v(e);break;case"bitwiseand":n=new o(R(new d(e),new d(a)));break;case"bitwiseor":n=new o(f(new d(e),new d(a)));break;case"bitwiseleftshift":n=new o(_(new d(e),new d(a)));break;case"bitwiserightshift":n=new o(y(new d(e),new d(a)));break;case"bitwisenot":n=new o(g(new d(e)));break;case"bitwisexor":n=new o(m(new d(e),new d(a)));break;case"booleanand":n=r(h(c(e,new o(0)),c(a,new o(0))));break;case"booleanor":n=r(k(c(e,new o(0)),c(a,new o(0))));break;case"booleannot":n=r(i(e,new o(0)));break;case"booleanxor":n=r(w(c(e,new o(0)),c(a,new o(0))));break;case"greaterthan":n=r(p(e,a));break;case"greaterthanequal":n=r(u(e,a));break;case"lessthan":n=r(l(e,a));break;case"lessthanequal":n=r(b(e,a));break;case"equalto":n=r(i(e,a));break;case"notequal":n=r(c(e,a));break;case"isnull":n=r(i(s,new o(0))),s=new o(1);break;case"setnull":{const t=r(i(e,new o(0)));n=t.multiply(a),s=s.multiply(t);break}default:n=e}return{value:n,alpha:s}}_conditional(e){const{a,b:s,c:t,alpha:n}=this._getRasterValues(e),r=new o(V(P(a))),i=K(t,s,r);return this._processResult(i,n)}_isAboveZero(e){return r(p(e,new o(0)))}_isAbsBiggerThanOne(e){return p(V(e),new o(1))}}e([t],ae.prototype,"operationName",void 0),e([t],ae.prototype,"isOutputRounded",void 0),e([s(ee)],ae.prototype,"domainRangeConfig",void 0);export{ee as DomainRangeConfig,ae as LocalShader};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as t}from"../../../../../../../../../chunks/tslib.es6.js";import{maxMapSizeGpu as o}from"../../../../../../../../../layers/support/rasterFunctions/pixelUtils.js";import{uniform as s,define as e,UniformGroup as r}from"../../../../GraphShaderModule.js";import{FixedArray as i,Float as a,Vec3 as l,abs as p,sign as n,step as u}from"../../../../graph/glsl.js";import{BaseRasterProcessorShader as c}from"./BaseRasterProcessorShader.js";class m extends r{}t([s(i.ofType(a,6))],m.prototype,"includedRanges",void 0),t([s(i.ofType(a,o))],m.prototype,"noDataValues",void 0);class y extends c{constructor(){super(...arguments),this.isMultiband=!0}_process(t){const o=this._getPixel(t),s=this._computeNoDataFactor(o.r),e=this._computeRangeFactor(o.rgb);let r;if(this.isMultiband){const t=this._computeNoDataFactor(o.g),i=this._computeNoDataFactor(o.b),a=new l(s,t,i).multiply(e);r=a.x.multiply(a.y).multiply(a.z)}else r=s.multiply(e.x);return o.multiply(r)}_computeNoDataFactor(t){const{noDataValues:s}=this.maskConfig;let e=new l(1);for(let r=0;r<o/3;r++){const o=3*r,i=new l(s[o+0],s[o+1],s[o+2]),a=p(n(i.subtract(t)));e=e.multiply(a)}return e.x.multiply(e.y).multiply(e.z)}_computeRangeFactor(t){const{includedRanges:o}=this.maskConfig,s=new l(o[0],o[2],o[4]),e=new l(o[1],o[3],o[5]);return u(s,t).multiply(u(t,e))}}t([e],y.prototype,"isMultiband",void 0),t([s(m)],y.prototype,"maskConfig",void 0);export{y as MaskShader};
|
|
5
|
+
import{_ as t}from"../../../../../../../../../chunks/tslib.es6.js";import{maxMapSizeGpu as o}from"../../../../../../../../../layers/support/rasterFunctions/pixelUtils.js";import{uniform as s,define as e,UniformGroup as r}from"../../../../GraphShaderModule.js";import{FixedArray as i,Float as a,Vec3 as l,abs as p,sign as n,step as u}from"../../../../graph/glsl.js";import{BaseRasterProcessorShader as c}from"./BaseRasterProcessorShader.js";class m extends r{}t([s(i.ofType(a,6))],m.prototype,"includedRanges",void 0),t([s(i.ofType(a,o))],m.prototype,"noDataValues",void 0);class y extends c{constructor(){super(...arguments),this.type="MaskShader",this.isMultiband=!0}_process(t){const o=this._getPixel(t),s=this._computeNoDataFactor(o.r),e=this._computeRangeFactor(o.rgb);let r;if(this.isMultiband){const t=this._computeNoDataFactor(o.g),i=this._computeNoDataFactor(o.b),a=new l(s,t,i).multiply(e);r=a.x.multiply(a.y).multiply(a.z)}else r=s.multiply(e.x);return o.multiply(r)}_computeNoDataFactor(t){const{noDataValues:s}=this.maskConfig;let e=new l(1);for(let r=0;r<o/3;r++){const o=3*r,i=new l(s[o+0],s[o+1],s[o+2]),a=p(n(i.subtract(t)));e=e.multiply(a)}return e.x.multiply(e.y).multiply(e.z)}_computeRangeFactor(t){const{includedRanges:o}=this.maskConfig,s=new l(o[0],o[2],o[4]),e=new l(o[1],o[3],o[5]);return u(s,t).multiply(u(t,e))}}t([e],y.prototype,"isMultiband",void 0),t([s(m)],y.prototype,"maskConfig",void 0);export{y as MaskShader};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as t}from"../../../../../../../../../chunks/tslib.es6.js";import{uniform as s,define as r,UniformGroup as
|
|
5
|
+
import{_ as t}from"../../../../../../../../../chunks/tslib.es6.js";import{uniform as s,define as r,UniformGroup as e}from"../../../../GraphShaderModule.js";import{Vec4 as o,floor as a,Mat3 as i}from"../../../../graph/glsl.js";import{BaseRasterProcessorShader as d}from"./BaseRasterProcessorShader.js";import{invertValue as p}from"./math.js";class n extends e{}t([s(i)],n.prototype,"bandIndexMat3",void 0);class l extends d{constructor(){super(...arguments),this.type="NDVIShader",this.scaled=!0}_process(t){const s=this._getPixel(t),{r,g:e}=this.ndviConfig.bandIndexMat3.multiply(s.rgb),i=r.subtract(e),d=r.add(e),n=i.multiply(p(d));if(!this.scaled)return new o(n,n,n,s.a);const l=a(n.multiply(100).add(100.5));return new o(l,l,l,s.a)}}t([r],l.prototype,"scaled",void 0),t([s(n)],l.prototype,"ndviConfig",void 0);export{l as NDVIShader};
|
package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/RemapShader.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as e}from"../../../../../../../../../chunks/tslib.es6.js";import{maxMapSizeGpu as t}from"../../../../../../../../../layers/support/rasterFunctions/pixelUtils.js";import{uniform as o,define as a,UniformGroup as r}from"../../../../GraphShaderModule.js";import{FixedArray as p,Float as s,mix as n,clamp as l,max as i,Vec4 as m,Vec3 as c,step as u,sign as d,dot as y,Vec2 as h}from"../../../../graph/glsl.js";import{oneMinus as f}from"../../utils.js";import{BaseRasterProcessorShader as g}from"./BaseRasterProcessorShader.js";class w extends r{}e([o(p.ofType(s,3*t))],w.prototype,"rangeMaps",void 0),e([o(p.ofType(s,2*t))],w.prototype,"noDataRanges",void 0),e([o(s)],w.prototype,"unmatchMask",void 0),e([o(s)],w.prototype,"replacementValue",void 0),e([o(h)],w.prototype,"clampRange",void 0);class M extends g{_process(e){const t=this._getPixel(e),{rrr:o}=t,{mapValue:a,includeMask:r}=this._computeMapValue(o),{unmatchMask:p,clampRange:s,replacementValue:c}=this.remapConfig,u=this.replaceUnmatched?c:p.multiply(t.r),d=n(u,a,r),y=l(d,s.x,s.y),h=this._computeNoDataFactor(o).multiply(i(p,r));return new m(y,y,y,t.a).multiply(h)}_computeMapValue(e){const{rangeMaps:o}=this.remapConfig;let a=new c(0,0,0),r=new s(0);for(let p=0;p<t/3;p++){const t=9*p,s=new c(o[t],o[t+3],o[t+6]),l=new c(o[t+1],o[t+4],o[t+7]),i=u(s,e).multiply(u(e,l)),m=new c(o[t+2],o[t+5],o[t+8]);r=n(r,m.x,i.x),r=n(r,m.y,i.y),r=n(r,m.z,i.z),a=a.add(i)}return{mapValue:r,includeMask:d(y(a,new c(1,1,1)))}}_computeNoDataFactor(e){const{noDataRanges:o}=this.remapConfig;let a=new c(0,0,0);for(let r=0;r<t/3;r++){const t=6*r,p=new c(o[t],o[t+2],o[t+4]),s=new c(o[t+1],o[t+3],o[t+5]);a=a.add(u(p,e).multiply(u(e,s)))}return f(d(y(a,new c(1,1,1))))}}e([o(w)],M.prototype,"remapConfig",void 0),e([a],M.prototype,"replaceUnmatched",void 0);export{M as RemapShader};
|
|
5
|
+
import{_ as e}from"../../../../../../../../../chunks/tslib.es6.js";import{maxMapSizeGpu as t}from"../../../../../../../../../layers/support/rasterFunctions/pixelUtils.js";import{uniform as o,define as a,UniformGroup as r}from"../../../../GraphShaderModule.js";import{FixedArray as p,Float as s,mix as n,clamp as l,max as i,Vec4 as m,Vec3 as c,step as u,sign as d,dot as y,Vec2 as h}from"../../../../graph/glsl.js";import{oneMinus as f}from"../../utils.js";import{BaseRasterProcessorShader as g}from"./BaseRasterProcessorShader.js";class w extends r{}e([o(p.ofType(s,3*t))],w.prototype,"rangeMaps",void 0),e([o(p.ofType(s,2*t))],w.prototype,"noDataRanges",void 0),e([o(s)],w.prototype,"unmatchMask",void 0),e([o(s)],w.prototype,"replacementValue",void 0),e([o(h)],w.prototype,"clampRange",void 0);class M extends g{constructor(){super(...arguments),this.type="RemapShader"}_process(e){const t=this._getPixel(e),{rrr:o}=t,{mapValue:a,includeMask:r}=this._computeMapValue(o),{unmatchMask:p,clampRange:s,replacementValue:c}=this.remapConfig,u=this.replaceUnmatched?c:p.multiply(t.r),d=n(u,a,r),y=l(d,s.x,s.y),h=this._computeNoDataFactor(o).multiply(i(p,r));return new m(y,y,y,t.a).multiply(h)}_computeMapValue(e){const{rangeMaps:o}=this.remapConfig;let a=new c(0,0,0),r=new s(0);for(let p=0;p<t/3;p++){const t=9*p,s=new c(o[t],o[t+3],o[t+6]),l=new c(o[t+1],o[t+4],o[t+7]),i=u(s,e).multiply(u(e,l)),m=new c(o[t+2],o[t+5],o[t+8]);r=n(r,m.x,i.x),r=n(r,m.y,i.y),r=n(r,m.z,i.z),a=a.add(i)}return{mapValue:r,includeMask:d(y(a,new c(1,1,1)))}}_computeNoDataFactor(e){const{noDataRanges:o}=this.remapConfig;let a=new c(0,0,0);for(let r=0;r<t/3;r++){const t=6*r,p=new c(o[t],o[t+2],o[t+4]),s=new c(o[t+1],o[t+3],o[t+5]);a=a.add(u(p,e).multiply(u(e,s)))}return f(d(y(a,new c(1,1,1))))}}e([o(w)],M.prototype,"remapConfig",void 0),e([a],M.prototype,"replaceUnmatched",void 0);export{M as RemapShader};
|
package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/ReprojectShader.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{BaseRasterColorizerShader as e}from"../BaseRasterColorizerShader.js";class r extends e{_colorize(e){return this._getPixel(e)}}export{r as ReprojectShader};
|
|
5
|
+
import{BaseRasterColorizerShader as e}from"../BaseRasterColorizerShader.js";class r extends e{constructor(){super(...arguments),this.type="ReprojectShader"}_colorize(e){return this._getPixel(e)}}export{r as ReprojectShader};
|
package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/ShadedReliefShader.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as
|
|
5
|
+
import{_ as r}from"../../../../../../../../../chunks/tslib.es6.js";import{uniform as e}from"../../../../GraphShaderModule.js";import{clamp as o,Float as s,Vec4 as t,Vec3 as i}from"../../../../graph/glsl.js";import{rgb2hsv as l,hsv2rgb as p}from"../colorConversion.js";import{lookupColor as a,ColormapConfig as m}from"../lut.js";import{HillshadeShader as n}from"./HillshadeShader.js";class d extends n{constructor(){super(...arguments),this.type="ShadedReliefShader"}_process(r){const e=super._process(r),{minValue:m,maxValue:n}=this.hillshadeConfig,d=this._getPixel(r),h=n.subtract(m),u=d.r.subtract(m),c=o(u.divide(h),new s(0),new s(1)),f=a(new t(c,c,c,1),new s(255),this.colormapConfig),x=l(f.xyz),g=p(new i(x.xy,e.x.divide(255))).multiply(255);return new t(g,f.a.multiply(e.a))}}r([e(m)],d.prototype,"colormapConfig",void 0);export{d as ShadedReliefShader};
|
package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/SlopeShader.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as e}from"../../../../../../../../../chunks/tslib.es6.js";import{uniform as t,define as o,UniformGroup as i}from"../../../../GraphShaderModule.js";import{pow as r,Vec2 as p,sqrt as s,atan as l,Vec4 as d,Float as u}from"../../../../graph/glsl.js";import{getSurfaceValues as c,computeDeltaZ as m}from"../surface.js";import{BaseRasterProcessorShader as a}from"./BaseRasterProcessorShader.js";import{roundOutput as n}from"./math.js";class
|
|
5
|
+
import{_ as e}from"../../../../../../../../../chunks/tslib.es6.js";import{uniform as t,define as o,UniformGroup as i}from"../../../../GraphShaderModule.js";import{pow as r,Vec2 as p,sqrt as s,atan as l,Vec4 as d,Float as u}from"../../../../graph/glsl.js";import{getSurfaceValues as c,computeDeltaZ as m}from"../surface.js";import{BaseRasterProcessorShader as a}from"./BaseRasterProcessorShader.js";import{roundOutput as n}from"./math.js";class h extends i{}e([t(u)],h.prototype,"pixelSizePower",void 0),e([t(u)],h.prototype,"pixelSizeFactor",void 0),e([t(u)],h.prototype,"zFactor",void 0),e([t(p)],h.prototype,"cellSize",void 0);class y extends a{constructor(){super(...arguments),this.type="SlopeShader",this.isOutputRounded=!1,this.percentRise=!1}_process(e){const{cellSize:t,pixelSizePower:o,pixelSizeFactor:i,zFactor:u}=this.slopeConfig,a=r(t,new p(o)).multiply(i).add(u).divide(t.multiply(8)),{texture:h}=this.config,y=c(h,e,this.config.srcImageSize),{x:f,y:S}=m(y,a),x=s(f.multiply(f).add(S.multiply(S))),z=this.percentRise?x.multiply(100):l(x).multiply(57.2957795),v=new d(z,z,z,y[9]);return this.isOutputRounded?n(v):v}}e([o],y.prototype,"isOutputRounded",void 0),e([o],y.prototype,"percentRise",void 0),e([t(h)],y.prototype,"slopeConfig",void 0);export{y as SlopeShader};
|
package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/StretchShader.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as t}from"../../../../../../../../../chunks/tslib.es6.js";import{define as s,uniform as
|
|
5
|
+
import{_ as t}from"../../../../../../../../../chunks/tslib.es6.js";import{define as s,uniform as r}from"../../../../GraphShaderModule.js";import{Vec4 as o}from"../../../../graph/glsl.js";import{stretch as e,StretchConfig as i}from"../stretch.js";import{BaseRasterProcessorShader as p}from"./BaseRasterProcessorShader.js";import{roundOutput as a}from"./math.js";class h extends p{constructor(){super(...arguments),this.type="StretchShader",this.isMultiband=!0,this.isOutputRounded=!1,this.useGamma=!1}_process(t){const s=this._getPixel(t);let r=e(s,this.stretchConfig,this.useGamma,1);return this.isMultiband||(r=new o(r.rrr,r.a)),this.isOutputRounded?a(r):r}}t([s],h.prototype,"isMultiband",void 0),t([s],h.prototype,"isOutputRounded",void 0),t([s],h.prototype,"useGamma",void 0),t([r(i)],h.prototype,"stretchConfig",void 0);export{h as StretchShader};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{_ as t,a as e}from"../../../../../../../chunks/tslib.es6.js";import{minMaxZoomPrecisionFactor as i,labelPlacementOffsetPadding as o}from"../../../definitions.js";import{location as s,option as l,uniform as a,define as r,ComputeVertexInput as n,input as p}from"../../GraphShaderModule.js";import{abs as d,min as u,Float as y,floor as m,step as c,Vec3 as
|
|
5
|
+
import{_ as t,a as e}from"../../../../../../../chunks/tslib.es6.js";import{minMaxZoomPrecisionFactor as i,labelPlacementOffsetPadding as o}from"../../../definitions.js";import{location as s,option as l,uniform as a,define as r,ComputeVertexInput as n,input as p}from"../../GraphShaderModule.js";import{abs as d,min as u,Float as y,floor as m,step as c,Vec3 as h,Mat3 as f,Vec2 as v,ifElse as w,equal as b,or as x,lessThanEqual as V,greaterThan as S,Bool as g,Vec4 as z,texture2D as j,smoothstep as R,Int as C,bitRShift as O,bitAnd as M}from"../../graph/glsl.js";import{FeatureVertexInput as L,FeatureFragmentInput as A,AFeatureShader as H}from"../shaders/AFeatureShader.js";import{bitsetTextIsBackground as P,sdfFontSize as N,bitsetTextIsMapAligned as U,maxSdfDistance as T}from"../shaders/constants.js";import{distPointTriangle as _,failHittest as k}from"../shaders/hittestUtils.js";import{MosaicInfo as I}from"../shaders/MosaicInfo.js";import{getBit as D}from"../shaders/utils.js";import{VisualVariableColor as B}from"../shaders/VisualVariableColor.js";import{VisualVariableOpacity as q}from"../shaders/VisualVariableOpacity.js";import{VisualVariableRotation as E}from"../shaders/VisualVariableRotation.js";import{VisualVariableSizeMinMaxValue as F}from"../shaders/VisualVariableSizeMinMaxValue.js";import{VisualVariableSizeScaleStops as W}from"../shaders/VisualVariableSizeScaleStops.js";import{VisualVariableSizeStops as G}from"../shaders/VisualVariableSizeStops.js";import{VisualVariableSizeUnitValue as Z}from"../shaders/VisualVariableSizeUnitValue.js";import{getVisualVariableSize as J,getVisualVariableRotation as K}from"../shaders/vvUtils.js";const Q=360/254;var X;!function(t){t[t.Color=0]="Color",t[t.Outline=1]="Outline",t[t.Halo=2]="Halo"}(X||(X={}));class Y extends L{}t([s(3,z)],Y.prototype,"color",void 0),t([s(4,v)],Y.prototype,"offset",void 0),t([s(5,v)],Y.prototype,"textureUV",void 0),t([s(6,y)],Y.prototype,"fontSize",void 0),t([s(7,y)],Y.prototype,"referenceSize",void 0),t([s(8,z)],Y.prototype,"outlineColor",void 0),t([s(9,z)],Y.prototype,"haloColor",void 0),t([s(10,v)],Y.prototype,"outlineAndHaloSize",void 0),t([s(11,v)],Y.prototype,"zoomRange",void 0),t([s(12,y)],Y.prototype,"clipAngle",void 0),t([s(13,z)],Y.prototype,"referenceSymbol",void 0);class $ extends n{}t([s(14,v)],$.prototype,"offsetNextVertex1",void 0),t([s(15,v)],$.prototype,"offsetNextVertex2",void 0);class tt extends A{}class et extends H{constructor(){super(...arguments),this.type="TextShader",this.computeAttributes={offset:["offsetNextVertex1","offsetNextVertex2"]},this.textRenderPassType=X.Color,this.isBackgroundPass=!1,this.isLabel=!1}clipLabel(t,e,o){const s=e.multiply(Q),l=d(this.view.rotation.subtract(s)),a=u(new y(360).subtract(l),l);let r=new y(0);const n=m(this.view.currentZoom.multiply(i)).divide(i),p=t.x,h=t.y,f=new y(1).subtract(c(p,n)).multiply(2),v=c(new y(90),a).multiply(2),w=new y(2).multiply(new y(1).subtract(c(n,h)));return r=r.add(o.multiply(f)),r=r.add(o.multiply(v)),r=r.add(w),r}vertex(t,e){const i=D(t.bitset,P),s=new y(1).subtract(i);let l=t.fontSize,a=l.divide(N);const r=this.textRenderPassType===X.Outline?t.outlineColor:this.textRenderPassType===X.Halo?t.haloColor:this._getVertexColor(t),n=this.isLabel?this.storage.getLabelVisibility(t.id):new y(1),p=this.isLabel?r.multiply(n):r,d=this.view.displayViewScreenMat3.multiply(new h(t.pos,1));let u=t.offset,m=new y(1),c=f.identity(),j=new v(0);if(this.isLabel){if(!t.referenceSymbol)throw new Error("InternalError: Optional attribute 'referenceSymbol' expected for labels");const e=t.referenceSymbol,i=e.xy,s=e.z,l=this._unpackDirection(e.w),a=J(this,t.id,s).divide(2),r=l.multiply(a.add(o));j=i.add(r),u=u.add(j)}else{m=J(this,t.id,t.referenceSize).divide(t.referenceSize),l=l.multiply(m),a=a.multiply(m),u=u.multiply(m),c=K(this,t.id),u=c.multiply(new h(u,0)).xy}const R=D(t.bitset,U),C=this._getViewRotationMatrix(R).multiply(new h(u,0));let O=this.isLabel?this.clipLabel(t.zoomRange,t.clipAngle,R):this.clip(t.id,t.zoomRange);O=this.isBackgroundPass?O.add(s.multiply(2)):O.add(i.multiply(2));let M=new y(0);if(this.textRenderPassType===X.Outline){O=O.add(w(b(t.outlineAndHaloSize.x,new y(0)),new y(2),new y(0)));M=new y(t.outlineAndHaloSize.x).divide(a).divide(T)}if(this.textRenderPassType===X.Halo){const e=t.outlineAndHaloSize.x,i=new y(t.outlineAndHaloSize.y);O=O.add(w(b(i,new y(0)),new y(2),new y(0)));M=i.add(e).divide(a).divide(T)}const L=this.isLabel?x(S(O,new y(1)),V(n,new y(0))):new g(!1);return{glPosition:new z(d.xy.add(C.xy),O,1),color:p,size:a,textureUV:t.textureUV.divide(this.mosaicInfo.size),antialiasingWidth:new y(.105*N).divide(l).divide(this.view.pixelRatio),outlineDistanceOffset:M,...this.maybeRunHittest(t,e,{vvSizeAdjustment:m,vvRotation:c,labelOffset:j,labelClipped:L})}}_getViewRotationMatrix(t){const e=this.view.displayViewMat3,i=this.view.displayMat3,o=new y(1).subtract(t);return e.multiply(t).add(i.multiply(o))}fragment(t){const e=new y(2/8),i=new y(1).subtract(e),o=j(this.mosaicInfo.texture,t.textureUV).a;let s=i.subtract(t.outlineDistanceOffset);this.highlight&&(s=s.divide(2));const l=t.antialiasingWidth,a=R(s.subtract(l),s.add(l),o);return this.getFragmentOutput(t.color.multiply(a),t)}hittest(t,e,{vvSizeAdjustment:i,vvRotation:o,labelOffset:s,labelClipped:l}){let a,r,n;this.isLabel?(a=new h(t.offset.add(s),0),r=new h(e.offsetNextVertex1.add(s),0),n=new h(e.offsetNextVertex2.add(s),0)):(a=o.multiply(new h(t.offset.multiply(i),0)),r=o.multiply(new h(e.offsetNextVertex1.multiply(i),0)),n=o.multiply(new h(e.offsetNextVertex2.multiply(i),0)));const{viewMat3:p,tileMat3:d}=this.view,u=p.multiply(d).multiply(new h(t.pos,1)),y=u.add(d.multiply(a)).xy,m=u.add(d.multiply(r)).xy,c=u.add(d.multiply(n)).xy,f=_(this.hittestRequest.position,y.xy,m.xy,c.xy);return this.isLabel?w(l,k(this.hittestRequest),f):f}_unpackDirection(t){const e=new C(t),i=O(e,new C(2)),o=M(e,new C(3));return new v(new y(i).subtract(1),new y(o).subtract(1))}_getVertexColor(t){let e=t.color;if(this.visualVariableColor){const i=this.storage.getColorValue(t.id);e=this.visualVariableColor.getColor(i,t.color,new g(!1))}if(this.visualVariableOpacity){const i=this.storage.getOpacityValue(t.id),o=this.visualVariableOpacity.getOpacity(i);e=e.multiply(o)}return e}}t([l(B)],et.prototype,"visualVariableColor",void 0),t([l(q)],et.prototype,"visualVariableOpacity",void 0),t([l(E)],et.prototype,"visualVariableRotation",void 0),t([l(F)],et.prototype,"visualVariableSizeMinMaxValue",void 0),t([l(W)],et.prototype,"visualVariableSizeScaleStops",void 0),t([l(G)],et.prototype,"visualVariableSizeStops",void 0),t([l(Z)],et.prototype,"visualVariableSizeUnitValue",void 0),t([a(I)],et.prototype,"mosaicInfo",void 0),t([r],et.prototype,"textRenderPassType",void 0),t([r],et.prototype,"isBackgroundPass",void 0),t([r],et.prototype,"isLabel",void 0),t([e(0,p(Y)),e(1,p($))],et.prototype,"vertex",null),t([e(0,p(tt))],et.prototype,"fragment",null);export{tt as TextFragmentInput,X as TextRenderPassType,et as TextShader,Y as TextVertexInput};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/4.33/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import e from"../../../../core/Evented.js";import{i as t,g as r,h as i}from"../../../../chunks/vec32.js";import{create as s}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{a as n,c as o}from"../../../../chunks/vec42.js";import{fromValues as a,clone as l}from"../../../../core/libs/gl-matrix-2/factories/vec4f64.js";import{projectBuffer as h}from"../../../../geometry/projection/projectBuffer.js";import{expandWithBuffer as c}from"../../../../geometry/support/aaBoundingBox.js";import{newDoubleArray as d}from"../../../../geometry/support/DoubleArray.js";import{makeDehydratedPoint as
|
|
5
|
+
import e from"../../../../core/Evented.js";import{i as t,g as r,h as i}from"../../../../chunks/vec32.js";import{create as s}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{a as n,c as o}from"../../../../chunks/vec42.js";import{fromValues as a,clone as l}from"../../../../core/libs/gl-matrix-2/factories/vec4f64.js";import{projectBuffer as h}from"../../../../geometry/projection/projectBuffer.js";import{expandWithBuffer as c}from"../../../../geometry/support/aaBoundingBox.js";import{newDoubleArray as d}from"../../../../geometry/support/DoubleArray.js";import{makeDehydratedPoint as p}from"../../../../layers/graphics/dehydratedPoint.js";import{getGeometryEffectiveElevationMode as m}from"../../../../support/elevationInfoUtils.js";import u from"../../../../symbols/support/ElevationInfo.js";import{EngineVisualElement as _}from"./EngineVisualElement.js";import{LaserlineVisualElement as f}from"./LaserlineVisualElement.js";import{ElevationContext as g}from"../../layers/graphics/ElevationContext.js";import{createGeometry as y}from"../../support/engineContent/line.js";import{geometryToRenderInfoDraped as O,geometryToRenderInfo as C}from"../../support/renderInfoUtils/line.js";import{RenderOccludedFlag as v}from"../../webgl-engine/lib/Material.js";import{RenderGeometry as b}from"../../webgl-engine/lib/RenderGeometry.js";import{VertexAttribute as w}from"../../webgl-engine/lib/VertexAttribute.js";import{RibbonLineMaterial as R}from"../../webgl-engine/materials/RibbonLineMaterial.js";class j extends _{constructor(t){super(t),this._attachmentOrigin=p(0,0,0,null),this._attachmentOriginDirty=!0,this.events=new e,this._geometry=null,this._width=1,this._color=a(1,0,1,1),this._innerWidth=0,this._innerColor=a(1,1,1,1),this._stipplePattern=null,this._stippleOffColor=null,this._falloff=0,this._elevationInfo=null,this._laserlineStyle=null,this._laserlineEnabled=!1,this._renderOccluded=v.OccludeAndTransparentStencil,this._attachmentOrigin.spatialReference=t.view.spatialReference,this._laserline=new f({view:t.view,isDecoration:t.isDecoration}),this.applyProperties(t),this.attached=t.attached??!0}destroy(){this._laserline.destroy(),super.destroy()}createObject3DResourceFactory(e){return{view:e,createResources:e=>this._createObject3DResources(e),destroyResources:D,recreateGeometry:(e,t)=>{e.geometries.length=0,this._recreateGeometry(t,e.material,e.geometries)}}}createDrapedResourceFactory(e){return{view:e,createResources:()=>this._createDrapedResources(),destroyResources:D,recreateGeometry:e=>{e.geometries=this._createRenderGeometriesDraped(e.material),this._attachmentOriginChanged()}}}get _laserlineAttached(){return this.attached&&this.visible&&null!=this._laserlineStyle&&!this.isDraped&&this.laserlineEnabled}onAttachedChange(e){this._laserline.attached=this._laserlineAttached,e&&this._attachmentOriginChanged()}get geometry(){return this._geometry}set geometry(e){const t=this._isClosed;this._geometry=e,this.recreateGeometry(),t!==this._isClosed&&this._updateMaterial()}get width(){return this._width}set width(e){e!==this._width&&(this._width=e,this._updateMaterial())}get color(){return this._color}set color(e){n(e,this._color)||(o(this._color,e),this._updateMaterial())}get innerWidth(){return this._innerWidth}set innerWidth(e){e!==this._innerWidth&&(this._innerWidth=e,this._updateMaterial())}get innerColor(){return this._innerColor}set innerColor(e){n(e,this._innerColor)||(o(this._innerColor,e),this._updateMaterial())}get stipplePattern(){return this._stipplePattern}set stipplePattern(e){const t=null!=e!=(null!=this._stipplePattern);this._stipplePattern=e,t?this.recreate():this._updateMaterial()}get stippleOffColor(){return this._stippleOffColor}set stippleOffColor(e){e&&this._stippleOffColor&&n(e,this._stippleOffColor)||(this._stippleOffColor=e?l(e):null,this._updateMaterial())}get falloff(){return this._falloff}set falloff(e){e!==this._falloff&&(this._falloff=e,this._updateMaterial())}get elevationInfo(){return this._elevationInfo}set elevationInfo(e){this._elevationInfo=e,this.recreateGeometry()}get laserlineStyle(){return this._laserlineStyle}set laserlineStyle(e){this._laserlineStyle=e,this._laserline.attached=this._laserlineAttached,null!=e&&(this._laserline.style=e)}get laserlineEnabled(){return this._laserlineEnabled}set laserlineEnabled(e){this._laserlineEnabled!==e&&(this._laserlineEnabled=e,this._laserline.attached=this._laserlineAttached)}get renderOccluded(){return this._renderOccluded}set renderOccluded(e){e!==this._renderOccluded&&(this._renderOccluded=e,this._updateMaterial())}get attachmentOrigin(){if(!this._attachmentOriginDirty)return this._attachmentOrigin;const e=this.object3dResources.resources?.geometries;if(!e||0===e.length)return null;t(E,0,0,0);let s=0;for(const t of e)t.computeAttachmentOrigin(P)&&(r(E,E,P),s++);return 0===s?null:(i(E,E,1/s),this.view.renderCoordsHelper.fromRenderCoords(E,this._attachmentOrigin),this._attachmentOriginDirty=!1,this._attachmentOrigin)}_updateMaterial(){this.object3dResources.resources?.material.setParameters(this._materialParameters),this.drapedResources.resources?.material.setParameters(this._materialParameters)}get _isClosed(){return null!=this.geometry&&"polygon"===this.geometry.type}get _materialParameters(){return{width:this._width,color:this._color,stippleOffColor:this._stippleOffColor,stipplePattern:this._stipplePattern,stipplePreferContinuous:!1,isClosed:this._isClosed,falloff:this._falloff,innerColor:this._innerColor,innerWidth:this._innerWidth,join:"round",hasPolygonOffset:!0,renderOccluded:this._normalizedRenderOccluded,isDecoration:this.isDecoration}}get _normalizedRenderOccluded(){return this.isDraped&&this._renderOccluded===v.OccludeAndTransparentStencil?v.OccludeAndTransparent:this._renderOccluded}_recreateGeometry(e,t,r){this._createRenderGeometries(t,r);for(const i of r)e.addGeometry(i);this._attachmentOriginChanged()}_attachmentOriginChanged(){this._attachmentOriginDirty=!0,this.events.emit("attachment-origin-changed")}_createObject3DResources(e){const t=new R(this._materialParameters),r=new Array;return this._recreateGeometry(e,t,r),{material:t,geometries:r,forEach:e=>{e(t),r.forEach(e)}}}_createDrapedResources(){const e=new R(this._materialParameters);return{material:e,geometries:this._createRenderGeometriesDraped(e)}}_createRenderGeometriesDraped(e){const{geometry:t,view:r}=this,i=r.basemapTerrain.spatialReference;if(null==t||null==i)return[];return O(t,i).lines.map((({position:t})=>{const s={overlayInfo:{spatialReference:i,renderCoordsHelper:r.renderCoordsHelper},attributeData:{position:t},removeDuplicateStartEnd:this._isClosed};return new b(y(e,s))}))}calculateMapBounds(e){if(null==this.object3dResources.resources)return!1;const t=this.view.renderCoordsHelper;for(const r of this.object3dResources.resources.geometries){const i=r.attributes.get(w.POSITION),s=d(i.data.length);h(i.data,t.spatialReference,0,s,this.view.spatialReference,0),c(e,s)}return!0}_createRenderGeometries(e,t){const r=this.geometry;if(null==r)return;const i=C(r,this.view.elevationProvider,this.view.renderCoordsHelper,g.fromElevationInfo(this.elevationInfo??new u({mode:m(r,null)}))),s=new Array;for(const{position:n,mapPositions:o}of i.lines){const r={mapPositions:o,attributeData:{position:n},removeDuplicateStartEnd:this._isClosed};t.push(y(e,r)),s.push(n)}this._laserline.pathVerticalPlane=s}}function D(e){e.geometries=[]}const P=s(),E=s();export{j as OutlineVisualElement};
|