skia2/src
Mike Klein 2eae8e53ba only scale shader by paint alpha < 1
This adds `shader && paint alpha < 1.0f` to the blitter Key, so we'll
generate and cache two different programs based on that bit.

I put a little bit of effort into a different approach, wrapping the
shader with a new shader that modulates by paint alpha when paint alpha
is less than one.  This should work, but I realized that it would break
caching, since we're caching based on shader identity.  (Not really
break, but make it ineffective.)

I've added some notes about cache keys in general, and that this wrapper
approach would make caching less effective is I think enough to make me
want to work out a "identify yourself except for uniforms" protocol for
shaders (really effects, eventually color filters will need it too).

Change-Id: I1a2a490657bf7442e79f87d80968302720265f7d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251775
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2019-10-31 15:27:53 +00:00
..
android Reland "Reland "SkSurface asynchronous read APIs allow client to extend pixel lifetime"" 2019-10-03 19:14:22 +00:00
atlastext Rename GrColorSpaceInfo -> GrColorInfo 2019-09-30 21:53:24 +00:00
c Revert "add guard to switch to SkPathTypes" 2019-09-14 19:13:44 +00:00
codec Have SkWuffsCodec use two Wuffs decoders 2019-10-29 22:17:43 +00:00
core only scale shader by paint alpha < 1 2019-10-31 15:27:53 +00:00
effects SkMorphologyImageFilter: Avoid integer overflow with large radii 2019-10-29 18:38:45 +00:00
fonts Add SkUNREACHABLE to definition of SK_ABORT. 2019-08-09 20:43:39 +00:00
gpu Use SkYUVMath in GrYUVtoRGBEffect 2019-10-31 13:20:33 +00:00
image Revert "Implement refPinnedTextureProxy for SkImage_Lazy." 2019-10-29 12:40:06 +00:00
images insist SkPngEncoder's input is initialized 2019-10-14 18:13:37 +00:00
lazy Remove std::move()s from returns of std::unique_ptrs 2019-08-15 23:48:59 +00:00
opts Slightly faster hsl_to_rgb stage 2019-10-24 16:26:02 +00:00
pathops Revert "add guard to switch to SkPathTypes" 2019-09-14 19:13:44 +00:00
pdf Reland "hide color filters from blitters" 2019-10-24 16:57:02 +00:00
ports Don't keep "outResultsFile" open in nanobench 2019-10-24 16:09:02 +00:00
sfnt Add Symbol encoding when renaming a font. 2019-08-07 20:35:28 +00:00
shaders rough sketch of shaders in SkVMBlitter 2019-10-29 21:41:53 +00:00
sksl Rename sampleVariablesSupport() to sampleMaskSupport() 2019-10-30 16:20:47 +00:00
svg Rename SkDevice::ctm() to localToDevice() 2019-10-18 18:04:31 +00:00
utils Rename SkDevice::ctm() to localToDevice() 2019-10-18 18:04:31 +00:00
xml [svgcanvas] Add flag to suppress newlines and tabs in XML 2019-08-21 20:17:37 +00:00
xps Rename SkDevice::ctm() to localToDevice() 2019-10-18 18:04:31 +00:00