mirror of
https://github.com/haraldk/TwelveMonkeys.git
synced 2025-08-04 20:15:28 -04:00
Fix reading jpeg images where last scanline is higher than the y
source subsampling offset.
This commit is contained in:
parent
e924fcefc0
commit
822bea80b6
@ -445,6 +445,10 @@ public class JPEGImageReader extends ImageReaderBase {
|
||||
for (int y = srcRegion.y; y < srcMaxY; y += step) {
|
||||
int scan = Math.min(step, srcMaxY - y);
|
||||
|
||||
if(scan <= param.getSubsamplingYOffset()) {
|
||||
param.setSourceSubsampling(param.getSourceXSubsampling(),param.getSourceYSubsampling(),param.getSubsamplingXOffset(),0);
|
||||
}
|
||||
|
||||
// Let the progress delegator handle progress, using corrected range
|
||||
progressDelegator.updateProgressRange(100f * (y + scan) / srcRegion.height);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user