Java examples for 2D Graphics:Color RGB
Color to Green
//package com.java2s; public class Main { public static int toGreen(int rgb) { int g = (rgb >> 8) & 0xFF; return g; }//from w w w . j a v a2 s .c om }