Remove discard from GrRenderTarget & force it to always go through a RenderTargetContext
authorRobert Phillips <robertphillips@google.com>
Tue, 11 Apr 2017 16:54:57 +0000 (12:54 -0400)
committerSkia Commit-Bot <skia-commit-bot@chromium.org>
Tue, 11 Apr 2017 19:38:18 +0000 (19:38 +0000)
commit1119dc366e15ef737d05d3a087410ea40c508101
tree0b1363476a28c6df8baf79a46dbee8a74eac48af
parentfafe135349bd34961a12bfd8185733709cd0e45e
Remove discard from GrRenderTarget & force it to always go through a RenderTargetContext

This is a bit sloppy in that it ignores some instances where discards were being issued before.

The creation of the temp RTContext in the RenderTarget's discard method was causing an extra split in the opLists.

This is split out of: https://skia-review.googlesource.com/c/10284/ (Omnibus: Remove GrSurface-derived classes from ops)

Change-Id: Ic366d303280635763b0fae238c4df37c04fb8503
Reviewed-on: https://skia-review.googlesource.com/11125
Commit-Queue: Robert Phillips <robertphillips@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
16 files changed:
gm/xfermodeimagefilter.cpp
include/gpu/GrRenderTarget.h
src/gpu/GrContext.cpp
src/gpu/GrContextPriv.h
src/gpu/GrGpu.cpp
src/gpu/GrPreFlushResourceProvider.cpp
src/gpu/GrRenderTarget.cpp
src/gpu/GrRenderTargetContext.cpp
src/gpu/GrRenderTargetOpList.cpp
src/gpu/GrRenderTargetOpList.h
src/gpu/GrResourceProvider.cpp
src/gpu/ops/GrClearOp.h
src/gpu/ops/GrDiscardOp.h
src/image/SkImage_Gpu.cpp
tests/ProxyRefTest.cpp
tests/RenderTargetContextTest.cpp