get Red - Java 2D Graphics

Java examples for 2D Graphics:Color RGB

Description

get Red

Demo Code


//package com.java2s;

public class Main {
    public static float getRed(int Color) {
        float Red = (float) (Color >> 16 & 255) / 255.0F;
        return Red * 1.0F;
    }//from  w w w. j  av a2 s  .  c o  m
}

Related Tutorials