History log of /external/skia/gm/perlinnoise.cpp
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
ce6a354e121915c2925e545e7df2929492d69d50 12-Jun-2014 senorblanco <senorblanco@chromium.org> Fix tiled perlin noise.

It turns out that the perlin implementation we inherited from WebKit
does not actually generate tileable noise (see Chromium bug
http://crbug.com/383495).

The main problem is that when generating coordinates for gradient
interpolation, it was attempting to wrap both x and (x + 1)
simultaneously at the tile boundary (that is, either both or neither
are wrapped). This obviously won't work, since along the tile seams,
(x + 1) should be wrapped, but x should not. The same is true in y.

This patch fixes both the CPU and GPU paths, renames some variables to
more closely match the spec, and modifies the perlin noise GM to
actually test tiling. (Note that the clipping the GM was doing was
removed, since it's superfluous: it used to be necessary for image
filters, but isn't anymore, and this isn't an image filter GM anyway.)

R=sugoi@google.com, sugoi
TBR=senorblanco

Author: senorblanco@chromium.org

Review URL: https://codereview.chromium.org/332523006
/external/skia/gm/perlinnoise.cpp
e92c68f7d7398e8a510b7157a38747b23cb883ae 13-May-2014 skia.committer@gmail.com <skia.committer@gmail.com@2bbb7eff-a529-9590-31e7-b0007b416f81> Sanitizing source files in Housekeeper-Nightly

git-svn-id: http://skia.googlecode.com/svn/trunk@14705 2bbb7eff-a529-9590-31e7-b0007b416f81
/external/skia/gm/perlinnoise.cpp
5970f625e96cdc007c563ae72f343ae0d71719a1 12-May-2014 commit-bot@chromium.org <commit-bot@chromium.org@2bbb7eff-a529-9590-31e7-b0007b416f81> re-land hide get/setLocalMatrix

This reverts commit b1d702a43b07934f5b001b1b09db2c57ede909a1.

TBR=scroggo@google.com

Author: reed@google.com

Review URL: https://codereview.chromium.org/279903002

git-svn-id: http://skia.googlecode.com/svn/trunk@14702 2bbb7eff-a529-9590-31e7-b0007b416f81
/external/skia/gm/perlinnoise.cpp
a501a64827ca3d67d45441e42bc377207eb5041b 12-May-2014 reed@google.com <reed@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> add new perlin noise gm to test localmatrix

BUG=skia:

Review URL: https://codereview.chromium.org/283533002

git-svn-id: http://skia.googlecode.com/svn/trunk@14698 2bbb7eff-a529-9590-31e7-b0007b416f81
/external/skia/gm/perlinnoise.cpp
9fbbcca1c958e6df2cff24d3ccdb7ebd89b8486b 01-Apr-2014 commit-bot@chromium.org <commit-bot@chromium.org@2bbb7eff-a529-9590-31e7-b0007b416f81> SkPerlinNoiseShader::CreateTubulenceNoise() is misspelled

Add missing 'r'.

BUG=skia:2329
R=bsalomon@google.com, hcm@google.com, sugoi@chromium.org

Author: siglesias@igalia.com

Review URL: https://codereview.chromium.org/207543008

git-svn-id: http://skia.googlecode.com/svn/trunk@14008 2bbb7eff-a529-9590-31e7-b0007b416f81
/external/skia/gm/perlinnoise.cpp
4b413c8bb123e42ca4b9c7bfa6bc2167283cb84c 25-Nov-2013 commit-bot@chromium.org <commit-bot@chromium.org@2bbb7eff-a529-9590-31e7-b0007b416f81> remove SkFloatToScalar macro

BUG=
R=reed@google.com, djsollen@google.com

Author: caryclark@google.com

Review URL: https://codereview.chromium.org/85463005

git-svn-id: http://skia.googlecode.com/svn/trunk@12385 2bbb7eff-a529-9590-31e7-b0007b416f81
/external/skia/gm/perlinnoise.cpp
c2a0ea6418988d4bcc0719f99b1a110cecd08679 06-Nov-2013 commit-bot@chromium.org <commit-bot@chromium.org@2bbb7eff-a529-9590-31e7-b0007b416f81> Perlin issue fixed

BUG=skia:1799
R=sugoi@chromium.org, sugoi@google.com, senorblanco@chromium.org

Author: bsalomon@google.com

Review URL: https://codereview.chromium.org/59173005

git-svn-id: http://skia.googlecode.com/svn/trunk@12150 2bbb7eff-a529-9590-31e7-b0007b416f81
/external/skia/gm/perlinnoise.cpp
344cf45a40c7de3c4664f8a048d4017af88adfee 17-Jun-2013 commit-bot@chromium.org <commit-bot@chromium.org@2bbb7eff-a529-9590-31e7-b0007b416f81> *** Perlin noise GM needs to be rebaselined ***

Enabling Perlin Noise on Android

I enabled the Perlin Noise shader on Android after doing some minor modifications to the shader, specifically for Android (and #ifdefed for Android, to make sure none of this affects other platforms).

For Tegra devices (Nexus 7, Xoom), a precision issue related to the color values read from textures caused the noise to read the wrong indices and produce bad noise. I fixed this by adding a founding of the values read by simply doing the equivalent of "colorValue = floor(colorValue * 255.0) / 255.0" to make sure we retrieve the colors that were written in the texture originally.

For non-Tegra devices (Nexus 10), dealing with values in the order of 4096.0 was problematic without using the "highp" precision setting. To solve this, a few variables were given the high precision setting.

Since both fixes don't seem to do considerable harm to the platforms that are not being targetted, I left both fixes on all android devices for now.

I also reduced the Perlin noise gm so that it takes less time to test it on the Xoom (Original time was about 20 seconds, this shold take less than 10, hopefully)

BUG=
R=senorblanco@google.com, bsalomon@google.com, sugoi@google.com, senorblanco@chromium.org

Author: sugoi@chromium.org

Review URL: https://chromiumcodereview.appspot.com/16818013

git-svn-id: http://skia.googlecode.com/svn/trunk@9637 2bbb7eff-a529-9590-31e7-b0007b416f81
/external/skia/gm/perlinnoise.cpp
4775cba7b37e24e8480bd2d96e297fd0828fb5c3 17-Apr-2013 sugoi@google.com <sugoi@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> Perlin noise adjustments

1 ) Added GPU simplex noise as a comparison to GPU Perlin noise. It can be enabled simply by using a #define (SK_USE_SIMPLEX_NOISE)
2 ) Enabled GPU Perlin noise tests
3 ) Added a small benchmark for noise
4 ) Disabled GPU Perlin noise on Android based on benchmarks

Review URL: https://codereview.chromium.org/14087002

git-svn-id: http://skia.googlecode.com/svn/trunk@8719 2bbb7eff-a529-9590-31e7-b0007b416f81
/external/skia/gm/perlinnoise.cpp
cff0243b0ff1de25b3d99e2bf15a30c0e0a31261 06-Apr-2013 skia.committer@gmail.com <skia.committer@gmail.com@2bbb7eff-a529-9590-31e7-b0007b416f81> Sanitizing source files in Skia_Periodic_House_Keeping

git-svn-id: http://skia.googlecode.com/svn/trunk@8548 2bbb7eff-a529-9590-31e7-b0007b416f81
/external/skia/gm/perlinnoise.cpp
e3b4c5097a6fd9b6c09d2ffbc3db170a287fdd99 05-Apr-2013 sugoi@google.com <sugoi@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> New SVG turbulence in Skia

This cl contains the code for CPU generation of noise.

TEST:Added 'perlinnoise' gm
Review URL: https://codereview.chromium.org/13094003

git-svn-id: http://skia.googlecode.com/svn/trunk@8541 2bbb7eff-a529-9590-31e7-b0007b416f81
/external/skia/gm/perlinnoise.cpp
8cf10efe759982340acda7c5d2c88fa65005085d 25-Mar-2013 robertphillips@google.com <robertphillips@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> Reverting r8376, r8373 and r8371 due to Android shader compilation failures



git-svn-id: http://skia.googlecode.com/svn/trunk@8378 2bbb7eff-a529-9590-31e7-b0007b416f81
/external/skia/gm/perlinnoise.cpp
33179c817ac0a66999d9e947e18e75044f6b03ff 25-Mar-2013 sugoi@google.com <sugoi@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> Unreviewed build fix

git-svn-id: http://skia.googlecode.com/svn/trunk@8376 2bbb7eff-a529-9590-31e7-b0007b416f81
/external/skia/gm/perlinnoise.cpp
2daa365123528219fae3b63791a8fd3d197a9ce2 25-Mar-2013 sugoi@google.com <sugoi@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> New SVG turbulence in Skia

This cl contains the code for both CPU and GPU generation of noise. Both
codepaths yield equivalent results.

TEST:Added 'perlinnoise' gm
Review URL: https://codereview.chromium.org/13047005

git-svn-id: http://skia.googlecode.com/svn/trunk@8371 2bbb7eff-a529-9590-31e7-b0007b416f81
/external/skia/gm/perlinnoise.cpp
b7636d3fadeceb803de58441bffb0448fba69fda 21-Mar-2013 robertphillips@google.com <robertphillips@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> Reverting 8313 (SVG turbulence) due to Ubuntu failures



git-svn-id: http://skia.googlecode.com/svn/trunk@8316 2bbb7eff-a529-9590-31e7-b0007b416f81
/external/skia/gm/perlinnoise.cpp
3067cc904d22fee756eea6dd8f65c00523026eb1 21-Mar-2013 sugoi@google.com <sugoi@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> New SVG turbulence in Skia

This cl contains the code for both CPU and GPU generation of noise. Both codepaths yield equivalent results.

TEST:Added 'perlinnoise' gm
Review URL: https://codereview.appspot.com/7322060

git-svn-id: http://skia.googlecode.com/svn/trunk@8313 2bbb7eff-a529-9590-31e7-b0007b416f81
/external/skia/gm/perlinnoise.cpp