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的源代码结构
  2. Android 5.1源代码与Nexus设备工厂镜像下载
  3. Android 自音乐播放器源代码
  4. [1] Android主要源代码组成
  5. Android 实例子源代码文件下载地址380个合集
  6. Android 近百个项目的源代码,覆盖Android开发的每个领域
  7. Android 源代码结构
  8. [置顶] Android 各类功能效果源代码集合

随机推荐

  1. Android 工程报错解决 Unable to resolve
  2. mac os x中android无法连接手机的解决方
  3. Android 设置背景色或者主题。
  4. 【转】Android之大话设计模式与企业级开
  5. ImageButton 和ImageWell 样式的浅析
  6. Android(安卓)Toolbar详解-实现Material
  7. Android EditText 限制输入的字数
  8. Android内核的编译
  9. Activity&Fragment生命周期详解
  10. 一界面相关知识