4.0.4 r1.2中android.graphics.drawable.Drawable源代码


Set to true to have the drawable dither its colors when drawn to a device with fewer than 8-bits per color component. This can improve the look on those devices, but can also slow down the drawing a little.public void setDither(boolean dither) {}


4.0.4 r1.2中android.graphics.drawable.BitmapDrawable源代码


@Overridepublic void setDither(boolean dither) {mBitmapState.mPaint.setDither(dither);invalidateSelf();}


4.0.4 r1.2中android.graphics.Paint源代码


Helper for setFlags(), setting or clearing the DITHER_FLAG bit Dithering affects how colors that are higher precision than the device are down-sampled. No dithering is generally faster, but higher precision colors are just truncated down (e.g. 8888 -> 565). Dithering tries to distribute the error inherent in this process, to reduce the visual artifacts.Parameters:dither true to set the dithering bit in flags, false to clear itpublic native void setDither(boolean dither);


最后调用本地类库进行处理。

更多相关文章

  1. Android(安卓)WebView
  2. Android(安卓)实现简单的刮刮乐
  3. Android中的共享设置(SharedPreferences)
  4. Intent在Android中的几种用法
  5. Android(安卓)GPS架构分析(二)
  6. Android(安卓)通过Intent调用系统功能和Action动作和服务广播【
  7. android入门级小软件身高体重计算器源代码,初学者可以看看~
  8. Android(安卓)Activity的生命周期
  9. Android中调用startActivity结果导致:java.lang.RuntimeException

随机推荐

  1. Android(安卓)Studio插件GenerateFindVie
  2. android-market-api
  3. Android(安卓)Gradle Plugin指南(四)——测
  4. Android(安卓)ApiDemos示例解析(124):Vie
  5. android 同一个界面多个跑马灯实现
  6. Android函数响应式编程——必学的RxJava
  7. android showSoftInput方法调用软键盘不
  8. ActionBarSherlock的使用一
  9. Android(安卓)webView与JavaScript的交互
  10. Android中实现部分字体颜色改变的方式