I am trying to understand how the the recently announced "GPU over draw" feature works. Why are certain parts of the screen drawn twice or thrice? How does this really work? Does this have anything to do with nesting of layouts? How to minimize this over draw. In windows phone we have an option like Bitmapcachemode
which will cache the redraw and prevent re drawing over and over again. Is there anything similar to this in Android? (The snippet below is from official Google docs)
With the latest version of glass, developers have an option of turning on GPU over draw.When you turn this setting on, the system will color in each pixel on the screen depending on how many times it was drawn in the last paint cycle. This setting helps you debug performance issues with deeply nested layouts or complex paint logic.
Pixels drawn in their original color were only drawn once. Pixels shaded in blue were drawn twice. Pixels shaded in green were drawn three times. Pixels shaded in light red were drawn four times. Pixels shaded in dark red were drawn five or more times.
Source - Google official docs.