aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/gpu/effects
Commit message (Collapse)AuthorAge
* Rename GrGLUniformManager to GrGLProgramDataManagerGravatar kkinnunen2014-07-30
| | | | | | | | | | | | | Rename GrGLUniformManager to GrGLProgramDataManager in anticipation that the class would be used to manage shader resources that are not uniforms. This is needed in order to implement NVPR on GLES. R=bsalomon@google.com Author: kkinnunen@nvidia.com Review URL: https://codereview.chromium.org/365853002
* Adding repeat mode to texture domainGravatar joshualitt2014-07-29
| | | | | | | | | BUG=skia: R=bsalomon@chromium.org, senorblanco@chromium.org, bsalomon@google.com, junov@chromium.org Author: joshualitt@chromium.org Review URL: https://codereview.chromium.org/422123003
* Revert of Add effect caching to distance field text. ↵Gravatar bensong2014-07-29
| | | | | | | | | | | | | | | | | | | | | | | (https://codereview.chromium.org/424103002/) Reason for revert: breaking Chrome canary. Original issue's description: > Add effect caching to distance field text. > > This also is a step towards unifying GrDistanceFieldTextureEffect and GrDistanceFieldLCDTextureEffect. > > Committed: https://skia.googlesource.com/skia/+/137bac067306c5446bc4f9797bedc3bbaf302822 R=robertphillips@google.com, jvanverth@google.com TBR=jvanverth@google.com, robertphillips@google.com NOTREECHECKS=true NOTRY=true Author: bensong@google.com Review URL: https://codereview.chromium.org/424173002
* Add effect caching to distance field text.Gravatar jvanverth2014-07-29
| | | | | | | | | | This also is a step towards unifying GrDistanceFieldTextureEffect and GrDistanceFieldLCDTextureEffect. R=robertphillips@google.com Author: jvanverth@google.com Review URL: https://codereview.chromium.org/424103002
* Initial change to move 2D kernel to its own file.Gravatar joshualitt2014-07-22
| | | | | | | | | BUG=skia: R=bsalomon@chromium.org, senorblanco@chromium.org, bsalomon@google.com Author: joshualitt@chromium.org Review URL: https://codereview.chromium.org/379253003
* Allow GrGLEffects to produce variable length keys.Gravatar bsalomon2014-07-21
| | | | | | | | R=robertphillips@google.com, jvanverth@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/385713005
* Replace GrTHash with SkTDynamicHashGravatar robertphillips2014-07-20
| | | | | | | | | | | | | Mike: SkTDynamicHash changes Brian: Ganesh changes This removes three instances of GrTHash leaving the ones in GrTextStrike.h R=mtklein@google.com, bsalomon@google.com Author: robertphillips@google.com Review URL: https://codereview.chromium.org/402693003
* This moves us towards variable length effect keys. The overall program key ↵Gravatar bsalomon2014-07-11
| | | | | | | | | | now allows for it. After the header it stores an array of offsets to effect keys. This allows us to grab the effect keys to pass to effects when they generate code. It also ensures that we can't get a collision by sets of keys that are different lengths but are the same when appended together. R=robertphillips@google.com, jvanverth@google.com, egdaniel@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/356513003
* Revert of Make GrGLConfigConversionEffect work for Imagination and some ↵Gravatar bsalomon2014-07-09
| | | | | | | | | | | | | | | | | | | | | | | | | other GPUs. (https://codereview.chromium.org/277323002/) Reason for revert: Need to only use the highp variations on GLES contexts not GL contexts. http://108.170.220.120:10117/builders/Test-Mac10.6-MacMini4.1-GeForce320M-x86_64-Release/builds/3398/steps/RunTests/logs/stdio Original issue's description: > Make GrGLConfigConversionEffect work for Imagination and some other GPUs. > > BUG=372341 > > Committed: https://skia.googlesource.com/skia/+/93cf46f7d687128d2ad05762bd65fea6c4539553 R=tomhudson@chromium.org, changjun.yang@intel.com, rmistry@google.com, jcgregorio@google.com NOTREECHECKS=true NOTRY=true BUG=372341 Author: bsalomon@google.com Review URL: https://codereview.chromium.org/377263003
* Make GrGLConfigConversionEffect work for Imagination and some other GPUs.Gravatar changjun.yang2014-07-09
| | | | | | | | | BUG=372341 R=tomhudson@chromium.org, bsalomon@google.com Author: changjun.yang@intel.com Review URL: https://codereview.chromium.org/277323002
* Goodbye GrEffectRef.Gravatar bsalomon2014-07-08
| | | | | | | | | | Also, reworked some var names and comments around SkShader::asNewEffect. R=robertphillips@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/374923002
* Remove GrEffect::CreateEffectRef and GrEffect::AutoEffectRef.Gravatar bsalomon2014-07-08
| | | | | | | | R=robertphillips@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/371103003
* Make GrDrawState and GrPaint take GrEffect* instead of GrEffectRef*.Gravatar bsalomon2014-07-08
| | | | | | | | | | | | | | Make Sk-effect virtuals produce GrEffect* rather than GrEffectRef* Make GrEffectRef a typedef for GrEffect. Committed: https://skia.googlesource.com/skia/+/2011fe9cdfa63b83489a146cea6a724cede352c8 R=robertphillips@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/377503004
* Revert of Make GrDrawState and GrPaint take GrEffect* instead of ↵Gravatar reed2014-07-07
| | | | | | | | | | | | | | | | | | | | | | | | | GrEffectRef*. (https://codereview.chromium.org/377503004/) Reason for revert: broke linux builders Original issue's description: > Make GrDrawState and GrPaint take GrEffect* instead of GrEffectRef*. > > Make Sk-effect virtuals produce GrEffect* rather than GrEffectRef* > > Make GrEffectRef a typedef for GrEffect. > > Committed: https://skia.googlesource.com/skia/+/2011fe9cdfa63b83489a146cea6a724cede352c8 R=robertphillips@google.com, bsalomon@google.com TBR=bsalomon@google.com, robertphillips@google.com NOTREECHECKS=true NOTRY=true Author: reed@google.com Review URL: https://codereview.chromium.org/372053003
* Make GrDrawState and GrPaint take GrEffect* instead of GrEffectRef*.Gravatar bsalomon2014-07-07
| | | | | | | | | | | | Make Sk-effect virtuals produce GrEffect* rather than GrEffectRef* Make GrEffectRef a typedef for GrEffect. R=robertphillips@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/377503004
* YUV to RGB converterGravatar sugoi2014-07-07
| | | | | | | | | | | | | This is a first piece of the GPU YUV decoder, which is the actual effect that performs the conversion. For now, it simply applies the conversion matrix, since it is all I need. I may add modes if different matrices need to be applied or if I add color profile support here. I'll try to keep these cls short and easy to review, but there should be a few of them coming once this one is in. BUG=skia: R=senorblanco@chromium.org, senorblanco@google.com, reed@google.com, bsalomon@google.com Author: sugoi@chromium.org Review URL: https://codereview.chromium.org/378503006
* Remove use of GrEffectRef from draw state and below.Gravatar bsalomon2014-07-07
| | | | | | | | R=robertphillips@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/372773002
* Fix int to float bug in shader on gpu Dotted Line clGravatar egdaniel2014-07-02
| | | | | | | | | | | | NOTRY=True NOTREECHECKS=True R=bsalomon@google.com TBR=bsalomon@google.com BUG=skia: Author: egdaniel@google.com Review URL: https://codereview.chromium.org/361253002
* Add the ability for gpu to render dotted lines (dashed line, 0 on interval, ↵Gravatar egdaniel2014-07-02
| | | | | | | | | | | round caps) BUG=skia: R=bsalomon@google.com Author: egdaniel@google.com Review URL: https://codereview.chromium.org/345113003
* Make GrGLShaderBuilder::fragmentPosition() return a vec4, with 1.0 as the zw ↵Gravatar bsalomon2014-06-24
| | | | | | | | | | | | | | components when in the y-flip case. This works around an Adreno driver bug. Revert "Stop referencing gl_FragCoord z and w components." This reverts commit 160a52ba217012ed73c240f6d67b3bbf2b4879d6. R=jvanverth@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/354663002
* Stop referencing gl_FragCoord z and w components.Gravatar bsalomon2014-06-20
| | | | | | | | | | This fixes an Adreno driver bug where GL programs fail to link if the FS refers to these components of gl_FragCoord. R=jvanverth@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/345083002
* Fix shader codeGravatar krajcevski2014-06-20
| | | | | | | | | | R=bsalomon@google.com, reed@google.com NOTREECHECKS=true NOTRYS=true Author: krajcevski@google.com Review URL: https://codereview.chromium.org/347563006
* Simple GPU based dithering:Gravatar krajcevski2014-06-19
| | | | | | | | | | | | | | | If dithering is turned on, apply an effect that filters the pixel through the following pipeline: for each channel c: 1. Compute quantized colors [low, high] that c is between 2. Pick high by flipping a coin weighted by (c - low) R=bsalomon@google.com, egdaniel@google.com, robertphillips@google.com Author: krajcevski@google.com Review URL: https://codereview.chromium.org/321253002
* Use vertex attributes for dash effect in gpuGravatar egdaniel2014-06-12
| | | | | | | | | | | | | This will allow us to batch dashed lines together when drawing. Also, this removes the need for a coord transform matrix in the shader, thus we save the cost of uploading a new matrix uniform everytime we do a simple transform to the dashed line we are drawing. BUG=skia: R=bsalomon@google.com Author: egdaniel@google.com Review URL: https://codereview.chromium.org/326103002
* Gamma correction for distance field text.Gravatar jvanverth2014-06-10
| | | | | | | | | | | | | | Handles both non-LCD and LCD text. Uses a texture to look up the gamma correction values for a given text color or luminance. BUG=skia: Committed: https://skia.googlesource.com/skia/+/4d517fdbb145cb95e5e935470df331e1b6667cfc R=reed@google.com, bungeman@google.com, robertphillips@google.com, bsalomon@google.com Author: jvanverth@google.com Review URL: https://codereview.chromium.org/258883002
* Revert of Gamma correction for distance field text. ↵Gravatar scroggo2014-06-09
| | | | | | | | | | | | | | | | | | | | | | | | (https://codereview.chromium.org/258883002/) Reason for revert: Memory leaks. I suspect this is due to the lack of destructors in SkAutoGlyphCache Original issue's description: > Gamma correction for distance field text. > > Handles both non-LCD and LCD text. Uses a texture to look up the gamma correction values for a given text color or luminance. > > BUG=skia: > > Committed: https://skia.googlesource.com/skia/+/4d517fdbb145cb95e5e935470df331e1b6667cfc NOTRY=true NOTREECHECKS=true R=reed@google.com, bungeman@google.com, robertphillips@google.com, bsalomon@google.com, jvanverth@google.com, mtklein@google.com Author: scroggo@google.com Review URL: https://codereview.chromium.org/323513005
* Gamma correction for distance field text.Gravatar jvanverth2014-06-09
| | | | | | | | | | | Handles both non-LCD and LCD text. Uses a texture to look up the gamma correction values for a given text color or luminance. BUG=skia: R=reed@google.com, bungeman@google.com, robertphillips@google.com, bsalomon@google.com Author: jvanverth@google.com Review URL: https://codereview.chromium.org/258883002
* Centralize decision about whether to do bicubic filtering, and fallbacks to ↵Gravatar commit-bot@chromium.org2014-05-20
| | | | | | | | | | | | mip, bilerp, or nearest R=robertphillips@google.com, humper@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/282293004 git-svn-id: http://skia.googlecode.com/svn/trunk@14809 2bbb7eff-a529-9590-31e7-b0007b416f81
* Sanitizing source files in Housekeeper-NightlyGravatar skia.committer@gmail.com2014-05-20
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@14793 2bbb7eff-a529-9590-31e7-b0007b416f81
* Pass in GrContext instead of SkGpuDevice for dashing and Sk2GrPaint conversionGravatar commit-bot@chromium.org2014-05-19
| | | | | | | | | | | BUG=skia: R=bsalomon@google.com Author: egdaniel@google.com Review URL: https://codereview.chromium.org/292773002 git-svn-id: http://skia.googlecode.com/svn/trunk@14790 2bbb7eff-a529-9590-31e7-b0007b416f81
* Fix build error for windows for Dashing CLGravatar commit-bot@chromium.org2014-05-19
| | | | | | | | | | | | | | NOTREECHECKS=True NOTRY=True R=bsalomon@google.com TBR=bsalomon@google.com BUG=skia: Author: egdaniel@google.com Review URL: https://codereview.chromium.org/291803004 git-svn-id: http://skia.googlecode.com/svn/trunk@14776 2bbb7eff-a529-9590-31e7-b0007b416f81
* Add Dashing gpu effect for simple dashed linesGravatar commit-bot@chromium.org2014-05-19
| | | | | | | | | | | BUG=skia: R=bsalomon@google.com Author: egdaniel@google.com Review URL: https://codereview.chromium.org/274673004 git-svn-id: http://skia.googlecode.com/svn/trunk@14775 2bbb7eff-a529-9590-31e7-b0007b416f81
* Convert GrCrash->SkFAIL GrDebugCrash->SkDEBUGFAILGravatar commit-bot@chromium.org2014-04-30
| | | | | | | | | | R=robertphillips@google.com, reed@google.com, mtklein@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/257393004 git-svn-id: http://skia.googlecode.com/svn/trunk@14460 2bbb7eff-a529-9590-31e7-b0007b416f81
* stop using deprecated bitmap::config for gpuGravatar commit-bot@chromium.org2014-04-23
| | | | | | | | | | | BUG=skia: R=bsalomon@google.com Author: reed@google.com Review URL: https://codereview.chromium.org/248473006 git-svn-id: http://skia.googlecode.com/svn/trunk@14330 2bbb7eff-a529-9590-31e7-b0007b416f81
* Sanitizing source files in Housekeeper-NightlyGravatar skia.committer@gmail.com2014-04-15
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@14196 2bbb7eff-a529-9590-31e7-b0007b416f81
* Move distance field generation to the glyph cache.Gravatar commit-bot@chromium.org2014-04-14
| | | | | | | | | | | | | | Distance fields are currently created in GrTextStrike, which is the wrong place. This moves that to the glyph cache where it belongs. As part of my testing, I found that when we fall back to paths in the GrDistanceFieldTextContext it was not scaling them properly, so that's fixed in here too. R=robertphillips@google.com, reed@google.com Author: jvanverth@google.com Review URL: https://codereview.chromium.org/227593010 git-svn-id: http://skia.googlecode.com/svn/trunk@14193 2bbb7eff-a529-9590-31e7-b0007b416f81
* Implement drawDRRect for GPUGravatar commit-bot@chromium.org2014-04-09
| | | | | | | | | | | BUG=skia:2259 R=jvanverth@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/220233011 git-svn-id: http://skia.googlecode.com/svn/trunk@14118 2bbb7eff-a529-9590-31e7-b0007b416f81
* Do div-by-zero check for all gpus in ellipse/rr effects.Gravatar commit-bot@chromium.org2014-04-09
| | | | | | | | | | R=jvanverth@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/231093002 git-svn-id: http://skia.googlecode.com/svn/trunk@14110 2bbb7eff-a529-9590-31e7-b0007b416f81
* SkNonCopyable should be used with private inheritance.Gravatar commit-bot@chromium.org2014-04-07
| | | | | | | | | | | | | | | This is mostly s/public SkNoncopyable/SkNoncopyable/g. Two classes (SkDrawLooper::Context and SkPicture::OperationList) don't actually work with SkNoncopyable because they introduce a virtual destructor. I added SkNoncopyableVirtual to make them work as intended. Sort of questionable whether they really need to be noncopyable in the first place, but I guess it doesn't hurt to keep the behavior the same. BUG=skia: R=reed@google.com, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/226183018 git-svn-id: http://skia.googlecode.com/svn/trunk@14081 2bbb7eff-a529-9590-31e7-b0007b416f81
* Add LCD support for distance field text.Gravatar commit-bot@chromium.org2014-04-03
| | | | | | | | | | | | | LCD support is handled by shifting the uv coordinate by 1/3 of a pixel (transformed by the inverse CTM) to the left and right of the original texture coordinate, and using left, center, and right lookups to set the RGB values. This supports both RGB and BGR subpixel order. BUG=skia:2173 R=robertphillips@google.com, egdaniel@google.com, bungeman@google.com Author: jvanverth@google.com Review URL: https://codereview.chromium.org/219243012 git-svn-id: http://skia.googlecode.com/svn/trunk@14049 2bbb7eff-a529-9590-31e7-b0007b416f81
* Add effect for ellipse clipping.Gravatar commit-bot@chromium.org2014-04-02
| | | | | | | | | | | BUG=skia:2181 R=jvanverth@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/218583013 git-svn-id: http://skia.googlecode.com/svn/trunk@14024 2bbb7eff-a529-9590-31e7-b0007b416f81
* Sanitizing source files in Housekeeper-NightlyGravatar skia.committer@gmail.com2014-03-29
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@13989 2bbb7eff-a529-9590-31e7-b0007b416f81
* SK_SUPPORT_LEGACY_GRTYPES to hide duplicate types from SkTypes.hGravatar commit-bot@chromium.org2014-03-28
| | | | | | | | | | | BUG=skia: R=bsalomon@google.com Author: reed@google.com Review URL: https://codereview.chromium.org/216503004 git-svn-id: http://skia.googlecode.com/svn/trunk@13982 2bbb7eff-a529-9590-31e7-b0007b416f81
* Add clip effect for circlesGravatar commit-bot@chromium.org2014-03-28
| | | | | | | | | | | BUG=skia:2181 R=jvanverth@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/214153002 git-svn-id: http://skia.googlecode.com/svn/trunk@13974 2bbb7eff-a529-9590-31e7-b0007b416f81
* Distance field fixes for AndroidGravatar commit-bot@chromium.org2014-03-26
| | | | | | | | | | | | | | | | | | | | - Expand glyph size by 2 on each side to compensate for bilerp lookup - Correct for Adreno tendency to drop entire tile if any pixel has divide-by-0 - Fix blurriness on Adreno by using uv coords to compute gradient instead of st coords - Add faster version for uniform scale BUG=skia:2173 Committed: http://code.google.com/p/skia/source/detail?r=13955 R=bsalomon@google.com Author: jvanverth@google.com Review URL: https://codereview.chromium.org/205343008 git-svn-id: http://skia.googlecode.com/svn/trunk@13958 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert of Distance field fixes for Android ↵Gravatar commit-bot@chromium.org2014-03-26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (https://codereview.chromium.org/205343008/) Reason for revert: compile error at line 110 in GrDistanceFieldTextureEffect.cpp Original issue's description: > Distance field fixes for Android > - Expand glyph size by 2 on each side to compensate for bilerp lookup > - Correct for Adreno tendency to drop entire tile if any pixel has divide-by-0 > - Fix blurriness on Adreno by using uv coords to compute gradient instead > of st coords > - Add faster version for uniform scale > > BUG=skia:2173 > > Committed: http://code.google.com/p/skia/source/detail?r=13955 R=bsalomon@google.com TBR=bsalomon@google.com NOTREECHECKS=true NOTRY=true BUG=skia:2173 Author: jvanverth@google.com Review URL: https://codereview.chromium.org/212953008 git-svn-id: http://skia.googlecode.com/svn/trunk@13956 2bbb7eff-a529-9590-31e7-b0007b416f81
* Distance field fixes for AndroidGravatar commit-bot@chromium.org2014-03-26
| | | | | | | | | | | | | | | | | - Expand glyph size by 2 on each side to compensate for bilerp lookup - Correct for Adreno tendency to drop entire tile if any pixel has divide-by-0 - Fix blurriness on Adreno by using uv coords to compute gradient instead of st coords - Add faster version for uniform scale BUG=skia:2173 R=bsalomon@google.com Author: jvanverth@google.com Review URL: https://codereview.chromium.org/205343008 git-svn-id: http://skia.googlecode.com/svn/trunk@13955 2bbb7eff-a529-9590-31e7-b0007b416f81
* Add GM that tests GrTextureDomain and fix bug where kDecal_Mode gets ↵Gravatar commit-bot@chromium.org2014-03-25
| | | | | | | | | | | | incorrectly ignored. R=robertphillips@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/208313017 git-svn-id: http://skia.googlecode.com/svn/trunk@13933 2bbb7eff-a529-9590-31e7-b0007b416f81
* Sanitizing source files in Housekeeper-NightlyGravatar skia.committer@gmail.com2014-03-25
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@13928 2bbb7eff-a529-9590-31e7-b0007b416f81
* When clipping treat rrect corners where either the x or y radius is < 0.5 as ↵Gravatar commit-bot@chromium.org2014-03-24
| | | | | | | | | | | | | square. BUG=skia:2181 R=robertphillips@google.com, jvanverth@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/200723011 git-svn-id: http://skia.googlecode.com/svn/trunk@13918 2bbb7eff-a529-9590-31e7-b0007b416f81