aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/shaders
Commit message (Collapse)AuthorAge
* Remove gradient onGetGLSLProcessorKey() overridesGravatar Florin Malita2017-11-03
| | | | | | | | | | | None of the gradient processor subclassess contributes anything to the base class key. Relocate the key logic to GrGradientEffect, and remove unneeded builerplate. Change-Id: I6b33ad359212579adedf95c0c3d481373c83d4c4 Reviewed-on: https://skia-review.googlesource.com/67721 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Florin Malita <fmalita@chromium.org>
* Streamline legacy gradient color conversionGravatar Florin Malita2017-11-01
| | | | | | | | | | | | | | | | To produce colors for interpolation in legacy mode, we currently do something like SkColor c = Sk4f_toS32(swizzle_rb(Sk4f::Load(c4f))); color4f = swizzle_rb(SkNx_cast<float>(Sk4b::Load(&c)) * (1/255.0f)); Let's see if we can streamline some of that. Change-Id: I423b5aa8c2df8d115cc236d5f0a2e79923a9c2cc Reviewed-on: https://skia-review.googlesource.com/66142 Commit-Queue: Florin Malita <fmalita@chromium.org> Reviewed-by: Mike Klein <mtklein@chromium.org> Reviewed-by: Brian Osman <brianosman@google.com>
* Gradient cleanup passGravatar Florin Malita2017-11-01
| | | | | | | | | | | 1) replace manual storage management with SkAutoSTMalloc 2) simplify explicit positions processing (remove redundant branch) Change-Id: I7841e2018ac421768ed1d61c4e3ef6a1d28f6244 Reviewed-on: https://skia-review.googlesource.com/66146 Reviewed-by: Brian Osman <brianosman@google.com> Commit-Queue: Florin Malita <fmalita@chromium.org>
* Don't store legacy colors in gradient shadersGravatar Florin Malita2017-10-31
| | | | | | | | | | | | We only pass linear/4f colors to the ctor, and then derive the legacy colors from them. Might as well just derive when needed. Change-Id: I82b3d159da91f6faa4a3e7d681763c0ec1cdab07 Reviewed-on: https://skia-review.googlesource.com/65680 Commit-Queue: Florin Malita <fmalita@chromium.org> Reviewed-by: Brian Osman <brianosman@google.com>
* Add support for transfer functions to GrColorSpaceXformGravatar Brian Osman2017-10-31
| | | | | | | | | | | | | | | | | | | With this change, untagged sources (eg N32) are treated as sRGB data, which causes a huge number of GMs to render more correctly in GPU sRGB/F16/etc... configs. Also, because the sources are treated as having a color space, we actually do gamut conversion for wide or narrow gamut outputs. This change also applies the transfer function math to individual colors in the case of gradient stops and color shaders. (The CPU backend doesn't do this yet, but I think we've decided there's no reason not to support it). Bug: skia: Change-Id: If76e9e4a268f9f74110ff4bbe4fe189ba5d19d9f Reviewed-on: https://skia-review.googlesource.com/64100 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Brian Osman <brianosman@google.com>
* Remove gradient SkFixed position recordsGravatar Florin Malita2017-10-30
| | | | | | | | | | At this point they are only used to build a cache key. Replace with float positions and delete the supporting code. Change-Id: Ida12fd39ed3f612a807de4505c7398838e0693be Reviewed-on: https://skia-review.googlesource.com/64940 Reviewed-by: Brian Osman <brianosman@google.com> Commit-Queue: Florin Malita <fmalita@chromium.org>
* Re-land: Stop using fixed point recs for gradient positioning infoGravatar Florin Malita2017-10-28
| | | | | | | | | | | | | The fixed point gradient records are historical relics. Instead of round-tripping through FP, just use the float positions directly. We can remove the recs completely in a follow-up. TBR= Change-Id: Ic3c8e58af6dfa76744799513c9e60af0462014d0 Reviewed-on: https://skia-review.googlesource.com/64680 Reviewed-by: Florin Malita <fmalita@chromium.org> Commit-Queue: Florin Malita <fmalita@chromium.org>
* Revert "Stop using fixed point recs for gradient positioning info"Gravatar Florin Malita2017-10-26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 97293503f50d01d7e5054d7a1f9d93644cce9964. Reason for revert: some wacky diffs Original change's description: > Stop using fixed point recs for gradient positioning info > > The fixed point gradient records are historical relics. Instead of > round-tripping through FP, just use the float positions directly. > > We can remove the recs completely in a follow-up, after rebaselining the > existing clients. > > Change-Id: I85d1e0f469006de320dbc842f50e69bcbb3aa668 > Reviewed-on: https://skia-review.googlesource.com/64102 > Reviewed-by: Brian Osman <brianosman@google.com> > Commit-Queue: Florin Malita <fmalita@chromium.org> TBR=brianosman@google.com,fmalita@chromium.org,reed@google.com Change-Id: I37bf9b6a358eb09d7d0cf737beb9c1bd994fd736 No-Presubmit: true No-Tree-Checks: true No-Try: true Reviewed-on: https://skia-review.googlesource.com/64103 Reviewed-by: Florin Malita <fmalita@chromium.org> Commit-Queue: Florin Malita <fmalita@chromium.org>
* Stop using fixed point recs for gradient positioning infoGravatar Florin Malita2017-10-26
| | | | | | | | | | | | | The fixed point gradient records are historical relics. Instead of round-tripping through FP, just use the float positions directly. We can remove the recs completely in a follow-up, after rebaselining the existing clients. Change-Id: I85d1e0f469006de320dbc842f50e69bcbb3aa668 Reviewed-on: https://skia-review.googlesource.com/64102 Reviewed-by: Brian Osman <brianosman@google.com> Commit-Queue: Florin Malita <fmalita@chromium.org>
* Tweak gradient shader code to avoid hangs on Tegra3Gravatar Brian Osman2017-10-26
| | | | | | | | | Bug: skia: Change-Id: I07d638d5f7b399d279f445c8f2b490ea55414e2f Reviewed-on: https://skia-review.googlesource.com/64101 Reviewed-by: Mike Klein <mtklein@chromium.org> Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Brian Osman <brianosman@google.com>
* Delete GradientShaderCacheGravatar Florin Malita2017-10-26
| | | | | | | | | Dead code. Change-Id: If415e603b8e898da72ad95f32596445900794d23 Reviewed-on: https://skia-review.googlesource.com/63562 Reviewed-by: Brian Osman <brianosman@google.com> Commit-Queue: Florin Malita <fmalita@chromium.org>
* Stop using GradientShaderCache for gradient texturesGravatar Florin Malita2017-10-25
| | | | | | | | | | | | | | | | | Ganesh uses GradientShaderCache for generating legacy gradient textures, and a custom helper (initLinearBitmap) for all other cases. Now that GradientShaderCache no longer supports dithering, there is little difference between the two implementantions. And sice the result is also cached in a separate bitmap cache, we might as well consolidate the implementation and always use initLinearBitmap. This allows us to completely remove GradientShaderCache in a follow up. Change-Id: Ie05d15132a6116d2f139f066b81fcfbc9e22d7b6 Reviewed-on: https://skia-review.googlesource.com/63741 Reviewed-by: Brian Osman <brianosman@google.com> Commit-Queue: Florin Malita <fmalita@chromium.org>
* Pass GrRenderTargetContext's GrColorSpaceInfo to SkShader and SkColorFilter.Gravatar Brian Salomon2017-10-25
| | | | | | | | | | | | | | Also to SkColorTo(Premul|Unpremul)GrColor4f. This can avoid cache lookups to find GrColorSpaceXforms as the xform pointer is stored in GrColorSpaceInfo after the first lookup. Also uses GrColorSpaceInfo to construct GrTextUtils::Paint. Bug: skia: Change-Id: Idf19d512a60d2269e6921c7fb54d93aee499a70d Reviewed-on: https://skia-review.googlesource.com/63660 Commit-Queue: Brian Salomon <bsalomon@google.com> Reviewed-by: Brian Osman <brianosman@google.com>
* Remove unused (?) gradient context classGravatar Brian Osman2017-10-25
| | | | | | | | Bug: skia: Change-Id: Id8a561e8d95fb0405cba2f2a5c3165667344579e Reviewed-on: https://skia-review.googlesource.com/63860 Reviewed-by: Florin Malita <fmalita@chromium.org> Commit-Queue: Brian Osman <brianosman@google.com>
* Remove GrColorSpaceXform from GrGradientEffectGravatar Brian Osman2017-10-25
| | | | | | | | | | | | | | Use a local xform to convert color stops for analytic gradients. For texture-based gradients, wrap the FP with an xform effect. To simplify this code, add a new AdjustFP helper to do the color xform, and also add the MulOutputByInputAlpha stage. Bug: skia: Change-Id: Icde19b5ec1c66aae76f894e9978c90a5f00c852e Reviewed-on: https://skia-review.googlesource.com/62500 Reviewed-by: Florin Malita <fmalita@chromium.org> Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Brian Osman <brianosman@google.com>
* Remove GradientShaderCache dither and paint alpha supportGravatar Florin Malita2017-10-25
| | | | | | | | | | | | The gradient cache is only used for complex GPU gradients, and is always initialized with no dithering and opaque alpha. Remove the (now-dead) code supporing ditherning and non-opaque alpha. Change-Id: Iad694fa760e9a236efadd4cf92fbc7f8bcacadbe Reviewed-on: https://skia-review.googlesource.com/63520 Reviewed-by: Brian Osman <brianosman@google.com> Commit-Queue: Florin Malita <fmalita@chromium.org>
* Avoid double-dithering of legacy/gpu gradientsGravatar Florin Malita2017-10-24
| | | | | | | | | | | | The GPU backend is the only remaining user of getGradientTableBitmap(). But with Ganesh, dithering is applied as a separate GrPaint effect => we must not pre-dither the gradient texture also. Change-Id: Icc47c1e762c4913205b3715512894d3d2c3b7659 Reviewed-on: https://skia-review.googlesource.com/63261 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Florin Malita <fmalita@chromium.org>
* Remove color space xform support from SkSLGravatar Brian Osman2017-10-23
| | | | | | | | Bug: skia: Change-Id: Ia50c1f750e4626211f012ae7543db126b10134c3 Reviewed-on: https://skia-review.googlesource.com/61906 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Brian Osman <brianosman@google.com>
* Remove dead SK_SUPPORT_LEGACY_PICTURESHADER_ROUNDING codeGravatar Florin Malita2017-10-23
| | | | | | | | | This flag is no longer used. Change-Id: I239e756f7945f0848d12409f0eb8d3077651a4cf Reviewed-on: https://skia-review.googlesource.com/62740 Reviewed-by: Brian Osman <brianosman@google.com> Commit-Queue: Florin Malita <fmalita@chromium.org>
* Add clamped/unclamped xform to GrColorSpaceXformGravatar Brian Osman2017-10-20
| | | | | | | | | | | Use that in analytic gradient setup for future-proofing. Also fixed several out-of-date comments in gradient code. Bug: skia: Change-Id: I79726cad786c22f80e08cdc2b7a1e15ae27ecd5a Reviewed-on: https://skia-review.googlesource.com/62320 Reviewed-by: Mike Klein <mtklein@chromium.org> Commit-Queue: Brian Osman <brianosman@google.com>
* make skmatrix getmapproc privateGravatar Cary Clark2017-10-20
| | | | | | | | | | | | | | Make SkMatrix MapXYProc MapPtsProc and friends private. Code search turned up no clients in chromium, google3, android. Fingers crossed. R:reed@google.com Bug: skia:6898 Change-Id: Iee20fe5150499215a09f67cc6f117b685f38f455 Reviewed-on: https://skia-review.googlesource.com/62140 Commit-Queue: Cary Clark <caryclark@google.com> Reviewed-by: Mike Reed <reed@google.com> Reviewed-by: Florin Malita <fmalita@chromium.org>
* Simplify GrGradientEffect color handlingGravatar Brian Osman2017-10-19
| | | | | | | | | | | | | For analytic gradients, hoist the byte -> float, premultiplication, and color space transformation to creation time. Eliminates second array (only one was ever used), and four different onSetData helpers. Bug: skia: Change-Id: Ib5740b37ef2a5dcf2551e85b1e72f64d8cbcc5fa Reviewed-on: https://skia-review.googlesource.com/62120 Commit-Queue: Brian Osman <brianosman@google.com> Reviewed-by: Florin Malita <fmalita@chromium.org> Reviewed-by: Brian Salomon <bsalomon@google.com>
* Avoid 2PtConical gradient flippingGravatar Florin Malita2017-10-19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently, when startRadius > endRadius conical gradients are inverting their data (start/end points and radii, colors and positions) to guarantee r0 < r1 at raster time. But the radii ordering is only mildly interesting to the impl: it controls which of the two quadratic solutions we select for the inside case, but doesn't fundamentally change the algorithm. Furthermore, for the "outside" case, inverting the order is already inconvenient and needs to be taken into account (both CPU/GPU impls are already tracking this bit of info). Instead of transforming the gradient definition, we can detect the inverted case and adjust the quadratic solution selector. In practice this means: * |edge| case - no change, the equation is linear * |inside| case - select the smaller root instead of largest * |outside| case - [gpu-only] invert the clamp/limiting function Change-Id: Ie3106464e39a4dd3848dc43671d973f7e1958e63 Reviewed-on: https://skia-review.googlesource.com/61660 Reviewed-by: Brian Salomon <bsalomon@google.com> Reviewed-by: Mike Klein <mtklein@chromium.org> Reviewed-by: Mike Reed <reed@google.com> Commit-Queue: Florin Malita <fmalita@chromium.org>
* Remove color space xform from GrTextureDomain & GrSimpleTextureEffectGravatar Brian Osman2017-10-18
| | | | | | | | Bug: skia: Change-Id: I31435d334da28cce9bbc654c4b98746b03078897 Reviewed-on: https://skia-review.googlesource.com/61460 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Brian Osman <brianosman@google.com>
* Feed seed_shader() iota through a context pointer.Gravatar Mike Klein2017-10-18
| | | | | | | | | | As this array grows longer it causes troublesome code generation when we're compiling offline, but it's easy as an argument. Change-Id: I53526443f534f29d3bff17c3aec24a9e916c9b86 Reviewed-on: https://skia-review.googlesource.com/60564 Commit-Queue: Mike Klein <mtklein@chromium.org> Reviewed-by: Herb Derby <herb@google.com>
* Convert more code to use color space xform FPGravatar Brian Osman2017-10-18
| | | | | | | | | | | Special images, image shaders, and all texture producers, as well as bicubic (which simplifies factory call sites). Bug: skia: Change-Id: I3f7c178060f25db8b659fe66e132f5ea066317b1 Reviewed-on: https://skia-review.googlesource.com/61261 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Brian Osman <brianosman@google.com>
* Remove trailing whitespace.Gravatar Ben Wagner2017-10-09
| | | | | | | | | | | Also adds a presubmit to prevent adding trailing whitespace to source code in the future. Change-Id: I41a4df81487f6f00aa19b188f0cac6a3377efde6 Reviewed-on: https://skia-review.googlesource.com/57380 Reviewed-by: Ravi Mistry <rmistry@google.com> Reviewed-by: Mike Reed <reed@google.com> Commit-Queue: Ben Wagner <bungeman@google.com>
* initClassID no longer auto-allocates idsGravatar Ethan Nicholas2017-10-09
| | | | | | | | | | | | | Auto-allocated IDs mean that the IDs depend upon the order in which classes happen to get initialized and are therefore not consistent from run to run. This change paves the way for a persistent shader cache by fixing the IDs in an enum. Bug: skia: Change-Id: I3e923c6c54f41b3b3eb616458abee83e0909c09f Reviewed-on: https://skia-review.googlesource.com/56401 Commit-Queue: Ethan Nicholas <ethannicholas@google.com> Reviewed-by: Brian Salomon <bsalomon@google.com>
* Fold clamp_{x,y} into the gathers.Gravatar Mike Klein2017-09-22
| | | | | | | | | | | | | | | | | | | All three image tile modes go through exclusive_clamp() and then a gather today, so we can move the work of exclusive_clamp() into eac gather_ stage, eliminating the need for clamp_{x,y} stages. Luckily, we've got a convenient place to bottleneck this, ptr_and_ix(), which works out the pointer and vector of indices to load for gathers. This deletes SkRasterPipeline_repeat_tiling unit test, which now no longer exactly makes sense. It tests that repeat_x does that clamp, but that's now done automatically outside that stage. Change-Id: I24637ef60921bec7aa00082984c0c6a49dd86ca9 Reviewed-on: https://skia-review.googlesource.com/50260 Commit-Queue: Mike Klein <mtklein@chromium.org> Reviewed-by: Mike Reed <reed@google.com> Reviewed-by: Florin Malita <fmalita@chromium.org>
* switched SkSL's temporary 'highfloat' type back to 'float'Gravatar Ethan Nicholas2017-09-22
| | | | | | | | Bug: skia: Change-Id: If0debae7318b6b5b4a7cb85d458996a09931127e Reviewed-on: https://skia-review.googlesource.com/48760 Commit-Queue: Ethan Nicholas <ethannicholas@google.com> Reviewed-by: Brian Salomon <bsalomon@google.com>
* re-land of new SkSL precisionsGravatar Ethan Nicholas2017-09-18
| | | | | | | | Bug: skia: Change-Id: Ic1deb3db2cbda6ca45f93dee99832971a36a2119 Reviewed-on: https://skia-review.googlesource.com/47841 Commit-Queue: Ethan Nicholas <ethannicholas@google.com> Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
* Delete the legacy linear gradient implGravatar Florin Malita2017-09-18
| | | | | | | | | | Dead code at this point. Change-Id: I0eb705195446ec084ead49c9f712bf19d8892305 Reviewed-on: https://skia-review.googlesource.com/48020 Reviewed-by: Herb Derby <herb@google.com> Reviewed-by: Mike Klein <mtklein@google.com> Commit-Queue: Mike Klein <mtklein@google.com>
* Revert "Revert "Revert "Switched highp float to highfloat and mediump float ↵Gravatar Ethan Nicholas2017-09-18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | to half.""" This reverts commit 05d5a13fea6246648de7e41358ed338d53c85ea2. Reason for revert: looks like it broke filterfastbounds Original change's description: > Revert "Revert "Switched highp float to highfloat and mediump float to half."" > > This reverts commit 1d816b92bb7cf2258007f3f74ffd143b89f25d01. > > Bug: skia: > Change-Id: I388b5e5e9bf619db48297a80c9a80c039f26c9f1 > Reviewed-on: https://skia-review.googlesource.com/46464 > Reviewed-by: Brian Salomon <bsalomon@google.com> > Commit-Queue: Ethan Nicholas <ethannicholas@google.com> TBR=bsalomon@google.com,ethannicholas@google.com # Not skipping CQ checks because original CL landed > 1 day ago. Bug: skia: Change-Id: Iddf6aef2ab084aa73da7ceebdfc303a1d2b80cde Reviewed-on: https://skia-review.googlesource.com/47441 Reviewed-by: Ethan Nicholas <ethannicholas@google.com> Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
* Revert "Revert "Switched highp float to highfloat and mediump float to half.""Gravatar Ethan Nicholas2017-09-15
| | | | | | | | | | This reverts commit 1d816b92bb7cf2258007f3f74ffd143b89f25d01. Bug: skia: Change-Id: I388b5e5e9bf619db48297a80c9a80c039f26c9f1 Reviewed-on: https://skia-review.googlesource.com/46464 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
* make most of SkColorPriv.h privateGravatar Cary Clark2017-09-15
| | | | | | | | | | | | | created new file src/core/SkColorData.h for internal consumption. Note that many of the functions there are unused as well. Bug: skia: 6898 R: reed@google.com Change-Id: I25bfd5a9c21f53558c4ca65a77eb5d322d897c6d Reviewed-on: https://skia-review.googlesource.com/46848 Commit-Queue: Cary Clark <caryclark@google.com> Reviewed-by: Mike Reed <reed@google.com>
* Remove symmetric three stop special caseGravatar Brian Osman2017-09-12
| | | | | | | | | | | | Just let the general three-stop shader handle all three-stop gradients. Also, pre-compute values derived from the middle stop to remove all division (and actually convert computation to FMA form). Bug: skia: Change-Id: I1aae069d929d1a942c38aa2e2f3fd5fb7d9b2f10 Reviewed-on: https://skia-review.googlesource.com/45800 Commit-Queue: Brian Osman <brianosman@google.com> Reviewed-by: Robert Phillips <robertphillips@google.com>
* Add general three-stop analytic gradient shaderGravatar Brian Osman2017-09-11
| | | | | | | | | | | | | | | | This fixes an Android rendering bug where radial gradients were being used for "clipping" (via DstIn blend mode). The gradient stops were placed at (0, 0.999, 1), which caused our table quantization to drop the last stop. kThree_ColorType now means "0, any t, 1". The old (special-case) kThree_ColorType is now called kSymmetricThree_ColorType. Bug: skia: Change-Id: I96a0b9e679f2d537862a3e097f7e3446474914ea Reviewed-on: https://skia-review.googlesource.com/45260 Reviewed-by: Robert Phillips <robertphillips@google.com> Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Brian Osman <brianosman@google.com>
* Rework GrSamplerParams to be more compact and use its own wrap mode enum.Gravatar Brian Salomon2017-09-07
| | | | | | | | | The main change is to make GrSamplerParams smaller by making its enums have byte-sized underlying types. The rest is cosmetic. Change-Id: Ib71ea50612d24619a85e463826c6b8dfb9b445e3 Reviewed-on: https://skia-review.googlesource.com/43200 Commit-Queue: Brian Salomon <bsalomon@google.com> Reviewed-by: Greg Daniel <egdaniel@google.com>
* fold params into StageRecGravatar Mike Reed2017-08-29
| | | | | | | | | | | | | pre-CL before trying to add a hint-rect field to allow shaders to "optimize" their stages for a given restriction in device space - e.g. if the shader's intrinsic domain is contained, it won't need to tile/clamp Bug: skia: Change-Id: Ia2da557691da25f31e4b9e3f53c3bc6709b89083 Reviewed-on: https://skia-review.googlesource.com/40224 Reviewed-by: Mike Klein <mtklein@google.com> Commit-Queue: Mike Reed <reed@google.com>
* Use the 4f impl for legacy/8888 linear gradientsGravatar Florin Malita2017-08-29
| | | | | | | | | | | | | | | This is a partial revert of https://skia-review.googlesource.com/c/20280, adding back L32 support for 4f gradients and switching off the legacy impl. If it sticks, we should be able to completely delete the legacy gradient code. Change-Id: Iaa6d722ea4dfd8e4d959bb76eca815a30ca7098f Reviewed-on: https://skia-review.googlesource.com/31425 Reviewed-by: Herb Derby <herb@google.com> Reviewed-by: Mike Reed <reed@google.com> Commit-Queue: Florin Malita <fmalita@chromium.org>
* remove code associated with legacy affine imageshadersGravatar Mike Reed2017-08-23
| | | | | | | | | | | requires https://skia-review.googlesource.com/c/33180 CQ_INCLUDE_TRYBOTS=skia.primary:Test-Debian9-GCC-GCE-CPU-AVX2-x86_64-Release-SKNX_NO_SIMD Bug: skia: Change-Id: I226e120cc5aebe393bda8bc069e7927fdc981a0e Reviewed-on: https://skia-review.googlesource.com/36800 Commit-Queue: Mike Reed <reed@google.com> Reviewed-by: Florin Malita <fmalita@chromium.org>
* use rasterpipeline if localmatrix is rotated or skewed for imagesGravatar Mike Reed2017-08-21
| | | | | | | | | Bug: skia: Change-Id: Ib269b5b9d79b055fe614aaacfd7e0d05d48f6085 Reviewed-on: https://skia-review.googlesource.com/33180 Commit-Queue: Mike Reed <reed@google.com> Reviewed-by: Yuqian Li <liyuqian@google.com> Reviewed-by: Florin Malita <fmalita@chromium.org>
* remove unused flag for rotated imageshadersGravatar Mike Reed2017-08-21
| | | | | | | | Bug: skia: Change-Id: I9066ec33a9742f6937cc61ff0afafd13af809222 Reviewed-on: https://skia-review.googlesource.com/36741 Reviewed-by: Florin Malita <fmalita@chromium.org> Commit-Queue: Mike Reed <reed@google.com>
* Add back raster pipeline image tiling guardGravatar Florin Malita2017-08-18
| | | | | | | | | | | | | (SK_SUPPORT_LEGACY_TILED_BITMAPS) We have a couple of M61 regressions related to this change. Adding the guard back in case we decide to revert. TBR= Change-Id: I0703e61d70aa919b71ff9711ec28bcfc67e3e84a Reviewed-on: https://skia-review.googlesource.com/36120 Reviewed-by: Florin Malita <fmalita@chromium.org> Commit-Queue: Florin Malita <fmalita@chromium.org>
* Revert "Switched highp float to highfloat and mediump float to half."Gravatar Brian Salomon2017-08-17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 88d99c63878c2d3d340120f0321676f72afcb4f0. Reason for revert: Believed to be causing unit test failures in Chrome roll: https://build.chromium.org/p/tryserver.chromium.android/builders/linux_android_rel_ng/builds/364433 https://luci-logdog.appspot.com/v/?s=chromium%2Fbb%2Ftryserver.chromium.android%2Flinux_android_rel_ng%2F364433%2F%2B%2Frecipes%2Fsteps%2Fcontent_browsertests__with_patch__on_Android%2F0%2Flogs%2FWebRtcCaptureFromElementBrowserTest.VerifyCanvasWebGLCaptureColor%2F0 Original change's description: > Switched highp float to highfloat and mediump float to half. > > The ultimate goal is to end up with "float" and "half", but this > intermediate step uses "highfloat" so that it is clear if I missed a > "float" somewhere. Once this lands, a subsequent CL will switch all > "highfloats" back to "floats". > > Bug: skia: > Change-Id: Ia13225c7a0a0a2901e07665891c473d2500ddcca > Reviewed-on: https://skia-review.googlesource.com/31000 > Commit-Queue: Ethan Nicholas <ethannicholas@google.com> > Reviewed-by: Brian Salomon <bsalomon@google.com> TBR=bsalomon@google.com,csmartdalton@google.com,ethannicholas@google.com Change-Id: I8bfa97547ac3920d433665f161d27df3f15c83aa No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: skia: Reviewed-on: https://skia-review.googlesource.com/35705 Commit-Queue: Brian Salomon <bsalomon@google.com> Reviewed-by: Brian Salomon <bsalomon@google.com>
* Switched highp float to highfloat and mediump float to half.Gravatar Ethan Nicholas2017-08-16
| | | | | | | | | | | | | The ultimate goal is to end up with "float" and "half", but this intermediate step uses "highfloat" so that it is clear if I missed a "float" somewhere. Once this lands, a subsequent CL will switch all "highfloats" back to "floats". Bug: skia: Change-Id: Ia13225c7a0a0a2901e07665891c473d2500ddcca Reviewed-on: https://skia-review.googlesource.com/31000 Commit-Queue: Ethan Nicholas <ethannicholas@google.com> Reviewed-by: Brian Salomon <bsalomon@google.com>
* Replace SkFAIL with SK_ABORT.Gravatar Ben Wagner2017-08-16
| | | | | | | | | | | | SkFAIL is a legacy macro which is just SK_ABORT. This CL mechanically changes uses of SkFAIL to SK_ABORT in preparation for its removal. The related sk_throw macro will be changed independently, due to needing to actually clean up its users. Change-Id: Id70b5c111a02d2458dc60c8933f444df27d9cebb Reviewed-on: https://skia-review.googlesource.com/35284 Reviewed-by: Derek Sollenberger <djsollen@google.com> Commit-Queue: Ben Wagner <bungeman@google.com>
* Make GrFragmentProcessor be non-refcounted and use std::unique_ptr.Gravatar Brian Salomon2017-08-11
| | | | | | | Change-Id: I985e54a071338e99292a5aa2f42c92bc115b4008 Reviewed-on: https://skia-review.googlesource.com/32760 Commit-Queue: Brian Salomon <bsalomon@google.com> Reviewed-by: Brian Osman <brianosman@google.com>
* use rasterpipeline for images if matrix is >= scale+translateGravatar Mike Reed2017-08-08
| | | | | | | | | Bug: skia: Change-Id: I36112fe54c6f2d0965d0b88f0291d7ffe0902715 Reviewed-on: https://skia-review.googlesource.com/30480 Commit-Queue: Mike Reed <reed@google.com> Reviewed-by: Mike Klein <mtklein@chromium.org> Reviewed-by: Florin Malita <fmalita@chromium.org>
* Remove unneeded GrGradientEffect Tegra3 workaroundGravatar Florin Malita2017-08-08
| | | | | | | | | | | | The workaround for canUseMinAndAbsTogether() is implemented in GLSLCodeGenerator, so presumably not needed here. (https://cs.chromium.org/chromium/src/third_party/skia/src/sksl/SkSLGLSLCodeGenerator.cpp?rcl=0ac06e47269a40c177747310a613d213c95d1d6d&l=223) Change-Id: Id8179ff17b929ed2d79ef9463c0f2008f3591b00 Reviewed-on: https://skia-review.googlesource.com/32181 Reviewed-by: Ethan Nicholas <ethannicholas@google.com> Commit-Queue: Florin Malita <fmalita@chromium.org>