Changeset 14816 in josm for trunk/src/org/openstreetmap
- Timestamp:
- 2019-02-25T20:03:10+01:00 (6 years ago)
- Location:
- trunk/src/org/openstreetmap/josm
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/gui/layer/imagery/ReprojectionTile.java
r14120 r14816 18 18 import org.openstreetmap.josm.tools.ImageWarp; 19 19 import org.openstreetmap.josm.tools.Utils; 20 import org.openstreetmap.josm.tools.bugreport.BugReport; 20 21 21 22 /** … … 166 167 transform = pointTransform; 167 168 } 168 BufferedImage imageOut = ImageWarp.warp( 169 imageIn, getDimension(pbTargetAligned, scale), 170 transform, interpolation); 171 synchronized (this) { 172 this.image = imageOut; 173 this.anchor = new TileAnchor(p00Img, p11Img); 174 this.nativeScale = scale; 175 this.maxZoomReached = scaleFix != null; 169 Dimension targetDim = getDimension(pbTargetAligned, scale); 170 try { 171 BufferedImage imageOut = ImageWarp.warp(imageIn, targetDim, transform, interpolation); 172 synchronized (this) { 173 this.image = imageOut; 174 this.anchor = new TileAnchor(p00Img, p11Img); 175 this.nativeScale = scale; 176 this.maxZoomReached = scaleFix != null; 177 } 178 } catch (NegativeArraySizeException e) { 179 // See #17387 - https://bugs.openjdk.java.net/browse/JDK-4690476 180 throw BugReport.intercept(e).put("targetDim", targetDim); 176 181 } 177 182 } -
trunk/src/org/openstreetmap/josm/tools/ImageWarp.java
r12865 r14816 9 9 import java.util.HashSet; 10 10 import java.util.Map; 11 import java.util.Objects; 11 12 import java.util.Set; 12 13 … … 181 182 break; 182 183 default: 183 throw new AssertionError( );184 throw new AssertionError(Objects.toString(interpolation)); 184 185 } 185 186 imgTarget.setRGB(i, j, rgba);
Note:
See TracChangeset
for help on using the changeset viewer.