diff options
author | Android (Google) Code Review <android-gerrit@google.com> | 2009-11-13 10:46:12 -0800 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2009-11-13 10:46:12 -0800 |
commit | 7a8980b45d74af83443e7b3b6387476abe6eb14a (patch) | |
tree | 17f9951440bb32f18b0fc948b06fb34daef97523 /res | |
parent | 9ea1a0ea7b3b75db3e6294ff26b68ecb2cfde5ab (diff) | |
parent | 97e65a2a35c1fa6dddece5d5fef51ec5c06435f5 (diff) | |
download | android_packages_wallpapers_MagicSmoke-7a8980b45d74af83443e7b3b6387476abe6eb14a.tar.gz android_packages_wallpapers_MagicSmoke-7a8980b45d74af83443e7b3b6387476abe6eb14a.tar.bz2 android_packages_wallpapers_MagicSmoke-7a8980b45d74af83443e7b3b6387476abe6eb14a.zip |
Merge change I97e65a2a into eclair
* changes:
Make sure texture coordinates and angles don't get too big, since eventually we'll hit some limit in the driver and things start to look weird.
Diffstat (limited to 'res')
-rw-r--r-- | res/raw/clouds.rs | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/res/raw/clouds.rs b/res/raw/clouds.rs index a468cfb..2d867e9 100644 --- a/res/raw/clouds.rs +++ b/res/raw/clouds.rs @@ -94,6 +94,12 @@ void drawClouds(float* ident) { xshift[4] += 0.00127f; } + // Make sure the texture coordinates don't continuously increase + for(i = 0; i < 5; i++) { + while (xshift[i] >= 1.f) { + xshift[i] -= 1.f; + } + } if (State->mRotate != 0) { rotation[0] += 0.10; rotation[1] += 0.102f; @@ -101,6 +107,13 @@ void drawClouds(float* ident) { rotation[3] += 0.114f; rotation[4] += 0.123f; } + + // Make sure the rotation angles don't continuously increase + for(i = 0; i < 5; i++) { + while (rotation[i] >= 360.f) { + rotation[i] -= 360.f; + } + } } int premul(int rgb, int a) { |