@gisatcz/deckgl-geolib 1.11.0-dev.0 → 1.11.0-dev.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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gisatcz/deckgl-geolib",
3
- "version": "1.11.0-dev.0",
3
+ "version": "1.11.0-dev.1",
4
4
  "private": false,
5
5
  "main": "dist/cjs/index.js",
6
6
  "module": "dist/esm/index.js",
@@ -435,7 +435,9 @@ export default class GeoImage {
435
435
 
436
436
  for (let i = 0; i < arrayLength; i += 4) {
437
437
  let pixelColor = options.nullColor;
438
- if (options.noDataValue === undefined || dataArray[pixel] !== options.noDataValue) {
438
+ // FIXME
439
+ // eslint-disable-next-line max-len
440
+ if ((!Number.isNaN(dataArray[pixel])) && (options.noDataValue === undefined || dataArray[pixel] !== options.noDataValue)) {
439
441
  if (
440
442
  (options.clipLow != null && dataArray[pixel] <= options.clipLow)
441
443
  || (options.clipHigh != null && dataArray[pixel] >= options.clipHigh)
@@ -468,9 +470,6 @@ export default class GeoImage {
468
470
  pixelColor[3] = this.scale(dataArray[pixel], options.colorScaleValueRange[0]!, options.colorScaleValueRange.slice(-1)[0]!, 0, 255);
469
471
  }
470
472
  }
471
- // If pixel has null value
472
- } else if (Number.isNaN(dataArray[pixel])) {
473
- pixelColor = [0, 0, 0, 0];
474
473
  }
475
474
  // FIXME
476
475
  // eslint-disable-next-line