Changeset 23190 in osm for applications/editors/josm/plugins/cadastre-fr/src/cadastre_fr/ImageModifier.java
- Timestamp:
- 2010-09-15T18:54:18+02:00 (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/cadastre-fr/src/cadastre_fr/ImageModifier.java
r20931 r23190 19 19 20 20 protected int parcelColor = Color.RED.getRGB(); 21 21 22 22 public BufferedImage bufferedImage; 23 23 … … 31 31 new byte[] { (byte) 0, (byte) 0xFF } 32 32 ); 33 33 34 34 BufferedImage dest = new BufferedImage( 35 35 src.getWidth(), src.getHeight(), … … 37 37 icm 38 38 ); 39 39 40 40 ColorConvertOp cco = new ColorConvertOp( 41 41 src.getColorModel().getColorSpace(), … … 43 43 null 44 44 ); 45 45 46 46 cco.filter(src, dest); 47 47 48 48 return dest; 49 49 } … … 72 72 return convert4(src, cmap); 73 73 } 74 74 75 75 /** 76 76 * Converts the source image to 4-bit colour … … 96 96 ); 97 97 cco.filter(src, dest); 98 98 99 99 return dest; 100 100 } 101 101 102 102 protected BufferedImage convert8(BufferedImage src) { 103 103 BufferedImage dest = new BufferedImage( … … 115 115 116 116 public boolean isBuildingColor(int rgb, boolean ignoreParcelColor) { 117 for (int i = 0; i < cBuilingFootColors.length; i++) 117 for (int i = 0; i < cBuilingFootColors.length; i++) 118 118 if (rgb == cBuilingFootColors[i]) 119 119 return true; … … 124 124 125 125 public boolean isRoofColor(int rgb, boolean ignoreParcelColor) { 126 for (int i = 0; i < cRoofColors.length; i++) 126 for (int i = 0; i < cRoofColors.length; i++) 127 127 if (rgb == cRoofColors[i]) 128 128 return true; … … 152 152 return ret; 153 153 } 154 154 155 155 /** 156 156 * Checks if the rgb value is the black background color 157 * @param 157 * @param 158 158 * @return 159 159 */
Note:
See TracChangeset
for help on using the changeset viewer.
