读书人

取ARGB色彩的分度值

发布时间: 2012-07-18 12:05:40 作者: rapoo

取ARGB颜色的分度值

        private static int getR32(int c) { return (c >>  0) & 0xFF; }        // access the red component from a premultiplied color        private static int getG32(int c) { return (c >>  8) & 0xFF; }        // access the red component from a premultiplied color        private static int getB32(int c) { return (c >> 16) & 0xFF; }        // access the red component from a premultiplied color        private static int getA32(int c) { return (c >> 24) & 0xFF; }
?

读书人网 >移动开发

热点推荐