aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/effects
Commit message (Collapse)AuthorAge
* Remove asTextureRef from SkSpecialImage & update effects accordinglyGravatar Robert Phillips2017-02-07
| | | | | | | | | This CL also renames SkSpecialImage::asTextureProxy to asTextureProxyRef Change-Id: I5ed8e475bb9688453b825ae4500ed0e8d324b5ac Reviewed-on: https://skia-review.googlesource.com/7995 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Robert Phillips <robertphillips@google.com>
* Use SkArenaAlloc in the SkAutoBlitterChoose code.Gravatar Herb Derby2017-02-07
| | | | | | | | | | | | | | | | | | | - Added default implementation of onMakeContext to support use in android. Searches for uses: "public SkShader" package:^chromium$ -file:^src/third_party/skia package:^aosp.* "public SkShader" -file:external/skia -file:.*third_party/skia package:^android$ "public SkShader" -file:external/skia -file:.*third_party/skia ... shows that no subclass overrides onCreateContext. TBR=reed@google.com TBR=mtklein@google.com Change-Id: I8bd5f57a79534574e344b165d31dccee41c31767 Reviewed-on: https://skia-review.googlesource.com/8140 Commit-Queue: Herb Derby <herb@google.com> Reviewed-by: Herb Derby <herb@google.com>
* SkColorSpace: remove named API, add gamut APIGravatar Matt Sarett2017-02-07
| | | | | | | | | | | Reland from: https://skia-review.googlesource.com/c/8021/ BUG=skia: Change-Id: I18985f130587b15fccbc86b76b2bb5c49ba5ba8a Reviewed-on: https://skia-review.googlesource.com/8136 Reviewed-by: Matt Sarett <msarett@google.com> Commit-Queue: Matt Sarett <msarett@google.com>
* Revert "Use SkArenaAlloc instead of SkSmallAllocator in the ↵Gravatar Robert Phillips2017-02-07
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | SkAutoBlitterChoose code." This reverts commit 2b57b7f7a7fc97db57f190b5a8ebcf68e177ee2d. Reason for revert: Android compile failing Original change's description: > Use SkArenaAlloc instead of SkSmallAllocator in the SkAutoBlitterChoose code. > > > TBR=reed@google.com > Change-Id: Iefb044bf7657fbf982f23aa91a3f4d013ce2c626 > Reviewed-on: https://skia-review.googlesource.com/7786 > Reviewed-by: Mike Klein <mtklein@chromium.org> > Reviewed-by: Herb Derby <herb@google.com> > Commit-Queue: Herb Derby <herb@google.com> > TBR=mtklein@chromium.org,mtklein@google.com,herb@google.com,reed@google.com NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true Change-Id: Id09c35377dddae0811d998b7d0c34c422325a5bc Reviewed-on: https://skia-review.googlesource.com/8129 Commit-Queue: Robert Phillips <robertphillips@google.com> Reviewed-by: Robert Phillips <robertphillips@google.com>
* Revert "SkColorSpace: remove named API, add gamut API"Gravatar Matt Sarett2017-02-07
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit ecaaf6f1c156e5690200322fc2636380c1f63dd8. Reason for revert: Breaks everything Original change's description: > SkColorSpace: remove named API, add gamut API > > BUG=skia: > > Change-Id: I01c5e1874c9a034febc64e25b3aaafb5050393a6 > Reviewed-on: https://skia-review.googlesource.com/8021 > Reviewed-by: Brian Osman <brianosman@google.com> > Reviewed-by: Mike Reed <reed@google.com> > Commit-Queue: Matt Sarett <msarett@google.com> > TBR=msarett@google.com,brianosman@google.com,reed@google.com,reviews@skia.org NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Change-Id: Ief5a0a4eeabe75a21f7512e23fc15309151066c4 Reviewed-on: https://skia-review.googlesource.com/8127 Commit-Queue: Matt Sarett <msarett@google.com> Reviewed-by: Matt Sarett <msarett@google.com>
* SkColorSpace: remove named API, add gamut APIGravatar Matt Sarett2017-02-07
| | | | | | | | | | BUG=skia: Change-Id: I01c5e1874c9a034febc64e25b3aaafb5050393a6 Reviewed-on: https://skia-review.googlesource.com/8021 Reviewed-by: Brian Osman <brianosman@google.com> Reviewed-by: Mike Reed <reed@google.com> Commit-Queue: Matt Sarett <msarett@google.com>
* Use SkArenaAlloc instead of SkSmallAllocator in the SkAutoBlitterChoose code.Gravatar Herb Derby2017-02-07
| | | | | | | | | TBR=reed@google.com Change-Id: Iefb044bf7657fbf982f23aa91a3f4d013ce2c626 Reviewed-on: https://skia-review.googlesource.com/7786 Reviewed-by: Mike Klein <mtklein@chromium.org> Reviewed-by: Herb Derby <herb@google.com> Commit-Queue: Herb Derby <herb@google.com>
* Add GM to exercise some of the darker corners of SkMagnifierImageFilterGravatar Robert Phillips2017-02-07
| | | | | | | | | | | An upcoming CL (https://skia-review.googlesource.com/c/7995/ (Remove asTextureRef from SkSpecialImage & update effects accordingly)) modifies some untested portions of the SkMagnifierImageFilter. This adds a test to prevents regressions. Change-Id: I9fa406f699e39fa393212e7f63a457b015b36edb Reviewed-on: https://skia-review.googlesource.com/8023 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Robert Phillips <robertphillips@google.com>
* Revert "Revert "Don't instantiate shaders with non-invertible local matrix""Gravatar Florin Malita2017-02-03
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 0e86725ba4f667056ff1ef65275165853a47303b. Reason for revert: landed Blink fix, should pass layout tests now Original change's description: > Revert "Don't instantiate shaders with non-invertible local matrix" > > This reverts commit ebfbba9bbdacd754c8ad7429ee066f53f17bc66b. > > Reason for revert: breaks chrome blink tests for linux_trusty_blink_rel > > Original change's description: > > Don't instantiate shaders with non-invertible local matrix > > > > Change-Id: If11f7d57cbf45929632d858f91c02d8f5fa9f442 > > Reviewed-on: https://skia-review.googlesource.com/7885 > > Reviewed-by: Mike Reed <reed@google.com> > > Commit-Queue: Florin Malita <fmalita@chromium.org> > > > > TBR=fmalita@chromium.org,reed@google.com,reviews@skia.org > NOPRESUBMIT=true > NOTREECHECKS=true > NOTRY=true > > Change-Id: I41c5513523c27dc4bad68008f08369185897b7a2 > Reviewed-on: https://skia-review.googlesource.com/7948 > Commit-Queue: Hal Canary <halcanary@google.com> > Reviewed-by: Hal Canary <halcanary@google.com> > TBR=halcanary@google.com,reviews@skia.org,fmalita@chromium.org,reed@google.com NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true Change-Id: I373ea6c61a256fd8cfbfb34f8b2d39a3ff8109db Reviewed-on: https://skia-review.googlesource.com/8003 Commit-Queue: Florin Malita <fmalita@chromium.org> Reviewed-by: Florin Malita <fmalita@chromium.org>
* Revert "Don't instantiate shaders with non-invertible local matrix"Gravatar Hal Canary2017-02-02
| | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit ebfbba9bbdacd754c8ad7429ee066f53f17bc66b. Reason for revert: breaks chrome blink tests for linux_trusty_blink_rel Original change's description: > Don't instantiate shaders with non-invertible local matrix > > Change-Id: If11f7d57cbf45929632d858f91c02d8f5fa9f442 > Reviewed-on: https://skia-review.googlesource.com/7885 > Reviewed-by: Mike Reed <reed@google.com> > Commit-Queue: Florin Malita <fmalita@chromium.org> > TBR=fmalita@chromium.org,reed@google.com,reviews@skia.org NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true Change-Id: I41c5513523c27dc4bad68008f08369185897b7a2 Reviewed-on: https://skia-review.googlesource.com/7948 Commit-Queue: Hal Canary <halcanary@google.com> Reviewed-by: Hal Canary <halcanary@google.com>
* Revert "Replaced all calls to fragmentPosition() with sk_FragCoord"Gravatar Ethan Nicholas2017-02-02
| | | | | | | | | | | | | This reverts commit de4d301881e7fd084f1f0b359ec6f9b2bf8bd4c5. Reason for revert: several Chrome rendering bugs on Mac BUG=skia: Change-Id: I492082b0b7e7c902ede4b598c5809f604d210ce1 Reviewed-on: https://skia-review.googlesource.com/7887 Reviewed-by: Ethan Nicholas <ethannicholas@google.com> Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
* Don't instantiate shaders with non-invertible local matrixGravatar Florin Malita2017-02-02
| | | | | | | Change-Id: If11f7d57cbf45929632d858f91c02d8f5fa9f442 Reviewed-on: https://skia-review.googlesource.com/7885 Reviewed-by: Mike Reed <reed@google.com> Commit-Queue: Florin Malita <fmalita@chromium.org>
* make GR_TEST_UTILS=0 workGravatar Hal Canary2017-02-02
| | | | | | | Change-Id: Icce35140ca08b65217b32e6b1ffc6ad2f38ab37f Reviewed-on: https://skia-review.googlesource.com/7840 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Hal Canary <halcanary@google.com>
* Rationalize GrContext's Gr*Proxy getter namingGravatar Robert Phillips2017-01-30
| | | | | | | | | | | | | | | | | | | | | | | | This CL replaces the entry points: asDeferredSurface asDeferredTexture asDeferredRenderTarget with: GrSurfaceProxy* asSurfaceProxy sk_sp<GrSurfaceProxy> asSurfaceProxyRef GrTextureProxy* asTextureProxy sk_sp<GrTextureProxy> asTextureProxyRef GrRenderTargetProxy* asRenderTargetProxy sk_sp<GrRenderTargetProxy> asRenderTargetProxyRef Change-Id: I7c2b1ea3d702023ff23019815ca13c9ff6f3b32d Reviewed-on: https://skia-review.googlesource.com/7741 Commit-Queue: Robert Phillips <robertphillips@google.com> Reviewed-by: Brian Salomon <bsalomon@google.com>
* Change shadow tessellators to use SkColor and move to util.Gravatar Jim Van Verth2017-01-30
| | | | | | | | | BUG=skia:6119 Change-Id: I4c4a8933c663ccc057596318a06c538175b9f16b Reviewed-on: https://skia-review.googlesource.com/7726 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Jim Van Verth <jvanverth@google.com>
* Make blur utils take GrTextureProxies - take 2Gravatar Robert Phillips2017-01-30
| | | | | | | | | This is a re-land of https://skia-review.googlesource.com/c/7738/ (Make blur utils take GrTextureProxies) with a fix for the Nexus7 Change-Id: I5821a26b1e986daa11d960ae826a1207512cd2a0 Reviewed-on: https://skia-review.googlesource.com/7746 Commit-Queue: Robert Phillips <robertphillips@google.com> Reviewed-by: Robert Phillips <robertphillips@google.com>
* Revert "Make blur utils take GrTextureProxies"Gravatar Robert Phillips2017-01-30
| | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit d0dc05b98b71af43b44f13beba1292db52b75539. Reason for revert: assertion failure on N7 Original change's description: > Make blur utils take GrTextureProxies > > Change-Id: I1c5054de6d9827eece2f73c4c78818b4db0bc611 > Reviewed-on: https://skia-review.googlesource.com/7738 > Reviewed-by: Brian Salomon <bsalomon@google.com> > Commit-Queue: Robert Phillips <robertphillips@google.com> > TBR=bsalomon@google.com,robertphillips@google.com,reviews@skia.org NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true Change-Id: I82d9385e23279db4c7a6757f1224e603e231354c Reviewed-on: https://skia-review.googlesource.com/7744 Commit-Queue: Robert Phillips <robertphillips@google.com> Reviewed-by: Robert Phillips <robertphillips@google.com>
* Make blur utils take GrTextureProxiesGravatar Robert Phillips2017-01-30
| | | | | | | Change-Id: I1c5054de6d9827eece2f73c4c78818b4db0bc611 Reviewed-on: https://skia-review.googlesource.com/7738 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Robert Phillips <robertphillips@google.com>
* Add geometric version of spot shadowGravatar Jim Van Verth2017-01-27
| | | | | | | | | BUG=skia:6119 Change-Id: Ib9770bd88f4eebd68f2d893c5788f966d89f193c Reviewed-on: https://skia-review.googlesource.com/7585 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Jim Van Verth <jvanverth@google.com>
* Raster pipeline support for SkLocalMatrixShader compositionGravatar Florin Malita2017-01-27
| | | | | | | | | | Plumb a local matrix arg to onAppendStages, similar to onCreateContext's ContextRec::fLocalMatrix. Change-Id: I6db3706918733b35eb7a3ae2cc65503223d0cf2d Reviewed-on: https://skia-review.googlesource.com/7653 Commit-Queue: Florin Malita <fmalita@chromium.org> Reviewed-by: Mike Reed <reed@google.com>
* Revert "Revert "Start of rewrite of GrFragmentProcessor optimizations.""Gravatar Brian Salomon2017-01-27
| | | | | | | | | | | This reverts commit 052fd5158f7f85e478a9f87c45fecaacf7d0f5f3. Disables the test (of unused code) until platform-specific issues are addressed. Change-Id: I7aa23a07954fccf382aa07d28afcbffb0bebcd6d Reviewed-on: https://skia-review.googlesource.com/7656 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Brian Salomon <bsalomon@google.com>
* Revert "Start of rewrite of GrFragmentProcessor optimizations."Gravatar Ethan Nicholas2017-01-27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 85eb4226a4cd8c10a0e3f3ba2f3a60efbb2dd61b. Reason for revert: test failures on Windows, e.g. https://chromium-swarm.appspot.com/task?id=33f9527484414110&refresh=10 Original change's description: > Start of rewrite of GrFragmentProcessor optimizations. > > This adds a replacement for computeInvariantOutput buts does not use it yet. The replacement allows for three types of optimizations: > > * known input color -> known output color for GrFP elimination > * tracking of whether all color processors modulate their input for the "tweak alpha" optimziation > * opaqueness tracking > > This loses some of the generality of computInvariantOutput. It does not track the known output status of individual color components (other than opaque alpha). It does not track whether GrFragmentProcessors read their input color. It doesn't allow a processor that will receive non-constant output to advertise that it produces a constant output. These could probably be added back in the unlikely case that they prove valuable. > > Unlike computeInvariantOutput the optimizations are decided at instantiation time and constant colors are expressed as GrColor4f rather than GrColor. > > Change-Id: I684d3f9050693dde2d28154fa695e049ed8cf61a > Reviewed-on: https://skia-review.googlesource.com/7481 > Reviewed-by: Greg Daniel <egdaniel@google.com> > Commit-Queue: Brian Salomon <bsalomon@google.com> > TBR=egdaniel@google.com,bsalomon@google.com,brianosman@google.com NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true Change-Id: I2390df257456013fa74137cb5d7b5a93820c291e Reviewed-on: https://skia-review.googlesource.com/7652 Commit-Queue: Ethan Nicholas <ethannicholas@google.com> Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
* Start of rewrite of GrFragmentProcessor optimizations.Gravatar Brian Salomon2017-01-27
| | | | | | | | | | | | | | | | | This adds a replacement for computeInvariantOutput buts does not use it yet. The replacement allows for three types of optimizations: * known input color -> known output color for GrFP elimination * tracking of whether all color processors modulate their input for the "tweak alpha" optimziation * opaqueness tracking This loses some of the generality of computInvariantOutput. It does not track the known output status of individual color components (other than opaque alpha). It does not track whether GrFragmentProcessors read their input color. It doesn't allow a processor that will receive non-constant output to advertise that it produces a constant output. These could probably be added back in the unlikely case that they prove valuable. Unlike computeInvariantOutput the optimizations are decided at instantiation time and constant colors are expressed as GrColor4f rather than GrColor. Change-Id: I684d3f9050693dde2d28154fa695e049ed8cf61a Reviewed-on: https://skia-review.googlesource.com/7481 Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Brian Salomon <bsalomon@google.com>
* Simplify SkShader::ContextRec::fLocalMatrix handlingGravatar Florin Malita2017-01-26
| | | | | | | | | | | Minor cleanup. R=robertphillips@google.com,reed@google.com Change-Id: I1a27af61e3e3bb5e895c9a3265da6b0408234165 Reviewed-on: https://skia-review.googlesource.com/7632 Commit-Queue: Florin Malita <fmalita@chromium.org> Reviewed-by: Robert Phillips <robertphillips@google.com>
* Move SkGammaColorFilter to tools, limit to sRGBGravatar Brian Osman2017-01-26
| | | | | | | | | | | Similarly, limit GrGammaEffect to sRGB (and rename it). BUG=skia: Change-Id: I88feef11ab7040bca2fa4c2eed71923ded87a0d0 Reviewed-on: https://skia-review.googlesource.com/7375 Commit-Queue: Brian Osman <brianosman@google.com> Reviewed-by: Brian Salomon <bsalomon@google.com>
* Move SkShadowTessellator to GrShadowTessellatorGravatar Jim Van Verth2017-01-25
| | | | | | | | | BUG=skia:6119 Change-Id: I9756b5aeaced1f21a65063470ccb013c7b856f28 Reviewed-on: https://skia-review.googlesource.com/7505 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Jim Van Verth <jvanverth@google.com>
* Add geometric implementation for ambient shadowsGravatar Jim Van Verth2017-01-25
| | | | | | | | | | | Original: https://skia-review.googlesource.com/7273 BUG=skia:6119 Change-Id: Ie7debd7727768f55dafad922a2b8b9fd3a638fda Reviewed-on: https://skia-review.googlesource.com/7500 Commit-Queue: Jim Van Verth <jvanverth@google.com> Reviewed-by: Brian Salomon <bsalomon@google.com>
* Revert "Add geometric implementation for ambient shadows"Gravatar Ethan Nicholas2017-01-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit fdb1bdf1aa4e7f14befcb3acc3f586e7734190ea. Reason for revert: Breaking the roll (see e.g. https://codereview.chromium.org/2652833006) Original change's description: > Add geometric implementation for ambient shadows > > BUG=skia:6119 > > Change-Id: I3140522f223c35fc059a33b593064897485dff7c > Reviewed-on: https://skia-review.googlesource.com/7273 > Reviewed-by: Brian Salomon <bsalomon@google.com> > Commit-Queue: Jim Van Verth <jvanverth@google.com> > TBR=jvanverth@google.com,bsalomon@google.com,robertphillips@google.com,reviews@skia.org,reed@google.com NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia:6119 Change-Id: I307f6084c40e5ba305c38d15b6b433465295553c Reviewed-on: https://skia-review.googlesource.com/7480 Commit-Queue: Ethan Nicholas <ethannicholas@google.com> Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
* Add geometric implementation for ambient shadowsGravatar Jim Van Verth2017-01-24
| | | | | | | | | BUG=skia:6119 Change-Id: I3140522f223c35fc059a33b593064897485dff7c Reviewed-on: https://skia-review.googlesource.com/7273 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Jim Van Verth <jvanverth@google.com>
* Stop tracking whether GrFragmentProcessors read their inputGravatar Brian Salomon2017-01-23
| | | | | | | Change-Id: Id5338901978b97289798eaef873527597bd8dfd6 Reviewed-on: https://skia-review.googlesource.com/7414 Commit-Queue: Brian Salomon <bsalomon@google.com> Reviewed-by: Greg Daniel <egdaniel@google.com>
* SkRasterPipeline: implement support for SkTableColorFilterGravatar Mike Klein2017-01-23
| | | | | | | | | | | | | This adds and uses a byte_tables stage that converts to bytes, looks up in the tables, then converts back to floats. We treat this as color filter as pure math, not considering anything colorspace related: no transfer functions, no gamut to change, etc. Change-Id: If5fefc1bcef61a0fb0ae279002a0dd1547e429ea Reviewed-on: https://skia-review.googlesource.com/7413 Reviewed-by: Brian Osman <brianosman@google.com> Commit-Queue: Mike Klein <mtklein@chromium.org>
* Remove SkColorCubeFilter. It is unused.Gravatar Mike Klein2017-01-21
| | | | | | | Change-Id: Iec5fc759e331de24caea1347f9510917260d379b Reviewed-on: https://skia-review.googlesource.com/7363 Reviewed-by: Mike Reed <reed@google.com> Commit-Queue: Mike Klein <mtklein@chromium.org>
* Continue making Ganesh use absolute texture coordinates - take 2Gravatar Robert Phillips2017-01-20
| | | | | | | | | | | | The idea here is that the GrCoordTransform will actually hold a GrTextureProxy (rather than a GrTexture) and then, in GrGLSLPrimitiveProcessor::GetTransformMatrix, use the instantiated width & height (when uploading the transform matrix) Relanding of: https://skia-review.googlesource.com/c/6977/ Change-Id: Ibc9b9e354f7fc23b1a6e6e4fe7c9fe3cef771c02 Reviewed-on: https://skia-review.googlesource.com/7265 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Robert Phillips <robertphillips@google.com>
* Just clamp to limit-epsilon.Gravatar Mike Klein2017-01-20
| | | | | | | | | | | | | I think the -0.5f was an implementation detail of Herb's bilerp that we don't need here. It happened to also be clamping us to something less than limit (limit-0.5), so we do need to replace that with a little nudge to keep us on tile. Change-Id: I4ebd32e0ad38c724a17dc8bc35d9ea228eeeca32 Reviewed-on: https://skia-review.googlesource.com/7338 Commit-Queue: Mike Klein <mtklein@chromium.org> Reviewed-by: Herb Derby <herb@google.com> Reviewed-by: Florin Malita <fmalita@chromium.org>
* Fix Vulkan crashes on nexus playerGravatar Greg Daniel2017-01-20
| | | | | | | | | | | | This CL enables Vulkan Test bots on the NexusPlayer TBR:bsalomon@google.com BUG=skia: Change-Id: I0cc8b01107afcc84e0cb0631f361f3615fc8dd9b Reviewed-on: https://skia-review.googlesource.com/5681 Reviewed-by: Jim Van Verth <jvanverth@google.com> Commit-Queue: Greg Daniel <egdaniel@google.com>
* SkRasterPipeline impl for 2-stop linear gradientsGravatar Florin Malita2017-01-20
| | | | | | | | | | CQ_INCLUDE_TRYBOTS=skia.primary:Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-SKNX_NO_SIMD Change-Id: Ia2b630cf9c0826fbfc3342707c005030d0529bbc Reviewed-on: https://skia-review.googlesource.com/7186 Commit-Queue: Florin Malita <fmalita@chromium.org> Reviewed-by: Herb Derby <herb@google.com> Reviewed-by: Mike Klein <mtklein@chromium.org>
* Replaced all calls to fragmentPosition() with sk_FragCoordGravatar Ethan Nicholas2017-01-19
| | | | | | | | | BUG=skia: Change-Id: I179576e148ea6caf6e1c40f0a216421898bcb35d Reviewed-on: https://skia-review.googlesource.com/5941 Commit-Queue: Ethan Nicholas <ethannicholas@google.com> Reviewed-by: Brian Salomon <bsalomon@google.com>
* Revert "Continue making Ganesh use absolute texture coordinates"Gravatar Joe Gregorio2017-01-17
| | | | | | | | | | | This reverts commit 4493a9dc9df8cf306a974bde7e0e9c5470ebcdc9. Reason for revert: Continuing failures https://luci-milo.appspot.com/swarming/task/33c693c3539a1410 Change-Id: Id371d6df6a875a5f6872f4ebd91b08a354d949de Reviewed-on: https://skia-review.googlesource.com/7125 Commit-Queue: Joe Gregorio <jcgregorio@google.com> Reviewed-by: Joe Gregorio <jcgregorio@google.com>
* Continue making Ganesh use absolute texture coordinatesGravatar Robert Phillips2017-01-17
| | | | | | | | | The idea here is that the GrCoordTransform will actually hold a GrTextureProxy (rather than a GrTexture) and then, in GrGLSLPrimitiveProcessor::GetTransformMatrix, use the instantiated width & height (when uploading the transform matrix) Change-Id: Ibac3a540fcb1967ceef571157d41c1937acfadf8 Reviewed-on: https://skia-review.googlesource.com/6977 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Robert Phillips <robertphillips@google.com>
* Split ShadowMaskFilter into separate ambient and spot mask filtersGravatar Jim Van Verth2017-01-16
| | | | | | | | | | | | This does not change the public API. BUG=skia:6119 Change-Id: Ibdcd2f8611bc2eec332d8a65e5d51246b89a0a90 Reviewed-on: https://skia-review.googlesource.com/7083 Commit-Queue: Jim Van Verth <jvanverth@google.com> Reviewed-by: Jim Van Verth <jvanverth@google.com> Reviewed-by: Robert Phillips <robertphillips@google.com>
* Remove SkFallbackAlloc and SkFixedAlloc.Gravatar Herb Derby2017-01-16
| | | | | | | | | | | CQ_INCLUDE_TRYBOTS=skia.primary:Test-Ubuntu-Clang-GCE-CPU-AVX2-x86_64-Debug-ASAN;skia.primary:Test-Ubuntu-Clang-GCE-CPU-AVX2-x86_64-Debug-MSAN TBR=reed@google.com Change-Id: I1000dc9ed8ad65b249798759d9af99f47fc237d2 Reviewed-on: https://skia-review.googlesource.com/6809 Reviewed-by: Herb Derby <herb@google.com> Commit-Queue: Herb Derby <herb@google.com>
* Move Android shadow rendering interface to util library.Gravatar Jim Van Verth2017-01-13
| | | | | | | | | BUG=skia:6119 Change-Id: I8318cf2758042ffd0c81c5fa74240acbf7bea61f Reviewed-on: https://skia-review.googlesource.com/6999 Commit-Queue: Jim Van Verth <jvanverth@google.com> Reviewed-by: Brian Salomon <bsalomon@google.com>
* Try out refFoo pattern on GrRenderTargetContextGravatar Robert Phillips2017-01-13
| | | | | | | | Change-Id: Ifae5618f30c2202b9083f479b58556709ff6126a Reviewed-on: https://skia-review.googlesource.com/6990 Commit-Queue: Robert Phillips <robertphillips@google.com> Reviewed-by: Brian Osman <brianosman@google.com> Reviewed-by: Robert Phillips <robertphillips@google.com>
* refFoo variant for getters that naturally have a sk_spGravatar Mike Reed2017-01-12
| | | | | | | | | | BUG=skia: Change-Id: I13afa1b81e8a72d93e45fb4d37228be196b0f388 Reviewed-on: https://skia-review.googlesource.com/6923 Reviewed-by: Florin Malita <fmalita@chromium.org> Reviewed-by: Robert Phillips <robertphillips@google.com> Commit-Queue: Mike Reed <reed@google.com>
* Make GrPaints move their GrProcessor ownership into GrPipelineBuilder.Gravatar Brian Salomon2017-01-11
| | | | | | | | | This makes GrPaints usable only once. In some places we must make copies in order to issue draws with the same paint state. Change-Id: Ie816e5185ce93a064111cad64c6880e1e21184c2 Reviewed-on: https://skia-review.googlesource.com/6844 Reviewed-by: Robert Phillips <robertphillips@google.com> Commit-Queue: Brian Salomon <bsalomon@google.com>
* SkTypes.h : move SkAutoMalloc into SkAutoMalloc.hGravatar Hal Canary2017-01-11
| | | | | | | | | | | | | | | | * SkAutoFree moved to SkTemplates.h (now implmented with unique_ptr). * SkAutoMalloc and SkAutoSMalloc moved to SkAutoMalloc.h * "SkAutoFree X(sk_malloc_throw(N));" --> "SkAutoMalloc X(N);" Revert "Revert 'SkTypes.h : move SkAutoMalloc into SkAutoMalloc.h'" This reverts commit c456b73fef9589bbdc5eb83eaa83e53c357bb3da. Change-Id: Ie2c1a17c20134b8ceab85a68b3ae3e61c24fbaab Reviewed-on: https://skia-review.googlesource.com/6886 Reviewed-by: Hal Canary <halcanary@google.com> Commit-Queue: Hal Canary <halcanary@google.com>
* Revert "SkTypes.h : move SkAutoMalloc into SkAutoMalloc.h"Gravatar Kevin Lubick2017-01-11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit a5494f117086d712855e4b6289c58c92d1549bcf. Reason for revert: Broke Google3 Original change's description: > SkTypes.h : move SkAutoMalloc into SkAutoMalloc.h > > * SkAutoFree moved to SkTemplates.h (now implmented with unique_ptr). > > * SkAutoMalloc and SkAutoSMalloc moved to SkAutoMalloc.h > > * "SkAutoFree X(sk_malloc_throw(N));" --> "SkAutoMalloc X(N);" > > Change-Id: Idacd86ca09e22bf092422228599ae0d9bedded88 > Reviewed-on: https://skia-review.googlesource.com/4543 > Reviewed-by: Ben Wagner <bungeman@google.com> > Reviewed-by: Mike Reed <reed@google.com> > Commit-Queue: Hal Canary <halcanary@google.com> > TBR=halcanary@google.com,bungeman@google.com,reed@google.com,reviews@skia.org NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true Change-Id: Ie8bd176121c3ee83c110d66c0d0ac65e09bfc9c5 Reviewed-on: https://skia-review.googlesource.com/6884 Commit-Queue: Kevin Lubick <kjlubick@google.com> Reviewed-by: Kevin Lubick <kjlubick@google.com>
* SkTypes.h : move SkAutoMalloc into SkAutoMalloc.hGravatar Hal Canary2017-01-11
| | | | | | | | | | | | | | * SkAutoFree moved to SkTemplates.h (now implmented with unique_ptr). * SkAutoMalloc and SkAutoSMalloc moved to SkAutoMalloc.h * "SkAutoFree X(sk_malloc_throw(N));" --> "SkAutoMalloc X(N);" Change-Id: Idacd86ca09e22bf092422228599ae0d9bedded88 Reviewed-on: https://skia-review.googlesource.com/4543 Reviewed-by: Ben Wagner <bungeman@google.com> Reviewed-by: Mike Reed <reed@google.com> Commit-Queue: Hal Canary <halcanary@google.com>
* Start making texture coordinates be absoluteGravatar Robert Phillips2017-01-10
| | | | | | | | | | | The idea here is that we will pass GrTextureProxys in (where we're currently passing GrTextures) and defer the normalization until the texture is actually instantiated (and possibly move it to the GPU entirely) This CL does (intentionally) change the texturedomaineffect GM but I believe the new behavior is more correct. Change-Id: I4e0510b3dfb65ff0d0ee5921f9a6f94151e602d3 Reviewed-on: https://skia-review.googlesource.com/6807 Commit-Queue: Robert Phillips <robertphillips@google.com> Reviewed-by: Brian Salomon <bsalomon@google.com>
* Separate SkArithmeticImageFilter from SkXfermodeImageFilter.Gravatar Brian Salomon2017-01-09
| | | | | | | Change-Id: I145eed7276456b546ca5c66bc1a0f0f74a84f138 Reviewed-on: https://skia-review.googlesource.com/6728 Reviewed-by: Mike Reed <reed@google.com> Commit-Queue: Brian Salomon <bsalomon@google.com>