public void setPalette(int[] rgb)
		{
			if (rgb.length < 1 * 3 || rgb.length > 256 * 3)
			{
				throw new IllegalArgumentException("PNGEncodeParam0");
			}
			if ((rgb.length % 3) != 0)
			{
				throw new IllegalArgumentException("PNGEncodeParam1");
			}

			palette = (rgb.clone());
			paletteSet = true;
		}