DescriptionSwitch Blink SkShader clients to sk_sp
Skia is migrating its APIs to the new smart pointer type - sk_sp. Among other
benefits, the new type/APIs help avoid atomic ref count churn thanks to
move semantics (ownership can now be transferred into Skia).
1) convert Blink shader wrappers (Gradient, Pattern) to store sk_sp<SkShader>
(instead of RefPtr<SkShader>).
2) use sk_sp factories (MakeFoo instead of CreateFoo)
3) call the sk_sp paint shader setters - setShader(sk_sp<SkShader>) instead of
setShader(SkShader*).
BUG=skia:5077
R=reed@google.com,schenney@chromium.org,junov@chromium.org,senorblanco@chromium.org
Committed: https://crrev.com/12e75e492a66e801b464eefa9b61d1c5058c0c5c
Cr-Commit-Position: refs/heads/master@{#380664}
Patch Set 1 #Patch Set 2 #
Total comments: 8
Patch Set 3 : review comments #Patch Set 4 : one more inlined shader #Patch Set 5 : build fix #Patch Set 6 : rebase after MakePictureShader constness change #Messages
Total messages: 25 (13 generated)
|