Skip to content

Commit

Permalink
Fix PNG elevation decoding.
Browse files Browse the repository at this point in the history
  • Loading branch information
ComBatVision committed Jun 23, 2024
1 parent b5ee69c commit 5e0bb00
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ open class ElevationDecoder: Closeable {
}

// Check if scale and offset should be applied to elevation data
return if (tileOffset != 1.0f || tileScale != 0.0f || coverageScale != 1.0f || coverageOffset != 0.0f) {
return if (tileScale != 1.0f || tileOffset != 0.0f || coverageScale != 1.0f || coverageOffset != 0.0f) {
// Apply scale and offset to INT16 values (except null data value) and return them as FLOAT32
val pixels = FloatArray(png.imgInfo.cols * png.imgInfo.rows)
var row = 0
Expand Down

0 comments on commit 5e0bb00

Please sign in to comment.