@webviz/subsurface-viewer 1.15.13 → 1.16.1

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.
Files changed (29) hide show
  1. package/dist/layers/utils/layerTools.d.ts +9 -4
  2. package/dist/layers/utils/layerTools.js +11 -0
  3. package/dist/layers/utils/layerTools.js.map +1 -1
  4. package/dist/layers/wells/layers/dashedSectionsPathLayer.d.ts +3990 -0
  5. package/dist/layers/wells/layers/dashedSectionsPathLayer.js +248 -0
  6. package/dist/layers/wells/layers/dashedSectionsPathLayer.js.map +1 -0
  7. package/dist/layers/wells/layers/flatWellMarkersLayer.d.ts +68 -0
  8. package/dist/layers/wells/layers/flatWellMarkersLayer.js +223 -0
  9. package/dist/layers/wells/layers/flatWellMarkersLayer.js.map +1 -0
  10. package/dist/layers/wells/types.d.ts +26 -0
  11. package/dist/layers/wells/utils/markers.d.ts +13 -0
  12. package/dist/layers/wells/utils/markers.js +73 -0
  13. package/dist/layers/wells/utils/markers.js.map +1 -0
  14. package/dist/layers/wells/utils/readout.d.ts +16 -0
  15. package/dist/layers/wells/utils/readout.js +33 -0
  16. package/dist/layers/wells/utils/readout.js.map +1 -0
  17. package/dist/layers/wells/utils/trajectory.d.ts +41 -2
  18. package/dist/layers/wells/utils/trajectory.js +173 -4
  19. package/dist/layers/wells/utils/trajectory.js.map +1 -1
  20. package/dist/layers/wells/wellsLayer.d.ts +55 -4
  21. package/dist/layers/wells/wellsLayer.js +325 -30
  22. package/dist/layers/wells/wellsLayer.js.map +1 -1
  23. package/dist/utils/Color.d.ts +7 -0
  24. package/dist/utils/Color.js +20 -0
  25. package/dist/utils/Color.js.map +1 -1
  26. package/dist/utils/measurement.d.ts +8 -0
  27. package/dist/utils/measurement.js +10 -0
  28. package/dist/utils/measurement.js.map +1 -1
  29. package/package.json +11 -10
@@ -0,0 +1,73 @@
1
+ import { rotate } from "../../map/utils";
2
+ const PERFORATION_WIDTH = 1.5;
3
+ const PERFORATION_OFFSET = 7;
4
+ const PERFORATION_HEIGHT = 18;
5
+ const SCREEN_HEIGHT = 10;
6
+ const SCREEN_INDENT = 3;
7
+ /**
8
+ * Returns two-dimensional geometry positions for different types of trajectory markers.
9
+ *
10
+ * **Note:** If a 3D anchor point is provided, the returned geometry will include the anchor's Z position for *each
11
+ * point*. The resulting geometry is a object in 3D space that lays flat on the XY-plane
12
+ * @param markerType The marker type to build
13
+ * @param anchorPoint The world position to place the anchor at
14
+ * @param angle The angle of the marker
15
+ * @returns A GeoJson geometry object
16
+ */
17
+ export function buildMarkerPath2D(markerType, anchorPoint, angle) {
18
+ switch (markerType) {
19
+ case "perforation":
20
+ return buildPerforationTrianglePolygonCoordinates(anchorPoint, angle);
21
+ case "screen-start":
22
+ return buildScreenMarkerLineCoordinates2D(anchorPoint, angle, "start");
23
+ case "screen-end":
24
+ return buildScreenMarkerLineCoordinates2D(anchorPoint, angle, "end");
25
+ default:
26
+ throw new Error(`Unknown marker type: ${markerType}`);
27
+ }
28
+ }
29
+ function getRotatedPoint2D(point, pivotPoint, rotation) {
30
+ return rotate(point[0], point[1], pivotPoint[0], pivotPoint[1], rotation);
31
+ }
32
+ function buildPerforationTrianglePolygonCoordinates(anchorPoint, rotation) {
33
+ const point1 = [
34
+ anchorPoint[0],
35
+ anchorPoint[1] + (PERFORATION_HEIGHT + PERFORATION_OFFSET),
36
+ ];
37
+ const point2 = [
38
+ anchorPoint[0] - PERFORATION_WIDTH,
39
+ anchorPoint[1] + PERFORATION_OFFSET,
40
+ ];
41
+ const point3 = [
42
+ anchorPoint[0] + PERFORATION_WIDTH,
43
+ anchorPoint[1] + PERFORATION_OFFSET,
44
+ ];
45
+ const rotatedPoint1 = getRotatedPoint2D(point1, anchorPoint, rotation);
46
+ const rotatedPoint2 = getRotatedPoint2D(point2, anchorPoint, rotation);
47
+ const rotatedPoint3 = getRotatedPoint2D(point3, anchorPoint, rotation);
48
+ // Keep the z coordinate the same so the marker still follows the path if this happens to be used in 3d (the marker will look "flat")
49
+ rotatedPoint1.push(anchorPoint[2]);
50
+ rotatedPoint2.push(anchorPoint[2]);
51
+ rotatedPoint3.push(anchorPoint[2]);
52
+ return [rotatedPoint1, rotatedPoint2, rotatedPoint3, rotatedPoint1];
53
+ }
54
+ function buildScreenMarkerLineCoordinates2D(anchorPoint, rotation, type) {
55
+ if (type === "end")
56
+ rotation += Math.PI;
57
+ const pointCenter = [...anchorPoint];
58
+ const pointAbove = [
59
+ anchorPoint[0] + SCREEN_INDENT,
60
+ anchorPoint[1] + SCREEN_HEIGHT,
61
+ ];
62
+ const pointBelow = [
63
+ anchorPoint[0] + SCREEN_INDENT,
64
+ anchorPoint[1] - SCREEN_HEIGHT,
65
+ ];
66
+ const rotatedPointAbove = getRotatedPoint2D(pointAbove, anchorPoint, rotation);
67
+ const rotatedPointBelow = getRotatedPoint2D(pointBelow, anchorPoint, rotation);
68
+ // Keep the z coordinate the same so the marker still follows the path if this happens to be used in 3d (the marker will look "flat")
69
+ rotatedPointAbove.push(anchorPoint[2]);
70
+ rotatedPointBelow.push(anchorPoint[2]);
71
+ return [rotatedPointAbove, pointCenter, rotatedPointBelow];
72
+ }
73
+ //# sourceMappingURL=markers.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"markers.js","sourceRoot":"","sources":["../../../../src/layers/wells/utils/markers.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,MAAM,EAAE,MAAM,iBAAiB,CAAC;AAIzC,MAAM,iBAAiB,GAAG,GAAG,CAAC;AAC9B,MAAM,kBAAkB,GAAG,CAAC,CAAC;AAC7B,MAAM,kBAAkB,GAAG,EAAE,CAAC;AAE9B,MAAM,aAAa,GAAG,EAAE,CAAC;AACzB,MAAM,aAAa,GAAG,CAAC,CAAC;AAExB;;;;;;;;;GASG;AACH,MAAM,UAAU,iBAAiB,CAC7B,UAAsB,EACtB,WAAqB,EACrB,KAAa;IAEb,QAAQ,UAAU,EAAE,CAAC;QACjB,KAAK,aAAa;YACd,OAAO,0CAA0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IAAI,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC;IACnC,aAAa,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC;IACnC,aAAa,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC;IAEnC,OAAO,CAAC,aAAa,EAAE,aAAa,EAAE,aAAa,EAAE,aAAa,CAAC,CAAC;AACxE,CAAC;AAED,SAAS,kCAAkC,CACvC,WAAqB,EACrB,QAAgB,EAChB,IAAqB;IAErB,IAAI,IAAI,KAAK,KAAK;QAAE,QAAQ,IAAI,IAAI,CAAC,EAAE,CAAC;IAExC,MAAM,WAAW,GAAa,CAAC,GAAG,WAAW,CAAC,CAAC;IAE/C,MAAM,UAAU,GAAG;QACf,WAAW,CAAC,CAAC,CAAC,GAAG,aAAa;QAC9B,WAAW,CAAC,CAAC,CAAC,GAAG,aAAa;KACjC,CAAC;IAEF,MAAM,UAAU,GAAa;QACzB,WAAW,CAAC,CAAC,CAAC,GAAG,aAAa;QAC9B,WAAW,CAAC,CAAC,CAAC,GAAG,aAAa;KACjC,CAAC;IAEF,MAAM,iBAAiB,GAAG,iBAAiB,CACvC,UAAU,EACV,WAAW,EACX,QAAQ,CACX,CAAC;IACF,MAAM,iBAAiB,GAAG,iBAAiB,CACvC,UAAU,EACV,WAAW,EACX,QAAQ,CACX,CAAC;IAEF,qIAAqI;IACrI,iBAAiB,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC;IACvC,iBAAiB,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC;IAEvC,OAAO,CAAC,iBAAiB,EAAE,WAAW,EAAE,iBAAiB,CAAC,CAAC;AAC/D,CAAC"}
@@ -0,0 +1,16 @@
1
+ import type { PropertyDataType } from "../../utils/layerTools";
2
+ import type { ScreenProperties, WellFeature, PerforationProperties } from "../types";
3
+ /**
4
+ * Creates a readout object that contains relevant screen information
5
+ * @param screen A well trajectory screen object
6
+ * @param parentWellFeature The well that the screen belongs to
7
+ * @returns A PropertyDataType object or null if no screen is provided
8
+ */
9
+ export declare function createScreenReadout(screen: ScreenProperties | undefined, parentWellFeature: WellFeature): PropertyDataType | null;
10
+ /**
11
+ * Creates a readout object that contains relevant perforation information
12
+ * @param perforation A well trajectory perforation object
13
+ * @param parentWellFeature The well that the perforation belongs to
14
+ * @returns A PropertyDataType object or null if no perforation is provided
15
+ */
16
+ export declare function createPerforationReadout(perforation: PerforationProperties | undefined, parentWellFeature: WellFeature): PropertyDataType | null;
@@ -0,0 +1,33 @@
1
+ /**
2
+ * Creates a readout object that contains relevant screen information
3
+ * @param screen A well trajectory screen object
4
+ * @param parentWellFeature The well that the screen belongs to
5
+ * @returns A PropertyDataType object or null if no screen is provided
6
+ */
7
+ export function createScreenReadout(screen, parentWellFeature) {
8
+ var _a;
9
+ if (!screen)
10
+ return null;
11
+ return {
12
+ name: `Screen ${parentWellFeature.properties.name}`,
13
+ value: screen.name,
14
+ color: (_a = parentWellFeature.properties) === null || _a === void 0 ? void 0 : _a.color,
15
+ };
16
+ }
17
+ /**
18
+ * Creates a readout object that contains relevant perforation information
19
+ * @param perforation A well trajectory perforation object
20
+ * @param parentWellFeature The well that the perforation belongs to
21
+ * @returns A PropertyDataType object or null if no perforation is provided
22
+ */
23
+ export function createPerforationReadout(perforation, parentWellFeature) {
24
+ var _a;
25
+ if (!perforation)
26
+ return null;
27
+ return {
28
+ name: perforation.name,
29
+ value: perforation.status,
30
+ color: (_a = parentWellFeature.properties) === null || _a === void 0 ? void 0 : _a.color,
31
+ };
32
+ }
33
+ //# sourceMappingURL=readout.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"readout.js","sourceRoot":"","sources":["../../../../src/layers/wells/utils/readout.ts"],"names":[],"mappings":"AAOA;;;;;GAKG;AAEH,MAAM,UAAU,mBAAmB,CAC/B,MAAoC,EACpC,iBAA8B;;IAE9B,IAAI,CAAC,MAAM;QAAE,OAAO,IAAI,CAAC;IAEzB,OAAO;QACH,IAAI,EAAE,UAAU,iBAAiB,CAAC,UAAU,CAAC,IAAI,EAAE;QACnD,KAAK,EAAE,MAAM,CAAC,IAAI;QAClB,KAAK,EAAE,MAAA,iBAAiB,CAAC,UAAU,0CAAE,KAAK;KAC7C,CAAC;AACN,CAAC;AAED;;;;;GAKG;AAEH,MAAM,UAAU,wBAAwB,CACpC,WAA8C,EAC9C,iBAA8B;;IAE9B,IAAI,CAAC,WAAW;QAAE,OAAO,IAAI,CAAC;IAE9B,OAAO;QACH,IAAI,EAAE,WAAW,CAAC,IAAI;QACtB,KAAK,EAAE,WAAW,CAAC,MAAM;QACzB,KAAK,EAAE,MAAA,iBAAiB,CAAC,UAAU,0CAAE,KAAK;KAC7C,CAAC;AACN,CAAC"}
@@ -1,10 +1,17 @@
1
1
  import type { AccessorContext, Color } from "@deck.gl/core";
2
- import type { Position } from "geojson";
2
+ import type { LineString, Position } from "geojson";
3
+ import type { Point2D, Point3D } from "../../../utils";
3
4
  import type { ColorAccessor, WellFeature } from "../types";
5
+ /**
6
+ * Finds the nested geometry object that describes a well's trajectory
7
+ * @param well_object A GeoJSON Well Feature
8
+ * @returns A "LineString" object that describes the well's path
9
+ */
10
+ export declare function getLineStringGeometry(well_object: WellFeature): LineString | undefined;
4
11
  export declare function getColor(accessor: ColorAccessor): Color | ((object: WellFeature, objectInfo?: AccessorContext<WellFeature>) => Color | undefined);
5
12
  /**
6
13
  * Get trajectory data from LineString Geometry if it's visible (checking
7
- * trajectory visiblity based on line color)
14
+ * trajectory visibility based on line color)
8
15
  */
9
16
  export declare function getTrajectory(well_object: WellFeature, color_accessor: ColorAccessor): Position[] | undefined;
10
17
  export declare function getMdsInRange(mdArray: number[], mdStart: number, mdEnd: number): number[];
@@ -12,3 +19,35 @@ export declare function interpolateDataOnTrajectory(coord: Position, data: numbe
12
19
  export declare function getMd(coord: Position, feature: WellFeature, accessor: ColorAccessor): number | null;
13
20
  export declare function getTvd(coord: Position, feature: WellFeature, accessor: ColorAccessor): number | null;
14
21
  export declare function getSegmentIndex(coord: Position, path: Position[]): number;
22
+ /**
23
+ * Gets the lower and upper path-indices for the path-segment that contains a specific fractional point along the path. fraction-positions that are very close to either end (by 0.001 units) will be rounded of.
24
+ * @param fractionPosition A fractional position along the track (0-1);
25
+ * @param trajectory A list of positions that describes the trajectory
26
+ * @param cumulativeTrajectoryDistance A list of pre-computed distance measurements for each trajectory point (i.e. a wells measured depth array). The measurements must cumulative values.
27
+ * @returns a tuple containing the lower and upper segment indices, as well as the fractional position along the segment (0-1, with 0 being the beginning of the segment)
28
+ */
29
+ export declare function getFractionPositionSegmentIndices(fractionPosition: number, trajectory: unknown[], cumulativeTrajectoryDistance: number[]): [lowerIndex: number, upperIndex: number, segmentFraction: number];
30
+ /**
31
+ * Get position and angle (in radians) along a trajectory path
32
+ * @param positionAlongPath 0-1 fraction along trajectory
33
+ * @param trajectory Trajectory as a list of positions
34
+ * @param projectionFunc Callback function to project 3D coordinates over to 2D
35
+ * @param is3d Whether to use compute with (and return) 2-dimensional positions
36
+ * @returns A tuple containing an angle and a interpolated point on the trajectory
37
+ */
38
+ export declare function getPositionAndAngleOnTrajectoryPath(positionAlongPath: number, trajectory: Position[], cumulativeTrajectoryDistance: number[], projectionFunc?: (xyz: number[]) => number[], is3d?: boolean): [angle: number, position: Point2D | Point3D];
39
+ /**
40
+ * Computes an array of cumulative distances for a well's trajectory path.
41
+ *
42
+ * **Note:** This is usually equivalent to the MD-array, so you probably don't need this.
43
+ * @param well_xyz A list of positions that describe the wells trajectory
44
+ * @returns a list of cumulative distances
45
+ */
46
+ export declare function getCumulativeDistance(well_xyz: Position[]): number[];
47
+ /**
48
+ * Adds interpolated entries to trajectory data (MD and position) at a given MD. If an MD value is close (0.001 units) the point will *not* be added.
49
+ * @param well A well feature to add entries to
50
+ * @param mdValuesToInject one or more MD values to inject
51
+ * @returns A copy of the well object with the new MD values injected
52
+ */
53
+ export declare function injectMdPoints(well: WellFeature, ...mdValuesToInject: number[]): WellFeature;
@@ -1,7 +1,14 @@
1
- import { distance, subtract, dot } from "mathjs";
2
- import { distToSegmentSquared, isPointAwayFromLineEnd, } from "../../../utils/measurement";
1
+ import _ from "lodash";
2
+ import { Vector2, Vector3 } from "math.gl";
3
+ import { distance, dot, subtract } from "mathjs";
4
+ import { distToSegmentSquared, isClose, isPointAwayFromLineEnd, } from "../../../utils/measurement";
3
5
  import { getWellHeadPosition } from "./features";
4
- function getLineStringGeometry(well_object) {
6
+ /**
7
+ * Finds the nested geometry object that describes a well's trajectory
8
+ * @param well_object A GeoJSON Well Feature
9
+ * @returns A "LineString" object that describes the well's path
10
+ */
11
+ export function getLineStringGeometry(well_object) {
5
12
  const geometries = well_object.geometry.geometries;
6
13
  return geometries.find((item) => item.type === "LineString");
7
14
  }
@@ -40,7 +47,7 @@ function isTrajectoryTransparent(well_object, color_accessor) {
40
47
  }
41
48
  /**
42
49
  * Get trajectory data from LineString Geometry if it's visible (checking
43
- * trajectory visiblity based on line color)
50
+ * trajectory visibility based on line color)
44
51
  */
45
52
  export function getTrajectory(well_object, color_accessor) {
46
53
  var _a;
@@ -87,6 +94,9 @@ export function interpolateDataOnTrajectory(coord, data, trajectory) {
87
94
  isPointAwayFromLineEnd(coord, [survey0, survey1])) {
88
95
  coord = survey1;
89
96
  }
97
+ if (index0 === 0 && isPointAwayFromLineEnd(coord, [survey1, survey0])) {
98
+ coord = survey0;
99
+ }
90
100
  const dv = distance(survey0, survey1);
91
101
  if (dv === 0) {
92
102
  return null;
@@ -158,4 +168,163 @@ export function getSegmentIndex(coord, path) {
158
168
  }
159
169
  return segment_index;
160
170
  }
171
+ /**
172
+ * Gets the lower and upper path-indices for the path-segment that contains a specific fractional point along the path. fraction-positions that are very close to either end (by 0.001 units) will be rounded of.
173
+ * @param fractionPosition A fractional position along the track (0-1);
174
+ * @param trajectory A list of positions that describes the trajectory
175
+ * @param cumulativeTrajectoryDistance A list of pre-computed distance measurements for each trajectory point (i.e. a wells measured depth array). The measurements must cumulative values.
176
+ * @returns a tuple containing the lower and upper segment indices, as well as the fractional position along the segment (0-1, with 0 being the beginning of the segment)
177
+ */
178
+ export function getFractionPositionSegmentIndices(fractionPosition, trajectory, cumulativeTrajectoryDistance) {
179
+ if (trajectory.length < 2) {
180
+ throw new Error("Expected trajectory to have at least 2 points");
181
+ }
182
+ if (cumulativeTrajectoryDistance.length !== trajectory.length) {
183
+ throw new Error("Expected path measurements array to be same length as path array");
184
+ }
185
+ // Some trajectories dont have the md-array starting at 1
186
+ const offset = cumulativeTrajectoryDistance.at(0);
187
+ const pointDistance = _.clamp(fractionPosition * (cumulativeTrajectoryDistance.at(-1) + offset), cumulativeTrajectoryDistance.at(0), cumulativeTrajectoryDistance.at(-1));
188
+ const sortedIndex = _.sortedIndex(cumulativeTrajectoryDistance, pointDistance);
189
+ if (sortedIndex === 0) {
190
+ return [0, 1, 0];
191
+ }
192
+ // Since we clamp it, this shouldn't be possible, but Im leaving it just in case
193
+ /* istanbul ignore next @preserve */
194
+ if (sortedIndex >= cumulativeTrajectoryDistance.length) {
195
+ throw new Error("Position is outside of trajectory");
196
+ }
197
+ const lowerDistance = cumulativeTrajectoryDistance[sortedIndex - 1];
198
+ const upperDistance = cumulativeTrajectoryDistance[sortedIndex];
199
+ // Distance arrays are expected to be increasing, so this implies invalid data
200
+ if (upperDistance - lowerDistance === 0) {
201
+ console.warn(`segment length is 0 at index ${sortedIndex - 1}`);
202
+ return [sortedIndex - 1, sortedIndex, 0];
203
+ }
204
+ let segmentPos = (pointDistance - lowerDistance) / (upperDistance - lowerDistance);
205
+ if (isClose(segmentPos, 0))
206
+ segmentPos = 0;
207
+ if (isClose(segmentPos, 1))
208
+ segmentPos = 1;
209
+ return [sortedIndex - 1, sortedIndex, segmentPos];
210
+ }
211
+ /**
212
+ * Get position and angle (in radians) along a trajectory path
213
+ * @param positionAlongPath 0-1 fraction along trajectory
214
+ * @param trajectory Trajectory as a list of positions
215
+ * @param projectionFunc Callback function to project 3D coordinates over to 2D
216
+ * @param is3d Whether to use compute with (and return) 2-dimensional positions
217
+ * @returns A tuple containing an angle and a interpolated point on the trajectory
218
+ */
219
+ export function getPositionAndAngleOnTrajectoryPath(positionAlongPath, trajectory, cumulativeTrajectoryDistance, projectionFunc, is3d) {
220
+ var _a;
221
+ if (is3d === undefined)
222
+ is3d = ((_a = trajectory[0]) === null || _a === void 0 ? void 0 : _a.length) === 3;
223
+ if (!trajectory.length && is3d)
224
+ return [0, [0, 0, 0]];
225
+ if (!trajectory.length && !is3d)
226
+ return [0, [0, 0]];
227
+ if (is3d && trajectory[0].length < 3)
228
+ throw new Error(`Expected trajectory positions to be 3D, instead got ${trajectory[0].length} dimensions`);
229
+ if (is3d && projectionFunc === undefined)
230
+ throw new Error("2D projection function required for 3d trajectories");
231
+ const [lowerSegmentIndex, upperSegmentIndex, segmentFraction] = getFractionPositionSegmentIndices(positionAlongPath, trajectory, cumulativeTrajectoryDistance);
232
+ const position = _.zipWith(trajectory[lowerSegmentIndex], trajectory[upperSegmentIndex], (pl, pu) => {
233
+ return pl + segmentFraction * (pu - pl);
234
+ });
235
+ // Compute angle projected to camera
236
+ let lowerProjectedPosition = trajectory[lowerSegmentIndex];
237
+ let upperProjectedPosition = trajectory[upperSegmentIndex];
238
+ // We only need to project when we deal with 3 positions
239
+ if (is3d) {
240
+ lowerProjectedPosition = projectionFunc(trajectory[lowerSegmentIndex]);
241
+ upperProjectedPosition = projectionFunc(trajectory[upperSegmentIndex]);
242
+ // ? I don't understand why we need to apply this whenever we project from 3d, but the angle gets wrong if I don't
243
+ lowerProjectedPosition[1] *= -1;
244
+ upperProjectedPosition[1] *= -1;
245
+ }
246
+ const segmentVec = new Vector2(upperProjectedPosition[0] - lowerProjectedPosition[0], upperProjectedPosition[1] - lowerProjectedPosition[1]);
247
+ let angle = 0;
248
+ // The projected vector has no length, so we cannot define an angle. This is most likely because the two points are stacked on top of each other
249
+ if (segmentVec.len() !== 0) {
250
+ segmentVec.normalize();
251
+ angle = Math.atan2(segmentVec[1], segmentVec[0]);
252
+ }
253
+ if (is3d)
254
+ return [angle, position];
255
+ return [angle, position];
256
+ }
257
+ /**
258
+ * Computes an array of cumulative distances for a well's trajectory path.
259
+ *
260
+ * **Note:** This is usually equivalent to the MD-array, so you probably don't need this.
261
+ * @param well_xyz A list of positions that describe the wells trajectory
262
+ * @returns a list of cumulative distances
263
+ */
264
+ export function getCumulativeDistance(well_xyz) {
265
+ if (!well_xyz.length)
266
+ return [];
267
+ const cumulativeDistance = [0];
268
+ for (let i = 1; i < well_xyz.length; i++) {
269
+ const p1 = well_xyz[i - 1];
270
+ const p2 = well_xyz[i];
271
+ const v0 = new Vector3(p1);
272
+ const v1 = new Vector3(p2);
273
+ const distance = v0.distance(v1);
274
+ cumulativeDistance.push(cumulativeDistance[i - 1] + distance);
275
+ }
276
+ return cumulativeDistance;
277
+ }
278
+ /**
279
+ * Adds interpolated entries to trajectory data (MD and position) at a given MD. If an MD value is close (0.001 units) the point will *not* be added.
280
+ * @param well A well feature to add entries to
281
+ * @param mdValuesToInject one or more MD values to inject
282
+ * @returns A copy of the well object with the new MD values injected
283
+ */
284
+ export function injectMdPoints(well, ...mdValuesToInject) {
285
+ var _a, _b, _c;
286
+ const path = (_b = (_a = getLineStringGeometry(well)) === null || _a === void 0 ? void 0 : _a.coordinates) !== null && _b !== void 0 ? _b : [];
287
+ const md = (_c = well.properties.md[0]) !== null && _c !== void 0 ? _c : getCumulativeDistance(path);
288
+ if (path.length !== md.length) {
289
+ throw new Error("Cannot inject MD points, md and path are of different length");
290
+ }
291
+ const newPath = [...path];
292
+ const newMd = [...md];
293
+ let currentDataRowIdx = 0;
294
+ let spliceCount = 0;
295
+ for (const nextMdToInject of mdValuesToInject) {
296
+ if (nextMdToInject < md[0])
297
+ continue;
298
+ if (nextMdToInject > md.at(-1))
299
+ break;
300
+ // Increase until we go over or find the value
301
+ while (currentDataRowIdx < md.length &&
302
+ md[currentDataRowIdx] < nextMdToInject) {
303
+ currentDataRowIdx++;
304
+ }
305
+ if (currentDataRowIdx >= md.length)
306
+ break;
307
+ // Data already in array, so we can skip it
308
+ const mdBelow = md[currentDataRowIdx - 1];
309
+ const mdAbove = md[currentDataRowIdx];
310
+ if (isClose(mdBelow, nextMdToInject))
311
+ continue;
312
+ if (isClose(mdAbove, nextMdToInject))
313
+ continue;
314
+ // above/below values are guaranteed to be different here, so we don't need to worry about 0 division
315
+ const interpolatedT = (nextMdToInject - mdBelow) / (mdAbove - mdBelow);
316
+ const interpolatedPosition = _.zipWith(path[currentDataRowIdx - 1], path[currentDataRowIdx], (pl, pu) => {
317
+ return pl + interpolatedT * (pu - pl);
318
+ });
319
+ const spliceIndex = currentDataRowIdx + spliceCount;
320
+ newPath.splice(spliceIndex, 0, interpolatedPosition);
321
+ newMd.splice(spliceIndex, 0, nextMdToInject);
322
+ spliceCount++;
323
+ }
324
+ return Object.assign(Object.assign({}, well), { properties: Object.assign(Object.assign({}, well.properties), { md: [newMd] }), geometry: Object.assign(Object.assign({}, well.geometry), { geometries: well.geometry.geometries.map((g) => {
325
+ if (g.type !== "LineString")
326
+ return g;
327
+ return Object.assign(Object.assign({}, g), { coordinates: newPath });
328
+ }) }) });
329
+ }
161
330
  //# sourceMappingURL=trajectory.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"trajectory.js","sourceRoot":"","sources":["../../../../src/layers/wells/utils/trajectory.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,GAAG,EAAE,MAAM,QAAQ,CAAC;AAIjD,OAAO,EACH,oBAAoB,EACpB,sBAAsB,GACzB,MAAM,4BAA4B,CAAC;AAGpC,OAAO,EAAE,mBAAmB,EAAE,MAAM,YAAY,CAAC;AAEjD,SAAS,qBAAqB,CAC1B,WAAwB;IAExB,MAAM,UAAU,GAAG,WAAW,CAAC,QAAQ,CAAC,UAAU,CAAC;IACnD,OAAO,UAAU,CAAC,IAAI,CAClB,CAAC,IAAI,EAAsB,EAAE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CACO,IAAI,KACP,UAAU,kCACH,IAAI,CAAC,UAAU,KAClB,EAAE,EAAE,CAAC,KAAK,CAAC,KAEf,QAAQ,kCACD,IAAI,CAAC,QAAQ,KAChB,UAAU,EAAE,IAAI,CAAC,QAAQ,CAAC,UAAU,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE;gBAC3C,IAAI,CAAC,CAAC,IAAI,KAAK,YAAY;oBAAE,OAAO,CAAC,CAAC;gBACtC,uCACO,CAAC,KACJ,WAAW,EAAE,OAAO,IACtB;YACN,CAAC,CAAC,OAER;AACN,CAAC"}
@@ -1,13 +1,14 @@
1
- import type { Color, Layer, LayersList, PickingInfo, UpdateParameters } from "@deck.gl/core";
1
+ import type { Accessor, Color, Layer, LayersList, PickingInfo, UpdateParameters } from "@deck.gl/core";
2
2
  import { CompositeLayer } from "@deck.gl/core";
3
3
  import type { BinaryFeatureCollection } from "@loaders.gl/schema";
4
4
  import type { Feature } from "geojson";
5
5
  import type { ColormapFunctionType } from "../utils/colormapTools";
6
6
  import type { ExtendedLayerProps, ReportBoundingBoxAction } from "../utils/layerTools";
7
+ import type { ContinuousLegendDataType, DiscreteLegendDataType } from "../../components/ColorLegend";
8
+ import type { FlatWellMarkersLayerProps } from "./layers/flatWellMarkersLayer";
7
9
  import type { WellLabelLayerProps } from "./layers/wellLabelLayer";
8
10
  import { WellLabelLayer } from "./layers/wellLabelLayer";
9
- import type { AbscissaTransform, LineStyleAccessor, LogCurveDataType, WellFeature, WellFeatureCollection, WellHeadStyleAccessor, WellsPickInfo } from "./types";
10
- import type { ContinuousLegendDataType, DiscreteLegendDataType } from "../../components/ColorLegend";
11
+ import type { AbscissaTransform, DashAccessor, LineStyleAccessor, LogCurveDataType, WellFeature, WellFeatureCollection, WellHeadStyleAccessor, WellsPickInfo } from "./types";
11
12
  export declare enum SubLayerId {
12
13
  COLORS = "colors",
13
14
  SIMPLE = "simple",
@@ -16,7 +17,12 @@ export declare enum SubLayerId {
16
17
  HIGHLIGHT_2 = "highlight2",
17
18
  LOG_CURVE = "log_curve",
18
19
  SELECTION = "selection",
19
- LABELS = "labels"
20
+ LABELS = "labels",
21
+ MARKERS = "markers",
22
+ WELL_HEADS = "well_head",
23
+ SCREEN_TRAJECTORY = "screen_trajectory",
24
+ SCREEN_TRAJECTORY_OUTLINE = "screen_trajectory_outline",
25
+ TRAJECTORY_FILTER_GHOST = "trajectory_filter_ghost"
20
26
  }
21
27
  export interface WellsLayerProps extends ExtendedLayerProps {
22
28
  /**
@@ -87,6 +93,49 @@ export interface WellsLayerProps extends ExtendedLayerProps {
87
93
  section?: boolean | AbscissaTransform;
88
94
  reportBoundingBox?: React.Dispatch<ReportBoundingBoxAction>;
89
95
  wellLabel?: Partial<WellLabelLayerProps>;
96
+ markers?: {
97
+ /** Enables simple line markers at the start and end of screen sections.
98
+ *
99
+ * @remark These markers are currently only designed for 2D, so they are not guaranteed to look nice in 3D
100
+ */
101
+ showScreens?: boolean;
102
+ /**
103
+ * Renders screen sections of the trajectory as dashed segments.
104
+ *
105
+ * @remark If enabled, the COLORS sub-layer will be replaced by the SCREEN_TRAJECTORY sub-layer!
106
+ */
107
+ showScreenTrajectoryAsDash?: boolean;
108
+ /** Enables visualization of trajectory perforations.
109
+ *
110
+ * @remark These markers are currently only designed for 2D, so they are not guaranteed to look nice in 3D
111
+ */
112
+ showPerforations?: boolean;
113
+ /** Specifies colors of markers at a per-marker basis */
114
+ getMarkerColor?: FlatWellMarkersLayerProps<WellFeature>["getMarkerColor"];
115
+ /** Specifies the dash factor for screen sections. */
116
+ getScreenDashArray?: DashAccessor;
117
+ };
118
+ /** Enables well filtering */
119
+ enableFilters: boolean;
120
+ /** Filter wells by measured depth (MD).
121
+ * - Return [min, max] to show only the portion of the well between these MD values
122
+ * - Return [max, min] (inverted) to show everything OUTSIDE this range
123
+ * - Return undefined or [-1, -1] to show the entire well
124
+ * Multiple ranges are additive
125
+ *
126
+ * @remark To make sure trajectories paths disappear at the correct point, each
127
+ * range value will inject a point into the path array; meaning layers will recompute
128
+ * each time this is changed
129
+ */
130
+ mdFilterRange: Accessor<WellFeature, [number, number] | [number, number][]>;
131
+ /**
132
+ * Filters trajectory paths to formation sections.
133
+ */
134
+ formationFilter: Accessor<WellFeature, string[]>;
135
+ /** Filters wells based on name */
136
+ wellNameFilter: string[];
137
+ /** Shows a simple trajectory in place of filtered sections. If color is not specified, a light gray will be used */
138
+ showFilterTrajectoryGhost: boolean | Color;
90
139
  }
91
140
  export default class WellsLayer extends CompositeLayer<WellsLayerProps> {
92
141
  state: {
@@ -115,6 +164,8 @@ export default class WellsLayer extends CompositeLayer<WellsLayerProps> {
115
164
  protected getWellLabelPosition(): number | ((d: Feature) => number);
116
165
  protected createWellLabelLayer(data: WellFeature[]): WellLabelLayer | null;
117
166
  renderLayers(): LayersList;
167
+ private getSubLayerId;
168
+ private getSubLayerById;
118
169
  getPickingInfo({ info }: {
119
170
  info: PickingInfo;
120
171
  }): WellsPickInfo;