| 22 | struct DrawRasterToWaveSimulator { |
| 23 | DrawRasterToWaveSimulator(WaveEffect* wave_fx) : mWaveFx(wave_fx) {} |
| 24 | void draw(const fl::vec2<int> &pt, uint32_t /*index*/, uint8_t value) { |
| 25 | float valuef = value / 255.0f; |
| 26 | int xx = pt.x; |
| 27 | int yy = pt.y; |
| 28 | mWaveFx->addf(xx, yy, valuef); |
| 29 | } |
| 30 | WaveEffect* mWaveFx; |
| 31 | }; |
| 32 |