Lines Matching defs:maxalpha
45 final int maxalpha;
50 // [0, maxalpha]) into alpha values, which are in [0,256).
53 public PiscesTileGenerator(Renderer r, int maxalpha) {
57 this.alphaMap = getAlphaMap(maxalpha);
58 this.maxalpha = maxalpha;
59 this.maxTileAlphaSum = TILE_SIZE*TILE_SIZE*maxalpha;
62 private static byte[] buildAlphaMap(int maxalpha) {
63 byte[] alMap = new byte[maxalpha+1];
64 int halfmaxalpha = maxalpha>>2;
65 for (int i = 0; i <= maxalpha; i++) {
66 alMap[i] = (byte) ((i * 255 + halfmaxalpha) / maxalpha);
71 public static byte[] getAlphaMap(int maxalpha) {
72 if (!alphaMapsCache.containsKey(maxalpha)) {
73 alphaMapsCache.put(maxalpha, buildAlphaMap(maxalpha));
75 return alphaMapsCache.get(maxalpha);
186 System.out.println("maxalpha = "+maxalpha);
208 System.out.println("maxalpha = "+maxalpha);