fine tune waveform and ook again (#2322)

This commit is contained in:
sommermorgentraum 2024-11-04 03:19:29 +08:00 committed by GitHub
parent abd6177303
commit bea9f444c6
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 33 additions and 6 deletions

View file

@ -2681,9 +2681,9 @@ void Waveform::paint(Painter& painter) {
x = prev_x + x_inc;
h /= 2;
prev_y = y_offset + h + (*(data_start++) * y_scale);
prev_y = y_offset + h - (*(data_start++) * y_scale);
for (n = 1; n < length_; n++) {
y = y_offset + h + (*(data_start++) * y_scale);
y = y_offset + h - (*(data_start++) * y_scale);
display.draw_line({prev_x, prev_y}, {(Coord)x, y}, color_);
prev_x = x;