Java tutorial
//package com.java2s; //License from project: Open Source License import android.graphics.Bitmap; public class Main { private static int getRGBAdd(Bitmap img, int x, int y) { int value = 0; int rgb = img.getPixel(x, y); value += (rgb >> 16) & 0xFF; value += (rgb >> 8) & 0xFF; value += rgb & 0xFF; return value; } }