@@ -32,6 +32,7 @@ import { resample, resampleInterleaved } from './resample.js';
32
32
*/
33
33
34
34
/** @typedef {import("./geotiff.js").TypedArray } TypedArray */
35
+ /** @typedef {import("./geotiff.js").ReadRasterResult } ReadRasterResult */
35
36
36
37
function sum ( array , start , end ) {
37
38
let s = 0 ;
@@ -422,15 +423,15 @@ class GeoTIFFImage {
422
423
* @private
423
424
* @param {Array } imageWindow The image window in pixel coordinates
424
425
* @param {Array } samples The selected samples (0-based indices)
425
- * @param {TypedArray[] |TypedArray } valueArrays The array(s) to write into
426
+ * @param {TypedArray|TypedArray[] } valueArrays The array(s) to write into
426
427
* @param {Boolean } interleave Whether or not to write in an interleaved manner
427
428
* @param {import("./geotiff").Pool|AbstractDecoder } poolOrDecoder the decoder or decoder pool
428
429
* @param {number } width the width of window to be read into
429
430
* @param {number } height the height of window to be read into
430
431
* @param {number } resampleMethod the resampling method to be used when interpolating
431
432
* @param {AbortSignal } [signal] An AbortSignal that may be signalled if the request is
432
433
* to be aborted
433
- * @returns {Promise<TypedArray[]>|Promise<TypedArray > }
434
+ * @returns {Promise<ReadRasterResult > }
434
435
*/
435
436
async _readRaster ( imageWindow , samples , valueArrays , interleave , poolOrDecoder , width ,
436
437
height , resampleMethod , signal ) {
@@ -554,7 +555,7 @@ class GeoTIFFImage {
554
555
* of the raster is read for each sample.
555
556
*
556
557
* @param {ReadRasterOptions } [options={}] optional parameters
557
- * @returns {Promise.<(TypedArray|TypedArray[]) > } the decoded arrays as a promise
558
+ * @returns {Promise<ReadRasterResult > } the decoded arrays as a promise
558
559
*/
559
560
async readRasters ( {
560
561
window : wnd , samples = [ ] , interleave, pool = null ,
@@ -635,7 +636,7 @@ class GeoTIFFImage {
635
636
* @param {boolean } [options.enableAlpha=false] Enable reading alpha channel if present.
636
637
* @param {AbortSignal } [options.signal] An AbortSignal that may be signalled if the request is
637
638
* to be aborted
638
- * @returns {Promise<TypedArray|TypedArray[] > } the RGB array as a Promise
639
+ * @returns {Promise<ReadRasterResult > } the RGB array as a Promise
639
640
*/
640
641
async readRGB ( { window, interleave = true , pool = null , width, height,
641
642
resampleMethod, enableAlpha = false , signal } = { } ) {
0 commit comments