Skip to content

Commit

Permalink
Merge pull request #27 from melissalinkert/yet-another-tile-padding-fix
Browse files Browse the repository at this point in the history
Fix output offset calculation in tile row copying
  • Loading branch information
chris-allan authored May 19, 2020
2 parents 7c293e9 + 06fe2e8 commit 13d276b
Showing 1 changed file with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -721,10 +721,9 @@ private void convertPyramid(PyramidSeries s)
new byte[descriptor.tileSizeX * descriptor.tileSizeY];
int totalRows = region.height;
int inRowLen = tileBytes.length / totalRows;
int outRowLen = realTile.length / totalRows;
for (int row=0; row<totalRows; row++) {
System.arraycopy(tileBytes, row * inRowLen,
realTile, row * outRowLen, inRowLen);
realTile, row * descriptor.tileSizeX, inRowLen);
}
writeTile(s, currentPlane, realTile,
currentIndex, currentResolution);
Expand Down

0 comments on commit 13d276b

Please sign in to comment.