page.title=Debug GPU Overdraw Walkthrough
meta.tags="android, performance, profiling, tools, rendering, overdraw"
page.tags="android", "performance", "profiling", "tools", "rendering", "overdraw"
page.metaDescription=Use color-coding to show how many times each pixel is redrawn on the screen to reduce rendering overhead.
page.image=tools/performance/thumbnails/tools_debug_gpu_overdraw.png
page.article=true
@jd:body
In this document
You should also read
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:
- Showing where an app might be doing more rendering work than necessary.
- Helping you see where you might be able to reduce rendering overhead.
Prerequisites
Visualizing Overdraw on your Mobile Device
- On your mobile device, go to Settings and tap Developer Options.
- In the Hardware accelerated rendering section,
select Debug GPU Overdraw.
- In the Debug GPU overdraw popup, select Show overdraw areas.
- 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.
- The colors are hinting at the amount of overdraw on your screen for each pixel, as
follows:
- True color: No overdraw
- Blue: Overdrawn once
- Green: Overdrawn twice
- Pink: Overdrawn three times
- Red: Overdrawn four or more times
- 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.