about summary refs log tree commit diff stats
path: root/data/maps/the_bearer/rooms/Green Town.txtpb
blob: fd80201e82964b19fef85d92c2378641617ea6f8 (plain) (blame)
1
name: "Green Town"
lass */ .highlight .vg { color: #dd7700 } /* Name.Variable.Global */ .highlight .vi { color: #3333bb } /* Name.Variable.Instance */ .highlight .vm { color: #336699 } /* Name.Variable.Magic */ .highlight .il { color: #0000DD; font-weight: bold } /* Literal.Number.Integer.Long */
/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package com.fourisland.fourpuzzle.util;

import java.awt.image.RGBImageFilter;

/**
 *
 * @author hatkirby
 */
public class TransparentPixelFilter extends RGBImageFilter {

    private int trans;
    public TransparentPixelFilter(int i)
    {
        trans = i;
        
        canFilterIndexColorModel = true;
    }

    @Override
    public int filterRGB(int x, int y, int rgb)
    {
        if (rgb == trans)
        {
            return 0;
        } else {
            return rgb;
        }
    }

}