source: osm/applications/editors/josm/plugins/cadastre-fr/src/cadastre_fr/BuildingsImageModifier.java@ 20425

Last change on this file since 20425 was 20390, checked in by pieren, 15 years ago

Many small fixes and improvements

File size: 794 bytes
Line 
1package cadastre_fr;
2
3public class BuildingsImageModifier extends ImageModifier {
4
5 public BuildingsImageModifier() {super();};
6
7 public BuildingsImageModifier(GeorefImage buildings, GeorefImage parcels) {
8 bufferedImage = buildings.image;
9 VectorImageModifier vim = new VectorImageModifier();
10 for (int x = 0; x < bufferedImage.getWidth(); x++) {
11 for (int y = 0; y < bufferedImage.getHeight(); y++) {
12 if (vim.isBuildingOrRoofColor(bufferedImage, x, y, false)
13 && !vim.isBackgroundColor(parcels.image, x, y)) {
14 // create a clear 'cut' for the parcels
15 bufferedImage.setRGB(x, y, parcelColor);
16 }
17 }
18 }
19 }
20
21}
Note: See TracBrowser for help on using the repository browser.