DescriptionThis addresses issue 1805 (Skia Debugger crashes when profiling SkPicture from chrome). The crux of the problem is that SkPicturePlayback::draw uses SkCanvas' quickRejectY method to cull clipped text. This can make the number of commands in the SkDebugCanvas substantially less then the number of commands in the captured skp - breaking a fundamental assumption of the debugger.
This CL patches the problem by setting the debug canvas' clip region to be very large (thus thwarting quickRejectY's culling). I'm not in love with this solution (since it is very side-effecty) but it does limit the changes to the DebugCanvas. The alternative seems to be to add a flag to SkPicturePlayback to optionally disable all optimizations.
Patch Set 1 #
Total comments: 2
Patch Set 2 : Add comment and a debug-only check #
Total comments: 3
Patch Set 3 : switch from round to roundOut #Messages
Total messages: 14 (0 generated)
|