@@ -2182,7 +2182,7 @@ static const char _data_FX_MODE_BPM[] PROGMEM = "Bpm@!;!;!;;sx=64";
2182
2182
uint16_t mode_fillnoise8 () {
2183
2183
if (SEGENV.call == 0 ) SEGENV.step = hw_random ();
2184
2184
for (unsigned i = 0 ; i < SEGLEN; i++) {
2185
- unsigned index = inoise8 (i * SEGLEN, SEGENV.step + i * SEGLEN);
2185
+ unsigned index = perlin8 (i * SEGLEN, SEGENV.step + i * SEGLEN);
2186
2186
SEGMENT.setPixelColor (i, SEGMENT.color_from_palette (index, false , PALETTE_SOLID_WRAP, 0 ));
2187
2187
}
2188
2188
SEGENV.step += beatsin8_t (SEGMENT.speed , 1 , 6 ); // 10,1,4
@@ -2202,7 +2202,7 @@ uint16_t mode_noise16_1() {
2202
2202
unsigned real_x = (i + shift_x) * scale; // the x position of the noise field swings @ 17 bpm
2203
2203
unsigned real_y = (i + shift_y) * scale; // the y position becomes slowly incremented
2204
2204
uint32_t real_z = SEGENV.step ; // the z position becomes quickly incremented
2205
- unsigned noise = inoise16 (real_x, real_y, real_z) >> 8 ; // get the noise data and scale it down
2205
+ unsigned noise = perlin16 (real_x, real_y, real_z) >> 8 ; // get the noise data and scale it down
2206
2206
unsigned index = sin8_t (noise * 3 ); // map LED color based on noise data
2207
2207
2208
2208
SEGMENT.setPixelColor (i, SEGMENT.color_from_palette (index, false , PALETTE_SOLID_WRAP, 0 ));
@@ -2220,7 +2220,7 @@ uint16_t mode_noise16_2() {
2220
2220
for (unsigned i = 0 ; i < SEGLEN; i++) {
2221
2221
unsigned shift_x = SEGENV.step >> 6 ; // x as a function of time
2222
2222
uint32_t real_x = (i + shift_x) * scale; // calculate the coordinates within the noise field
2223
- unsigned noise = inoise16 (real_x, 0 , 4223 ) >> 8 ; // get the noise data and scale it down
2223
+ unsigned noise = perlin16 (real_x, 0 , 4223 ) >> 8 ; // get the noise data and scale it down
2224
2224
unsigned index = sin8_t (noise * 3 ); // map led color based on noise data
2225
2225
2226
2226
SEGMENT.setPixelColor (i, SEGMENT.color_from_palette (index, false , PALETTE_SOLID_WRAP, 0 , noise));
@@ -2241,7 +2241,7 @@ uint16_t mode_noise16_3() {
2241
2241
uint32_t real_x = (i + shift_x) * scale; // calculate the coordinates within the noise field
2242
2242
uint32_t real_y = (i + shift_y) * scale; // based on the precalculated positions
2243
2243
uint32_t real_z = SEGENV.step *8 ;
2244
- unsigned noise = inoise16 (real_x, real_y, real_z) >> 8 ; // get the noise data and scale it down
2244
+ unsigned noise = perlin16 (real_x, real_y, real_z) >> 8 ; // get the noise data and scale it down
2245
2245
unsigned index = sin8_t (noise * 3 ); // map led color based on noise data
2246
2246
2247
2247
SEGMENT.setPixelColor (i, SEGMENT.color_from_palette (index, false , PALETTE_SOLID_WRAP, 0 , noise));
@@ -2256,7 +2256,7 @@ static const char _data_FX_MODE_NOISE16_3[] PROGMEM = "Noise 3@!;!;!;;pal=35";
2256
2256
uint16_t mode_noise16_4 () {
2257
2257
uint32_t stp = (strip.now * SEGMENT.speed ) >> 7 ;
2258
2258
for (unsigned i = 0 ; i < SEGLEN; i++) {
2259
- int index = inoise16 (uint32_t (i) << 12 , stp);
2259
+ int index = perlin16 (uint32_t (i) << 12 , stp);
2260
2260
SEGMENT.setPixelColor (i, SEGMENT.color_from_palette (index, false , PALETTE_SOLID_WRAP, 0 ));
2261
2261
}
2262
2262
return FRAMETIME;
@@ -4118,7 +4118,7 @@ static uint16_t phased_base(uint8_t moder) { // We're making si
4118
4118
*phase += SEGMENT.speed /32.0 ; // You can change the speed of the wave. AKA SPEED (was .4)
4119
4119
4120
4120
for (unsigned i = 0 ; i < SEGLEN; i++) {
4121
- if (moder == 1 ) modVal = (inoise8 (i*10 + i*10 ) /16 ); // Let's randomize our mod length with some Perlin noise.
4121
+ if (moder == 1 ) modVal = (perlin8 (i*10 + i*10 ) /16 ); // Let's randomize our mod length with some Perlin noise.
4122
4122
unsigned val = (i+1 ) * allfreq; // This sets the frequency of the waves. The +1 makes sure that led 0 is used.
4123
4123
if (modVal == 0 ) modVal = 1 ;
4124
4124
val += *phase * (i % modVal +1 ) /2 ; // This sets the varying phase change of the waves. By Andrew Tuline.
@@ -4187,7 +4187,7 @@ uint16_t mode_noisepal(void) { // Slow noise
4187
4187
if (SEGMENT.palette > 0 ) palettes[0 ] = SEGPALETTE;
4188
4188
4189
4189
for (unsigned i = 0 ; i < SEGLEN; i++) {
4190
- unsigned index = inoise8 (i*scale, SEGENV.aux0 +i*scale); // Get a value from the noise function. I'm using both x and y axis.
4190
+ unsigned index = perlin8 (i*scale, SEGENV.aux0 +i*scale); // Get a value from the noise function. I'm using both x and y axis.
4191
4191
SEGMENT.setPixelColor (i, ColorFromPalette (palettes[0 ], index, 255 , LINEARBLEND)); // Use my own palette.
4192
4192
}
4193
4193
@@ -4798,7 +4798,7 @@ uint16_t mode_perlinmove(void) {
4798
4798
if (SEGLEN <= 1 ) return mode_static ();
4799
4799
SEGMENT.fade_out (255 -SEGMENT.custom1 );
4800
4800
for (int i = 0 ; i < SEGMENT.intensity /16 + 1 ; i++) {
4801
- unsigned locn = inoise16 (strip.now *128 /(260 -SEGMENT.speed )+i*15000 , strip.now *128 /(260 -SEGMENT.speed )); // Get a new pixel location from moving noise.
4801
+ unsigned locn = perlin16 (strip.now *128 /(260 -SEGMENT.speed )+i*15000 , strip.now *128 /(260 -SEGMENT.speed )); // Get a new pixel location from moving noise.
4802
4802
unsigned pixloc = map (locn, 50 *256 , 192 *256 , 0 , SEGLEN-1 ); // Map that to the length of the strand, and ensure we don't go over.
4803
4803
SEGMENT.setPixelColor (pixloc, SEGMENT.color_from_palette (pixloc%255 , false , PALETTE_SOLID_WRAP, 0 ));
4804
4804
}
@@ -5056,7 +5056,7 @@ uint16_t mode_2Dfirenoise(void) { // firenoise2d. By Andrew Tuline
5056
5056
CRGBPalette16 pal = SEGMENT.check1 ? SEGPALETTE : SEGMENT.loadPalette (pal, 35 );
5057
5057
for (int j=0 ; j < cols; j++) {
5058
5058
for (int i=0 ; i < rows; i++) {
5059
- indexx = inoise8 (j*yscale*rows/255 , i*xscale+strip.now /4 ); // We're moving along our Perlin map.
5059
+ indexx = perlin8 (j*yscale*rows/255 , i*xscale+strip.now /4 ); // We're moving along our Perlin map.
5060
5060
SEGMENT.setPixelColorXY (j, i, ColorFromPalette (pal, min (i*indexx/11 , 225U ), i*255 /rows, LINEARBLEND)); // With that value, look up the 8 bit colour palette value and assign it to the current LED.
5061
5061
} // for i
5062
5062
} // for j
@@ -5449,11 +5449,11 @@ uint16_t mode_2Dmetaballs(void) { // Metaballs by Stefan Petrick. Cannot have
5449
5449
float speed = 0 .25f * (1 +(SEGMENT.speed >>6 ));
5450
5450
5451
5451
// get some 2 random moving points
5452
- int x2 = map (inoise8 (strip.now * speed, 25355 , 685 ), 0 , 255 , 0 , cols-1 );
5453
- int y2 = map (inoise8 (strip.now * speed, 355 , 11685 ), 0 , 255 , 0 , rows-1 );
5452
+ int x2 = map (perlin8 (strip.now * speed, 25355 , 685 ), 0 , 255 , 0 , cols-1 );
5453
+ int y2 = map (perlin8 (strip.now * speed, 355 , 11685 ), 0 , 255 , 0 , rows-1 );
5454
5454
5455
- int x3 = map (inoise8 (strip.now * speed, 55355 , 6685 ), 0 , 255 , 0 , cols-1 );
5456
- int y3 = map (inoise8 (strip.now * speed, 25355 , 22685 ), 0 , 255 , 0 , rows-1 );
5455
+ int x3 = map (perlin8 (strip.now * speed, 55355 , 6685 ), 0 , 255 , 0 , cols-1 );
5456
+ int y3 = map (perlin8 (strip.now * speed, 25355 , 22685 ), 0 , 255 , 0 , rows-1 );
5457
5457
5458
5458
// and one Lissajou function
5459
5459
int x1 = beatsin8_t (23 * speed, 0 , cols-1 );
@@ -5509,7 +5509,7 @@ uint16_t mode_2Dnoise(void) { // By Andrew Tuline
5509
5509
5510
5510
for (int y = 0 ; y < rows; y++) {
5511
5511
for (int x = 0 ; x < cols; x++) {
5512
- uint8_t pixelHue8 = inoise8 (x * scale, y * scale, strip.now / (16 - SEGMENT.speed /16 ));
5512
+ uint8_t pixelHue8 = perlin8 (x * scale, y * scale, strip.now / (16 - SEGMENT.speed /16 ));
5513
5513
SEGMENT.setPixelColorXY (x, y, ColorFromPalette (SEGPALETTE, pixelHue8));
5514
5514
}
5515
5515
}
@@ -5531,10 +5531,10 @@ uint16_t mode_2DPlasmaball(void) { // By: Stepko https://edito
5531
5531
SEGMENT.fadeToBlackBy (SEGMENT.custom1 >>2 );
5532
5532
uint_fast32_t t = (strip.now * 8 ) / (256 - SEGMENT.speed ); // optimized to avoid float
5533
5533
for (int i = 0 ; i < cols; i++) {
5534
- unsigned thisVal = inoise8 (i * 30 , t, t);
5534
+ unsigned thisVal = perlin8 (i * 30 , t, t);
5535
5535
unsigned thisMax = map (thisVal, 0 , 255 , 0 , cols-1 );
5536
5536
for (int j = 0 ; j < rows; j++) {
5537
- unsigned thisVal_ = inoise8 (t, j * 30 , t);
5537
+ unsigned thisVal_ = perlin8 (t, j * 30 , t);
5538
5538
unsigned thisMax_ = map (thisVal_, 0 , 255 , 0 , rows-1 );
5539
5539
int x = (i + thisMax_ - cols / 2 );
5540
5540
int y = (j + thisMax - cols / 2 );
@@ -5579,7 +5579,7 @@ uint16_t mode_2DPolarLights(void) { // By: Kostyantyn Matviyevskyy https
5579
5579
for (int x = 0 ; x < cols; x++) {
5580
5580
for (int y = 0 ; y < rows; y++) {
5581
5581
SEGENV.step ++;
5582
- uint8_t palindex = qsub8 (inoise8 ((SEGENV.step %2 ) + x * _scale, y * 16 + SEGENV.step % 16 , SEGENV.step / _speed), fabsf ((float )rows / 2 .0f - (float )y) * adjustHeight);
5582
+ uint8_t palindex = qsub8 (perlin8 ((SEGENV.step %2 ) + x * _scale, y * 16 + SEGENV.step % 16 , SEGENV.step / _speed), fabsf ((float )rows / 2 .0f - (float )y) * adjustHeight);
5583
5583
uint8_t palbrightness = palindex;
5584
5584
if (SEGMENT.check1 ) palindex = 255 - palindex; // flip palette
5585
5585
SEGMENT.setPixelColorXY (x, y, SEGMENT.color_from_palette (palindex, false , false , 255 , palbrightness));
@@ -5696,7 +5696,8 @@ uint16_t mode_2DSunradiation(void) { // By: ldirko https://edi
5696
5696
uint8_t someVal = SEGMENT.speed /4 ; // Was 25.
5697
5697
for (int j = 0 ; j < (rows + 2 ); j++) {
5698
5698
for (int i = 0 ; i < (cols + 2 ); i++) {
5699
- byte col = (inoise8_raw (i * someVal, j * someVal, t)) / 2 ;
5699
+ // byte col = (inoise8_raw(i * someVal, j * someVal, t)) / 2;
5700
+ byte col = ((int16_t )perlin8 (i * someVal, j * someVal, t) - 0x7F ) / 3 ;
5700
5701
bump[index++] = col;
5701
5702
}
5702
5703
}
@@ -6394,10 +6395,10 @@ uint16_t mode_2DWaverly(void) {
6394
6395
6395
6396
long t = strip.now / 2 ;
6396
6397
for (int i = 0 ; i < cols; i++) {
6397
- unsigned thisVal = (1 + SEGMENT.intensity /64 ) * inoise8 (i * 45 , t , t)/2 ;
6398
+ unsigned thisVal = (1 + SEGMENT.intensity /64 ) * perlin8 (i * 45 , t , t)/2 ;
6398
6399
// use audio if available
6399
6400
if (um_data) {
6400
- thisVal /= 32 ; // reduce intensity of inoise8 ()
6401
+ thisVal /= 32 ; // reduce intensity of perlin8 ()
6401
6402
thisVal *= volumeSmth;
6402
6403
}
6403
6404
int thisMax = map (thisVal, 0 , 512 , 0 , rows);
@@ -6476,7 +6477,7 @@ uint16_t mode_gravcenter_base(unsigned mode) {
6476
6477
}
6477
6478
else if (mode == 2 ) { // Gravimeter
6478
6479
for (int i=0 ; i<tempsamp; i++) {
6479
- uint8_t index = inoise8 (i*segmentSampleAvg+strip.now , 5000 +i*segmentSampleAvg);
6480
+ uint8_t index = perlin8 (i*segmentSampleAvg+strip.now , 5000 +i*segmentSampleAvg);
6480
6481
SEGMENT.setPixelColor (i, color_blend (SEGCOLOR (1 ), SEGMENT.color_from_palette (index, false , PALETTE_SOLID_WRAP, 0 ), uint8_t (segmentSampleAvg*8 )));
6481
6482
}
6482
6483
if (gravcen->topLED > 0 ) {
@@ -6498,7 +6499,7 @@ uint16_t mode_gravcenter_base(unsigned mode) {
6498
6499
}
6499
6500
else { // Gravcenter
6500
6501
for (int i=0 ; i<tempsamp; i++) {
6501
- uint8_t index = inoise8 (i*segmentSampleAvg+strip.now , 5000 +i*segmentSampleAvg);
6502
+ uint8_t index = perlin8 (i*segmentSampleAvg+strip.now , 5000 +i*segmentSampleAvg);
6502
6503
SEGMENT.setPixelColor (i+SEGLEN/2 , color_blend (SEGCOLOR (1 ), SEGMENT.color_from_palette (index, false , PALETTE_SOLID_WRAP, 0 ), uint8_t (segmentSampleAvg*8 )));
6503
6504
SEGMENT.setPixelColor (SEGLEN/2 -i-1 , color_blend (SEGCOLOR (1 ), SEGMENT.color_from_palette (index, false , PALETTE_SOLID_WRAP, 0 ), uint8_t (segmentSampleAvg*8 )));
6504
6505
}
@@ -6620,7 +6621,7 @@ uint16_t mode_midnoise(void) { // Midnoise. By Andrew Tuline.
6620
6621
if (maxLen >SEGLEN/2 ) maxLen = SEGLEN/2 ;
6621
6622
6622
6623
for (unsigned i=(SEGLEN/2 -maxLen); i<(SEGLEN/2 +maxLen); i++) {
6623
- uint8_t index = inoise8 (i*volumeSmth+SEGENV.aux0 , SEGENV.aux1 +i*volumeSmth); // Get a value from the noise function. I'm using both x and y axis.
6624
+ uint8_t index = perlin8 (i*volumeSmth+SEGENV.aux0 , SEGENV.aux1 +i*volumeSmth); // Get a value from the noise function. I'm using both x and y axis.
6624
6625
SEGMENT.setPixelColor (i, SEGMENT.color_from_palette (index, false , PALETTE_SOLID_WRAP, 0 ));
6625
6626
}
6626
6627
@@ -6648,7 +6649,7 @@ uint16_t mode_noisefire(void) { // Noisefire. By Andrew Tuline.
6648
6649
if (SEGENV.call == 0 ) SEGMENT.fill (BLACK);
6649
6650
6650
6651
for (unsigned i = 0 ; i < SEGLEN; i++) {
6651
- unsigned index = inoise8 (i*SEGMENT.speed /64 ,strip.now *SEGMENT.speed /64 *SEGLEN/255 ); // X location is constant, but we move along the Y at the rate of millis(). By Andrew Tuline.
6652
+ unsigned index = perlin8 (i*SEGMENT.speed /64 ,strip.now *SEGMENT.speed /64 *SEGLEN/255 ); // X location is constant, but we move along the Y at the rate of millis(). By Andrew Tuline.
6652
6653
index = (255 - i*256 /SEGLEN) * index/(256 -SEGMENT.intensity ); // Now we need to scale index so that it gets blacker as we get close to one of the ends.
6653
6654
// This is a simple y=mx+b equation that's been scaled. index/128 is another scaling.
6654
6655
@@ -6679,7 +6680,7 @@ uint16_t mode_noisemeter(void) { // Noisemeter. By Andrew Tuline.
6679
6680
if (maxLen > SEGLEN) maxLen = SEGLEN;
6680
6681
6681
6682
for (unsigned i=0 ; i<maxLen; i++) { // The louder the sound, the wider the soundbar. By Andrew Tuline.
6682
- uint8_t index = inoise8 (i*volumeSmth+SEGENV.aux0 , SEGENV.aux1 +i*volumeSmth); // Get a value from the noise function. I'm using both x and y axis.
6683
+ uint8_t index = perlin8 (i*volumeSmth+SEGENV.aux0 , SEGENV.aux1 +i*volumeSmth); // Get a value from the noise function. I'm using both x and y axis.
6683
6684
SEGMENT.setPixelColor (i, SEGMENT.color_from_palette (index, false , PALETTE_SOLID_WRAP, 0 ));
6684
6685
}
6685
6686
@@ -7095,7 +7096,7 @@ uint16_t mode_noisemove(void) { // Noisemove. By: Andrew Tuli
7095
7096
7096
7097
uint8_t numBins = map (SEGMENT.intensity ,0 ,255 ,0 ,16 ); // Map slider to fftResult bins.
7097
7098
for (int i=0 ; i<numBins; i++) { // How many active bins are we using.
7098
- unsigned locn = inoise16 (strip.now *SEGMENT.speed +i*50000 , strip.now *SEGMENT.speed ); // Get a new pixel location from moving noise.
7099
+ unsigned locn = perlin16 (strip.now *SEGMENT.speed +i*50000 , strip.now *SEGMENT.speed ); // Get a new pixel location from moving noise.
7099
7100
// if SEGLEN equals 1 locn will be always 0, hence we set the first pixel only
7100
7101
locn = map (locn, 7500 , 58000 , 0 , SEGLEN-1 ); // Map that to the length of the strand, and ensure we don't go over.
7101
7102
SEGMENT.setPixelColor (locn, color_blend (SEGCOLOR (1 ), SEGMENT.color_from_palette (i*64 , false , PALETTE_SOLID_WRAP, 0 ), uint8_t (fftResult[i % 16 ]*4 )));
@@ -7545,7 +7546,7 @@ uint16_t mode_2Dsoap() {
7545
7546
int32_t ioffset = scale32_x * (i - cols / 2 );
7546
7547
for (int j = 0 ; j < rows; j++) {
7547
7548
int32_t joffset = scale32_y * (j - rows / 2 );
7548
- uint8_t data = inoise16 (noisecoord[0 ] + ioffset, noisecoord[1 ] + joffset, noisecoord[2 ]) >> 8 ;
7549
+ uint8_t data = perlin16 (noisecoord[0 ] + ioffset, noisecoord[1 ] + joffset, noisecoord[2 ]) >> 8 ;
7549
7550
noise3d[XY (i,j)] = scale8 (noise3d[XY (i,j)], smoothness) + scale8 (data, 255 - smoothness);
7550
7551
}
7551
7552
}
@@ -8050,7 +8051,7 @@ uint16_t mode_particlefire(void) {
8050
8051
if (SEGMENT.call % 10 == 0 )
8051
8052
SEGENV.aux1 ++; // move in noise y direction so noise does not repeat as often
8052
8053
// add wind force to all particles
8053
- int8_t windspeed = ((int16_t )(inoise8 (SEGENV.aux0 , SEGENV.aux1 ) - 127 ) * SEGMENT.custom2 ) >> 7 ;
8054
+ int8_t windspeed = ((int16_t )(perlin8 (SEGENV.aux0 , SEGENV.aux1 ) - 127 ) * SEGMENT.custom2 ) >> 7 ;
8054
8055
PartSys->applyForce (windspeed, 0 );
8055
8056
}
8056
8057
SEGENV.step ++;
@@ -8059,7 +8060,7 @@ uint16_t mode_particlefire(void) {
8059
8060
if (SEGMENT.call % map (firespeed, 0 , 255 , 4 , 15 ) == 0 ) {
8060
8061
for (i = 0 ; i < PartSys->usedParticles ; i++) {
8061
8062
if (PartSys->particles [i].y < PartSys->maxY / 4 ) { // do not apply turbulance everywhere -> bottom quarter seems a good balance
8062
- int32_t curl = ((int32_t )inoise8 (PartSys->particles [i].x , PartSys->particles [i].y , SEGENV.step << 4 ) - 127 );
8063
+ int32_t curl = ((int32_t )perlin8 (PartSys->particles [i].x , PartSys->particles [i].y , SEGENV.step << 4 ) - 127 );
8063
8064
PartSys->particles [i].vx += (curl * (firespeed + 10 )) >> 9 ;
8064
8065
}
8065
8066
}
@@ -8276,8 +8277,8 @@ uint16_t mode_particlebox(void) {
8276
8277
SEGENV.aux0 -= increment;
8277
8278
8278
8279
if (SEGMENT.check1 ) { // random, use perlin noise
8279
- xgravity = ((int16_t )inoise8 (SEGENV.aux0 ) - 127 );
8280
- ygravity = ((int16_t )inoise8 (SEGENV.aux0 + 10000 ) - 127 );
8280
+ xgravity = ((int16_t )perlin8 (SEGENV.aux0 ) - 127 );
8281
+ ygravity = ((int16_t )perlin8 (SEGENV.aux0 + 10000 ) - 127 );
8281
8282
// scale the gravity force
8282
8283
xgravity = (xgravity * SEGMENT.custom1 ) / 128 ;
8283
8284
ygravity = (ygravity * SEGMENT.custom1 ) / 128 ;
@@ -8348,11 +8349,11 @@ uint16_t mode_particleperlin(void) {
8348
8349
uint32_t scale = 16 - ((31 - SEGMENT.custom3 ) >> 1 );
8349
8350
uint16_t xnoise = PartSys->particles [i].x / scale; // position in perlin noise, scaled by slider
8350
8351
uint16_t ynoise = PartSys->particles [i].y / scale;
8351
- int16_t baseheight = inoise8 (xnoise, ynoise, SEGENV.aux0 ); // noise value at particle position
8352
+ int16_t baseheight = perlin8 (xnoise, ynoise, SEGENV.aux0 ); // noise value at particle position
8352
8353
PartSys->particles [i].hue = baseheight; // color particles to perlin noise value
8353
8354
if (SEGMENT.call % 8 == 0 ) { // do not apply the force every frame, is too chaotic
8354
- int8_t xslope = (baseheight + (int16_t )inoise8 (xnoise - 10 , ynoise, SEGENV.aux0 ));
8355
- int8_t yslope = (baseheight + (int16_t )inoise8 (xnoise, ynoise - 10 , SEGENV.aux0 ));
8355
+ int8_t xslope = (baseheight + (int16_t )perlin8 (xnoise - 10 , ynoise, SEGENV.aux0 ));
8356
+ int8_t yslope = (baseheight + (int16_t )perlin8 (xnoise, ynoise - 10 , SEGENV.aux0 ));
8356
8357
PartSys->applyForce (i, xslope, yslope);
8357
8358
}
8358
8359
}
@@ -9720,7 +9721,7 @@ uint16_t mode_particleBalance(void) {
9720
9721
int32_t increment = (SEGMENT.speed >> 6 ) + 1 ;
9721
9722
SEGENV.aux0 += increment;
9722
9723
if (SEGMENT.check3 ) // random, use perlin noise
9723
- xgravity = ((int16_t )inoise8 (SEGENV.aux0 ) - 128 );
9724
+ xgravity = ((int16_t )perlin8 (SEGENV.aux0 ) - 128 );
9724
9725
else // sinusoidal
9725
9726
xgravity = (int16_t )cos8 (SEGENV.aux0 ) - 128 ;// ((int32_t)(SEGMENT.custom3 << 2) * cos8(SEGENV.aux0)
9726
9727
// scale the force
@@ -10072,7 +10073,7 @@ uint16_t mode_particle1Dsonicstream(void) {
10072
10073
else PartSys->particles [i].ttl = 0 ;
10073
10074
}
10074
10075
if (SEGMENT.check1 ) // modulate colors by mid frequencies
10075
- PartSys->particles [i].hue += (mids * inoise8 (PartSys->particles [i].x << 2 , SEGMENT.step << 2 )) >> 9 ; // color by perlin noise from mid frequencies
10076
+ PartSys->particles [i].hue += (mids * perlin8 (PartSys->particles [i].x << 2 , SEGMENT.step << 2 )) >> 9 ; // color by perlin noise from mid frequencies
10076
10077
}
10077
10078
10078
10079
if (loudness > threshold) {
0 commit comments