Debug GPU Overdraw Walkthrough

  This walkthrough shows how to visualize overdraw on your mobile device by color-coding interface elements based on how often they are drawn underneath.

  What it's good for:

 检测哪个view有过度的绘制。不同颜色含义不同。
    1. Showing where an app might be doing more rendering work than necessary.
    2. Helping you see where you might be able to reduce rendering overhead.

2.Prerequisites

3.Visualizing Overdraw on your Mobile Device

  1. On your mobile device, go to Settings and tap Developer Options.
  2. In the Hardware accelerated rendering section, select Debug GPU Overdraw.
  3. In the Debug GPU overdraw popup, select Show overdraw areas.
    开发者选项->硬件加速渲染->调试 GPU 过度绘制->显示过度绘制区域

       5.1.1版本设置如图: 

       Figure 1. Steps for turning on Debug GPU Overdraw.

  4. Don't panic as your screen turns into a delirium of colors. The coloring is provided to help you diagnose your app's display behavior.        
    打开开发选项中的 调试GPU过度绘制 后,可以通过颜色判断应用各部位view的绘制是否过度。 

       

      Figure 2. Example of Debug GPU Overdraw output.

  5. The colors are hinting at the amount of overdraw on your screen for each pixel, as follows:
    过度绘制情况的好坏通过颜色来表示,从正常颜色,蓝色、绿色、淡红色到红色,分别代表从好到坏(没有过度绘制,1x过度绘制、2x过度绘制、3x过度绘制和超过4x过度绘制)。少量的淡红色可以接受,二红色就是实现有问题,需要解决。
    • True color: No overdraw        正常颜色,没有过度绘制
    • Blue: Overdrawn once       有1次
    • Green: Overdrawn twice         有2次
    • Pink: Overdrawn three times     有3次
    • Red: Overdrawn four or more times  4次以上

        Figure 3. Color key for Debug GPU Overdraw output.

  6. Some overdraw is unavoidable. As you are tuning your app's user interface, the goal is to arrive at a visualization that shows mostly true colors and 1X overdraw in blue.
    有些时候,过度绘制是可以避免不了的,保持在正常颜色和1x过度绘制是可接受的。

    

      Figure 4. Examples of undesirable and desirable Debug GPU Overdraw output.

最新文章

  1. 关于PB调用Microsoft Web Browser控件的一些问题
  2. java多线程系类:JUC线程池:05之线程池原理(四)(转)
  3. 《Java程序设计与数据结构教程(第二版)》学习指导
  4. DOM事件机制进一步理解
  5. jQuery疑惑记录
  6. Maven学习(二) -- 坐标和依赖
  7. bzoj2588
  8. OpenRTSP的使用
  9. 屏幕分辨率(QQVGA、QVGA、VGA、XGA、WXGA、WUXGA和WSXGA+)
  10. css中的字体样式及元素样式
  11. 内核空间和用户空间的分界 PAGE_OFFSET
  12. nuget挂了吗?
  13. procotol.go 源码阅读
  14. response.redirect 与location.href 的区别
  15. 如何在已有的 Web 应用中使用 ReactJS
  16. http协议和telnet指令讲解
  17. Android 指定 Theme
  18. 【19】中间者模式(Mediator Pattern)
  19. JUnit手动设计测试方法以及与Randoop的自动生成测试的比较
  20. 排序基础之归并排序、快排、堆排序、希尔排序思路讲解与Java代码实现

热门文章

  1. hiho一下 第四十九周 欧拉路
  2. js的声明与引入
  3. Ext-js使用指南(总结)
  4. MongoDB小结10 - update【upsert】
  5. java编程思想-复用类
  6. Linux 内核开发 - 内存管理
  7. PHP + Socket 发送http请求进而实现站点灌水
  8. WCF探索之旅(五)——WCF与WebService的异同
  9. 关于jiffies回绕以及time_after,time_before
  10. tesnorflow Conv2DTranspose