Project

General

Profile

« Previous | Next » 

Revision 9ff0c8c3

Added by Leszek Koltunski over 7 years ago

Fix 4D and 5D noise, make noise N dimensional.

View differences:

src/main/java/org/distorted/examples/starwars/StarWarsRenderer.java
165 165
    Static3D center = new Static3D(0,0,0);
166 166
    Static3D axis   = new Static3D(0,0,1);
167 167

  
168
    Static1D alphaNoise = new Static1D(0.4f);
169

  
168 170
    for(int i=0; i<NUM_STARS; i++)
169 171
      {
170 172
      randomX = mRnd.nextInt(w);
......
180 182
      mStars[i].rotate( new Static1D(randomA), axis, center );
181 183
      
182 184
      Dynamic1D di = new Dynamic1D(randomTime,0.0f);
183
      di.setNoise(0.5f);
185
      di.setNoise(alphaNoise);
184 186
      di.add(new Static1D(randomAlpha1));
185 187
      di.add(new Static1D(randomAlpha2));
186 188
      

Also available in: Unified diff