dwv 0.33.0-beta.43 → 0.33.0-beta.45

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/dist/dwv.d.ts CHANGED
@@ -123,9 +123,9 @@ export declare class App {
123
123
  * Get the active layer group.
124
124
  * The layer is available after the first loaded item.
125
125
  *
126
- * @returns {LayerGroup} The layer group.
126
+ * @returns {LayerGroup|undefined} The layer group.
127
127
  */
128
- getActiveLayerGroup(): LayerGroup;
128
+ getActiveLayerGroup(): LayerGroup | undefined;
129
129
  /**
130
130
  * Set the active layer group.
131
131
  *
@@ -179,7 +179,7 @@ export declare class App {
179
179
  /**
180
180
  * Initialise the application.
181
181
  *
182
- * @param {AppOptions} opt The application options
182
+ * @param {AppOptions} opt The application options.
183
183
  * @example
184
184
  * // create the dwv app
185
185
  * const app = new dwv.App();
@@ -251,9 +251,9 @@ export declare class App {
251
251
  *
252
252
  * @param {string[]} urls The list of urls to load.
253
253
  * @param {object} [options] The options object, can contain:
254
- * - requestHeaders: an array of {name, value} to use as request headers
255
- * - withCredentials: boolean xhr.withCredentials flag to pass to the request
256
- * - batchSize: the size of the request url batch
254
+ * - requestHeaders: an array of {name, value} to use as request headers,
255
+ * - withCredentials: boolean xhr.withCredentials flag to pass to the request,
256
+ * - batchSize: the size of the request url batch.
257
257
  * @fires App#loadstart
258
258
  * @fires App#loadprogress
259
259
  * @fires App#loaditem
@@ -446,13 +446,14 @@ export declare class App {
446
446
  onKeydown: (event: KeyboardEvent) => void;
447
447
  /**
448
448
  * Key down event handler example.
449
- * - CRTL-Z: undo
450
- * - CRTL-Y: redo
451
- * - CRTL-ARROW_LEFT: next element on fourth dim
452
- * - CRTL-ARROW_UP: next element on third dim
453
- * - CRTL-ARROW_RIGHT: previous element on fourth dim
454
- * - CRTL-ARROW_DOWN: previous element on third dim
455
- * (applies to the active view of the active layer group)
449
+ * - CRTL-Z: undo,
450
+ * - CRTL-Y: redo,
451
+ * - CRTL-ARROW_LEFT: next element on fourth dim,
452
+ * - CRTL-ARROW_UP: next element on third dim,
453
+ * - CRTL-ARROW_RIGHT: previous element on fourth dim,
454
+ * - CRTL-ARROW_DOWN: previous element on third dim.
455
+ *
456
+ * Applies to the active view of the active layer group.
456
457
  *
457
458
  * @param {KeyboardEvent} event The key down event.
458
459
  * @fires UndoStack#undo
@@ -461,11 +462,11 @@ export declare class App {
461
462
  */
462
463
  defaultOnKeydown: (event: KeyboardEvent) => void;
463
464
  /**
464
- * Reset the display
465
+ * Reset the display.
465
466
  */
466
467
  resetDisplay(): void;
467
468
  /**
468
- * Reset the app zoom.s
469
+ * Reset the app zoom.
469
470
  */
470
471
  resetZoom(): void;
471
472
  /**
@@ -483,7 +484,7 @@ export declare class App {
483
484
  */
484
485
  setWindowLevelPreset(preset: string): void;
485
486
  /**
486
- * Set the tool
487
+ * Set the tool.
487
488
  *
488
489
  * @param {string} tool The tool.
489
490
  */
@@ -495,13 +496,13 @@ export declare class App {
495
496
  */
496
497
  setToolFeatures(list: object): void;
497
498
  /**
498
- * Undo the last action
499
+ * Undo the last action.
499
500
  *
500
501
  * @fires UndoStack#undo
501
502
  */
502
503
  undo(): void;
503
504
  /**
504
- * Redo the last action
505
+ * Redo the last action.
505
506
  *
506
507
  * @fires UndoStack#redo
507
508
  */
@@ -569,15 +570,16 @@ export declare class AppOptions {
569
570
  binders: string[] | undefined;
570
571
  /**
571
572
  * Optional boolean flag to trigger the first data render
572
- * after the first loaded data or not. Defaults to true;
573
+ * after the first loaded data or not. Defaults to true.
573
574
  *
574
575
  * @type {boolean|undefined}
575
576
  */
576
577
  viewOnFirstLoadItem: boolean | undefined;
577
578
  /**
578
- * Optional default chraracter set string used for DICOM parsing if
579
- * not passed in DICOM file.
580
- * Valid values: https://developer.mozilla.org/en-US/docs/Web/API/Encoding_API/Encodings
579
+ * Optional default chraracterset string used for DICOM parsing if
580
+ * not passed in DICOM file.
581
+ *
582
+ * Valid values: {@link https://developer.mozilla.org/en-US/docs/Web/API/Encoding_API/Encodings}.
581
583
  *
582
584
  * @type {string|undefined}
583
585
  */
@@ -604,8 +606,10 @@ export declare namespace BLACK {
604
606
 
605
607
  /**
606
608
  * Build a multipart message.
607
- * See: https://en.wikipedia.org/wiki/MIME#Multipart_messages
608
- * See: https://hg.orthanc-server.com/orthanc-dicomweb/file/tip/Resources/Samples/JavaScript/stow-rs.js
609
+ *
610
+ * Ref:
611
+ * - {@link https://en.wikipedia.org/wiki/MIME#Multipart_messages},
612
+ * - {@link https://hg.orthanc-server.com/orthanc-dicomweb/file/tip/Resources/Samples/JavaScript/stow-rs.js}.
609
613
  *
610
614
  * @param {Array} parts The message parts as an array of object containing
611
615
  * content headers and messages as the data property (as returned by parse).
@@ -666,7 +670,7 @@ export declare class ChangeSegmentColourCommand {
666
670
 
667
671
  /**
668
672
  * Colour map: red, green and blue components
669
- * to associate with intensity values.
673
+ * to associate with intensity values.
670
674
  */
671
675
  export declare class ColourMap {
672
676
  /**
@@ -875,7 +879,7 @@ export declare class DeleteSegmentCommand {
875
879
  /**
876
880
  * DICOM code: item of a basic code sequence.
877
881
  *
878
- * @see https://dicom.nema.org/medical/dicom/current/output/chtml/part03/sect_8.8.html
882
+ * Ref: {@link https://dicom.nema.org/medical/dicom/2022a/output/chtml/part03/sect_8.8.html}.
879
883
  */
880
884
  export declare class DicomCode {
881
885
  /**
@@ -1030,7 +1034,7 @@ export declare class DicomWriter {
1030
1034
  * if nothing is found the default rule is applied.
1031
1035
  *
1032
1036
  * @param {Object<string, WriterRule>} rules The input rules.
1033
- * @param {boolean} [addMissingTags] if true, explicit tags that
1037
+ * @param {boolean} [addMissingTags] If true, explicit tags that
1034
1038
  * have replace rule and a value will be
1035
1039
  * added if missing. Defaults to false.
1036
1040
  */
@@ -1045,7 +1049,7 @@ export declare class DicomWriter {
1045
1049
  * Get the element to write according to the class rules.
1046
1050
  * Priority order: tagName, groupName, default.
1047
1051
  *
1048
- * @param {DataElement} element The element to check
1052
+ * @param {DataElement} element The element to check.
1049
1053
  * @returns {DataElement|null} The element to write, can be null.
1050
1054
  */
1051
1055
  getElementToWrite(element: DataElement): DataElement | null;
@@ -1317,11 +1321,11 @@ export declare class DrawLayer {
1317
1321
  isVisible(): boolean;
1318
1322
  /**
1319
1323
  * Draw the content (imageData) of the layer.
1320
- * The imageData variable needs to be set
1324
+ * The imageData variable needs to be set.
1321
1325
  */
1322
1326
  draw(): void;
1323
1327
  /**
1324
- * Initialise the layer: set the canvas and context
1328
+ * Initialise the layer: set the canvas and context.
1325
1329
  *
1326
1330
  * @param {Scalar2D} size The image size as {x,y}.
1327
1331
  * @param {Scalar2D} spacing The image spacing as {x,y}.
@@ -1331,11 +1335,11 @@ export declare class DrawLayer {
1331
1335
  /**
1332
1336
  * Fit the layer to its parent container.
1333
1337
  *
1334
- * @param {number} fitScale1D The 1D fit scale.
1335
- * @param {Scalar2D} fitSize The fit size as {x,y}.
1338
+ * @param {Scalar2D} containerSize The container size as {x,y}.
1339
+ * @param {number} divToWorldSizeRatio The div to world size ratio.
1336
1340
  * @param {Scalar2D} fitOffset The fit offset as {x,y}.
1337
1341
  */
1338
- fitToContainer(fitScale1D: number, fitSize: Scalar2D, fitOffset: Scalar2D): void;
1342
+ fitToContainer(containerSize: Scalar2D, divToWorldSizeRatio: number, fitOffset: Scalar2D): void;
1339
1343
  /**
1340
1344
  * Check the visibility of a given group.
1341
1345
  *
@@ -1495,7 +1499,7 @@ export declare class Geometry {
1495
1499
  * Warning: the size comes as stored in DICOM, meaning that it could
1496
1500
  * be oriented.
1497
1501
  *
1498
- * @param {Matrix33} [viewOrientation] The view orientation (optional)
1502
+ * @param {Matrix33} [viewOrientation] The view orientation (optional).
1499
1503
  * @returns {Size} The object size.
1500
1504
  */
1501
1505
  getSize(viewOrientation?: Matrix33): Size;
@@ -1504,7 +1508,7 @@ export declare class Geometry {
1504
1508
  * Warning: the spacing comes as stored in DICOM, meaning that it could
1505
1509
  * be oriented.
1506
1510
  *
1507
- * @param {Matrix33} [viewOrientation] The view orientation (optional)
1511
+ * @param {Matrix33} [viewOrientation] The view orientation (optional).
1508
1512
  * @returns {Spacing} The object spacing.
1509
1513
  */
1510
1514
  getSpacing(viewOrientation?: Matrix33): Spacing;
@@ -1727,11 +1731,14 @@ export declare function getTypedArray(bitsAllocated: number, pixelRepresentation
1727
1731
 
1728
1732
  /**
1729
1733
  * Get a UID for a DICOM tag.
1730
- * Note: Use https://github.com/uuidjs/uuid?
1731
1734
  *
1732
- * @see http://dicom.nema.org/dicom/2013/output/chtml/part05/chapter_9.html
1733
- * @see http://dicomiseasy.blogspot.com/2011/12/chapter-4-dicom-objects-in-chapter-3.html
1734
- * @see https://stackoverflow.com/questions/46304306/how-to-generate-unique-dicom-uid
1735
+ * Note: Use {@link https://github.com/uuidjs/uuid}?
1736
+ *
1737
+ * Ref:
1738
+ * - {@link http://dicom.nema.org/medical/dicom/2022a/output/chtml/part05/chapter_9.html},
1739
+ * - {@link http://dicomiseasy.blogspot.com/2011/12/chapter-4-dicom-objects-in-chapter-3.html},
1740
+ * - {@link https://stackoverflow.com/questions/46304306/how-to-generate-unique-dicom-uid}.
1741
+ *
1735
1742
  * @param {string} tagName The input tag.
1736
1743
  * @returns {string} The corresponding UID.
1737
1744
  */
@@ -1739,8 +1746,9 @@ export declare function getUID(tagName: string): string;
1739
1746
 
1740
1747
  /**
1741
1748
  * Check that an input buffer includes the DICOM prefix 'DICM'
1742
- * after the 128 bytes preamble.
1743
- * Ref: [DICOM File Meta]{@link https://dicom.nema.org/dicom/2013/output/chtml/part10/chapter_7.html#sect_7.1}
1749
+ * after the 128 bytes preamble.
1750
+ *
1751
+ * Ref: [DICOM File Meta]{@link https://dicom.nema.org/medical/dicom/2022a/output/chtml/part10/chapter_7.html#sect_7.1}.
1744
1752
  *
1745
1753
  * @param {ArrayBuffer} buffer The buffer to check.
1746
1754
  * @returns {boolean} True if the buffer includes the prefix.
@@ -1825,7 +1833,7 @@ declare class Image_2 {
1825
1833
  /**
1826
1834
  * Get the data buffer of the image.
1827
1835
  *
1828
- * @todo dangerous...
1836
+ * @todo Dangerous...
1829
1837
  * @returns {TypedArray} The data buffer of the image.
1830
1838
  */
1831
1839
  getBuffer(): Int8Array | Uint8Array | Int16Array | Uint16Array | Int32Array | Uint32Array;
@@ -2260,18 +2268,18 @@ export declare function labToUintLab(triplet: object): object;
2260
2268
  /**
2261
2269
  * Layer group.
2262
2270
  *
2263
- * Display position: {x,y}
2264
- * Plane position: Index (access: get(i))
2265
- * (world) Position: Point3D (access: getX, getY, getZ)
2271
+ * - Display position: {x,y},
2272
+ * - Plane position: Index (access: get(i)),
2273
+ * - (world) Position: Point3D (access: getX, getY, getZ).
2266
2274
  *
2267
2275
  * Display -> World:
2268
- * planePos = viewLayer.displayToPlanePos(displayPos)
2269
- * -> compensate for layer scale and offset
2270
- * pos = viewController.getPositionFromPlanePoint(planePos)
2276
+ * - planePos = viewLayer.displayToPlanePos(displayPos)
2277
+ * -> compensate for layer scale and offset,
2278
+ * - pos = viewController.getPositionFromPlanePoint(planePos).
2271
2279
  *
2272
- * World -> display
2273
- * planePos = viewController.getOffset3DFromPlaneOffset(pos)
2274
- * no need yet for a planePos to displayPos...
2280
+ * World -> Display:
2281
+ * - planePos = viewController.getOffset3DFromPlaneOffset(pos)
2282
+ * no need yet for a planePos to displayPos...
2275
2283
  */
2276
2284
  export declare class LayerGroup {
2277
2285
  /**
@@ -2315,7 +2323,7 @@ export declare class LayerGroup {
2315
2323
  */
2316
2324
  getBaseScale(): Scalar3D;
2317
2325
  /**
2318
- * Get the added scale: the scale added to the base scale
2326
+ * Get the added scale: the scale added to the base scale.
2319
2327
  *
2320
2328
  * @returns {Scalar3D} The scale as {x,y,z}.
2321
2329
  */
@@ -2418,12 +2426,16 @@ export declare class LayerGroup {
2418
2426
  /**
2419
2427
  * Add a view layer.
2420
2428
  *
2429
+ * The new layer will be marked as the active view layer.
2430
+ *
2421
2431
  * @returns {ViewLayer} The created layer.
2422
2432
  */
2423
2433
  addViewLayer(): ViewLayer;
2424
2434
  /**
2425
2435
  * Add a draw layer.
2426
2436
  *
2437
+ * The new layer will be marked as the active draw layer.
2438
+ *
2427
2439
  * @returns {DrawLayer} The created layer.
2428
2440
  */
2429
2441
  addDrawLayer(): DrawLayer;
@@ -2494,23 +2506,24 @@ export declare class LayerGroup {
2494
2506
  */
2495
2507
  updateLayersToPositionChange: (event: object) => void;
2496
2508
  /**
2497
- * Calculate the fit scale: the scale that fits the largest data.
2509
+ * Calculate the div to world size ratio needed to fit
2510
+ * the largest data.
2498
2511
  *
2499
- * @returns {number|undefined} The fit scale.
2512
+ * @returns {number|undefined} The ratio.
2500
2513
  */
2501
- calculateFitScale(): number | undefined;
2514
+ getDivToWorldSizeRatio(): number | undefined;
2502
2515
  /**
2503
- * Set the layer group fit scale.
2516
+ * Fit to container: set the layers div to world size ratio.
2504
2517
  *
2505
- * @param {number} scaleIn The fit scale.
2518
+ * @param {number} divToWorldSizeRatio The ratio.
2506
2519
  */
2507
- setFitScale(scaleIn: number): void;
2520
+ fitToContainer(divToWorldSizeRatio: number): void;
2508
2521
  /**
2509
- * Get the largest data size.
2522
+ * Get the largest data world (mm) size.
2510
2523
  *
2511
2524
  * @returns {Scalar2D|undefined} The largest size as {x,y}.
2512
2525
  */
2513
- getMaxSize(): Scalar2D | undefined;
2526
+ getMaxWorldSize(): Scalar2D | undefined;
2514
2527
  /**
2515
2528
  * Flip all layers along the Z axis without offset compensation.
2516
2529
  */
@@ -2653,7 +2666,7 @@ export declare class MaskFactory {
2653
2666
  /**
2654
2667
  * DICOM (mask) segment: item of a SegmentSequence (0062,0002).
2655
2668
  *
2656
- * @see https://dicom.nema.org/medical/dicom/2022a/output/chtml/part03/sect_C.8.20.4.html
2669
+ * Ref: {@link https://dicom.nema.org/medical/dicom/2022a/output/chtml/part03/sect_C.8.20.4.html}.
2657
2670
  */
2658
2671
  export declare class MaskSegment {
2659
2672
  /**
@@ -2822,7 +2835,7 @@ export declare class MaskSegmentViewHelper {
2822
2835
  */
2823
2836
  export declare class Matrix33 {
2824
2837
  /**
2825
- * @param {number[]} values row-major ordered 9 values.
2838
+ * @param {number[]} values Row-major ordered 9 values.
2826
2839
  */
2827
2840
  constructor(values: number[]);
2828
2841
  /**
@@ -2911,7 +2924,7 @@ export declare class Matrix33 {
2911
2924
  */
2912
2925
  getColAbsMax(col: number): object;
2913
2926
  /**
2914
- * Get this matrix with only zero and +/- ones instead of the maximum,
2927
+ * Get this matrix with only zero and +/- ones instead of the maximum.
2915
2928
  *
2916
2929
  * @returns {Matrix33} The simplified matrix.
2917
2930
  */
@@ -3290,9 +3303,11 @@ export declare class Point3D {
3290
3303
 
3291
3304
  /**
3292
3305
  * Round a float number to a given precision.
3293
- * Inspired from https://stackoverflow.com/a/49729715/3639892.
3306
+ *
3307
+ * Inspired from {@link https://stackoverflow.com/a/49729715/3639892}.
3308
+ *
3294
3309
  * Can be a solution to not have trailing zero as when
3295
- * using toFixed or toPrecision.
3310
+ * using toFixed or toPrecision.
3296
3311
  * '+number.toFixed(precision)' does not pass all the tests...
3297
3312
  *
3298
3313
  * @param {number} number The number to round.
@@ -3302,7 +3317,7 @@ export declare class Point3D {
3302
3317
  export declare function precisionRound(number: number, precision: number): number;
3303
3318
 
3304
3319
  /**
3305
- * Rescale Slope and Intercept
3320
+ * Rescale Slope and Intercept.
3306
3321
  */
3307
3322
  export declare class RescaleSlopeAndIntercept {
3308
3323
  /**
@@ -3600,7 +3615,7 @@ export declare class Spacing {
3600
3615
  /**
3601
3616
  * Convert sRGB to CIE LAB (standard illuminant D65).
3602
3617
  *
3603
- * @param {RGB} triplet sRGB triplet as {r,g,b}.
3618
+ * @param {RGB} triplet 'sRGB' triplet as {r,g,b}.
3604
3619
  * @returns {object} CIE LAB triplet as {l,a,b}.
3605
3620
  */
3606
3621
  export declare function srgbToCielab(triplet: RGB): object;
@@ -3661,7 +3676,8 @@ export declare class Tag {
3661
3676
  isWithVR(): boolean;
3662
3677
  /**
3663
3678
  * Is the tag group a private tag group ?
3664
- * see: http://dicom.nema.org/medical/dicom/2015a/output/html/part05.html#sect_7.8
3679
+ *
3680
+ * See: {@link http://dicom.nema.org/medical/dicom/2022a/output/html/part05.html#sect_7.8}.
3665
3681
  *
3666
3682
  * @returns {boolean} True if the tag group is private,
3667
3683
  * ie if its group is an odd number.
@@ -3847,7 +3863,8 @@ export declare class Vector3D {
3847
3863
  * vector that is perpendicular to both a and b.
3848
3864
  * If both vectors are parallel, the cross product is a zero vector.
3849
3865
  *
3850
- * @see https://en.wikipedia.org/wiki/Cross_product
3866
+ * Ref: {@link https://en.wikipedia.org/wiki/Cross_product}.
3867
+ *
3851
3868
  * @param {Vector3D} vector3D The input vector.
3852
3869
  * @returns {Vector3D} The result vector.
3853
3870
  */
@@ -3855,7 +3872,8 @@ export declare class Vector3D {
3855
3872
  /**
3856
3873
  * Get the dot product with another Vector3D.
3857
3874
  *
3858
- * @see https://en.wikipedia.org/wiki/Dot_product
3875
+ * Ref: {@link https://en.wikipedia.org/wiki/Dot_product}.
3876
+ *
3859
3877
  * @param {Vector3D} vector3D The input vector.
3860
3878
  * @returns {number} The dot product.
3861
3879
  */
@@ -4045,7 +4063,7 @@ export declare class View {
4045
4063
  *
4046
4064
  * @param {Point} position The new position.
4047
4065
  * @param {boolean} silent Flag to fire event or not.
4048
- * @returns {boolean} False if not in bounds
4066
+ * @returns {boolean} False if not in bounds.
4049
4067
  * @fires View#positionchange
4050
4068
  */
4051
4069
  setCurrentPosition(position: Point, silent: boolean): boolean;
@@ -4318,7 +4336,7 @@ export declare class ViewController {
4318
4336
  /**
4319
4337
  * Get the image rescaled value at the input position.
4320
4338
  *
4321
- * @param {Point} position the input position.
4339
+ * @param {Point} position The input position.
4322
4340
  * @returns {number|undefined} The image value or undefined if out of bounds
4323
4341
  * or no quantifiable (for ex RGB).
4324
4342
  */
@@ -4326,7 +4344,7 @@ export declare class ViewController {
4326
4344
  /**
4327
4345
  * Get the image pixel unit.
4328
4346
  *
4329
- * @returns {string} The unit
4347
+ * @returns {string} The unit.
4330
4348
  */
4331
4349
  getPixelUnit(): string;
4332
4350
  /**
@@ -4616,11 +4634,11 @@ export declare class ViewLayer {
4616
4634
  */
4617
4635
  getScale(): Scalar2D;
4618
4636
  /**
4619
- * Get the layer zoom offset.
4637
+ * Get the layer zoom offset without the fit scale.
4620
4638
  *
4621
4639
  * @returns {Scalar2D} The offset as {x,y}.
4622
4640
  */
4623
- getZoomOffset(): Scalar2D;
4641
+ getAbsoluteZoomOffset(): Scalar2D;
4624
4642
  /**
4625
4643
  * Set the imageSmoothing flag value.
4626
4644
  *
@@ -4737,13 +4755,13 @@ export declare class ViewLayer {
4737
4755
  */
4738
4756
  setScale(newScale: Scalar3D, center?: Point3D): void;
4739
4757
  /**
4740
- * Initialise the layer scale. Works with a zoom offset that
4741
- * comes from a equal view layer (size, scale, offset...).
4758
+ * Initialise the layer scale.
4742
4759
  *
4743
4760
  * @param {Scalar3D} newScale The scale as {x,y,z}.
4744
- * @param {Scalar2D} zoomOffset The zoom offset as {x,y}.
4761
+ * @param {Scalar2D} absoluteZoomOffset The zoom offset as {x,y}
4762
+ * without the fit scale (as provided by getAbsoluteZoomOffset).
4745
4763
  */
4746
- initScale(newScale: Scalar3D, zoomOffset: Scalar2D): void;
4764
+ initScale(newScale: Scalar3D, absoluteZoomOffset: Scalar2D): void;
4747
4765
  /**
4748
4766
  * Set the base layer offset. Updates the layer offset.
4749
4767
  *
@@ -4810,14 +4828,14 @@ export declare class ViewLayer {
4810
4828
  isVisible(): boolean;
4811
4829
  /**
4812
4830
  * Draw the content (imageData) of the layer.
4813
- * The imageData variable needs to be set
4831
+ * The imageData variable needs to be set.
4814
4832
  *
4815
4833
  * @fires App#renderstart
4816
4834
  * @fires App#renderend
4817
4835
  */
4818
4836
  draw(): void;
4819
4837
  /**
4820
- * Initialise the layer: set the canvas and context
4838
+ * Initialise the layer: set the canvas and context.
4821
4839
  *
4822
4840
  * @param {Scalar2D} size The image size as {x,y}.
4823
4841
  * @param {Scalar2D} spacing The image spacing as {x,y}.
@@ -4827,11 +4845,11 @@ export declare class ViewLayer {
4827
4845
  /**
4828
4846
  * Fit the layer to its parent container.
4829
4847
  *
4830
- * @param {number} fitScale1D The 1D fit scale.
4831
- * @param {Scalar2D} fitSize The fit size as {x,y}.
4848
+ * @param {Scalar2D} containerSize The fit size as {x,y}.
4849
+ * @param {number} divToWorldSizeRatio The div to world size ratio.
4832
4850
  * @param {Scalar2D} fitOffset The fit offset as {x,y}.
4833
4851
  */
4834
- fitToContainer(fitScale1D: number, fitSize: Scalar2D, fitOffset: Scalar2D): void;
4852
+ fitToContainer(containerSize: Scalar2D, divToWorldSizeRatio: number, fitOffset: Scalar2D): void;
4835
4853
  /**
4836
4854
  * Enable and listen to container interaction events.
4837
4855
  */