Grace Kloba found that LayerRendererChromium was inadvertently causing a copy of the SkBitmap data structure for the root layer's canvas. If the bitmap is using an SkPixelRef internally, this can cause getPixels() to return NULL. The fix is to use a const SkBitmap& like ContentLayerChromium already does.
Created attachment 73925 [details] Patch
Comment on attachment 73925 [details] Patch Good catch!
Committed r72026: <http://trac.webkit.org/changeset/72026>
Accessing pixels() without calling lockPixels() isn't guaranteed to work.
Yeah, this really should call accessBitmap(true) as well, no?
(In reply to comment #4) > Accessing pixels() without calling lockPixels() isn't guaranteed to work. This is definitely true for an ordinary SkBitmap, but what about the bitmaps that are managed by an SkDevice?
(In reply to comment #5) > Yeah, this really should call accessBitmap(true) as well, no? No; the bitmap's pixels are only accessed to upload them to OpenGL, and aren't modified.