set Red value for a color - Android Graphics

Android examples for Graphics:Color RGB Value

Description

set Red value for a color

Demo Code


//package com.java2s;
import android.graphics.Color;

public class Main {
    public static int setRed(int color, int value) {
        return Color.argb(Color.alpha(color), value, Color.green(color),
                Color.blue(color));
    }/*ww  w. j  a v a2  s .c  om*/
}

Related Tutorials