首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 移动开发 > 移动开发 >

图片放灰处理

2012-06-26 
图片置灰处理1.//像素过滤矩阵2.public final static float[] BT_SELECTED new float[] {3.0.308f, 0.60

图片置灰处理
1.//像素过滤矩阵      
2.public final static float[] BT_SELECTED = new float[] {         
3.    0.308f, 0.609f, 0.082f, 0, 0,       
4.    0.308f, 0.609f, 0.082f, 0, 0,  
5.    0.308f, 0.609f, 0.082f, 0, 0,  
6.    0, 0, 0, 1, 0 
7.};  
8. 
9.Drawable myImage = res.getDrawable(R.drawable.h114);  
10.myImage.mutate();  
11.myImage.clearColorFilter();  
12.myImage.setColorFilter(new ColorMatrixColorFilter(BT_SELECTED)); 

热点排行