Don't always draw waveforms inverted!

This commit is contained in:
Jonathan Moore Liles 2008-05-12 22:06:07 -05:00
parent f5db8ac7ad
commit 71c4964174
1 changed files with 4 additions and 4 deletions

View File

@ -83,8 +83,8 @@ Waveform::draw ( int X, int Y, int W, int H,
else
fl_color( color );
const int ty = mid + ( halfheight * p.min );
const int by = mid + ( halfheight * p.max );
const int ty = mid - ( halfheight * p.min );
const int by = mid - ( halfheight * p.max );
fl_line( x, ty, x, by );
/* if ( outline ) */
@ -112,7 +112,7 @@ Waveform::draw ( int X, int Y, int W, int H,
j = start;
for ( int x = X; x < X + W; ++x, j += skip )
fl_vertex( x, ty + ( halfheight * pbuf[ j ].min ) );
fl_vertex( x, ty - ( halfheight * pbuf[ j ].min ) );
fl_end_line();
@ -121,7 +121,7 @@ Waveform::draw ( int X, int Y, int W, int H,
j = start;
for ( int x = X; x < X + W; ++x, j += skip )
fl_vertex( x, ty + ( halfheight * pbuf[ j ].max ) );
fl_vertex( x, ty - ( halfheight * pbuf[ j ].max ) );
fl_end_line();