Make stream captures work on canvases that are not in the DOM.

This CL refactors part of the internal workings of 2D canvas in order to
decouple the notions animation frame boundaries and paint invalidations.
The two used to be considered as one, which caused frame boundaries to
stop being processed on object not attached to the DOM due to the lack
of paint invalidations.

TBR=kbr@chromium.org, esprehn@chromium.org
BUG=653548
CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_optional_gpu_tests_rel;master.tryserver.chromium.mac:mac_optional_gpu_tests_rel;master.tryserver.chromium.win:win_optional_gpu_tests_rel

Review-Url: https://codereview.chromium.org/2653933003
Cr-Commit-Position: refs/heads/master@{#449845}
22 files changed