MCPcopy Create free account
hub / github.com/FastLED/FastLED / fill_raw_noise8

Function fill_raw_noise8

src/noise.cpp.hpp:675–686  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

673// }
674
675void fill_raw_noise8(fl::u8 *pData, fl::u8 num_points, fl::u8 octaves, fl::u16 x, int scale, fl::u16 time) {
676 fl::u32 _xx = x;
677 fl::u32 scx = scale;
678 for(int o = 0; o < octaves; ++o) {
679 for(int i = 0,xx=_xx; i < num_points; ++i, xx+=scx) {
680 pData[i] = qadd8(pData[i],inoise8(xx,time)>>o);
681 }
682
683 _xx <<= 1;
684 scx <<= 1;
685 }
686}
687
688void fill_raw_noise16into8(fl::u8 *pData, fl::u8 num_points, fl::u8 octaves, fl::u32 x, int scale, fl::u32 time) {
689 fl::u32 _xx = x;

Callers 2

fill_noise8Function · 0.85
fill_noise16Function · 0.85

Calls 1

inoise8Function · 0.85

Tested by

no test coverage detected