diff options
Diffstat (limited to 'rotord/src')
| -rw-r--r-- | rotord/src/nodes_drawing.h | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/rotord/src/nodes_drawing.h b/rotord/src/nodes_drawing.h index 375ab03..ad5bc8c 100644 --- a/rotord/src/nodes_drawing.h +++ b/rotord/src/nodes_drawing.h @@ -166,11 +166,12 @@ namespace Rotor { if (attributes["mode"]->value=="fill"||attributes["mode"]->value=="both") { cairo_set_source_rgb(cr, fill.Rfloat(),fill.Gfloat(),fill.Bfloat()); cairo_save(cr); //not really even necessary? - cairo_translate(cr, 0, frame.h/2); + cairo_translate(cr, 0, 0); + //cairo_line_to(cr, 0, frame.h/2); for (int i=0;i<frame.w;i++){ cairo_line_to(cr,i,(((int16_t)frame.audio->samples[i*frame.audio->channels])*frame.h)>>16); } - cairo_line_to(cr, frame.w, frame.h/2); + cairo_line_to(cr, frame.w, 0); cairo_close_path(cr); cairo_restore (cr); //not really even necessary? cairo_fill(cr); @@ -178,10 +179,11 @@ namespace Rotor { if (attributes["mode"]->value=="line"||attributes["mode"]->value=="both") { cairo_set_source_rgb(cr, stroke.Rfloat(),stroke.Gfloat(),stroke.Bfloat()); cairo_save(cr); //not really even necessary? - cairo_translate(cr, 0, frame.h/2); + cairo_translate(cr, 0, 0); for (int i=0;i<frame.w;i++){ cairo_line_to(cr,i,(((int16_t)frame.audio->samples[i*frame.audio->channels])*frame.h)>>16); } + cairo_line_to(cr, frame.w, 0); cairo_restore (cr); //not really even necessary? cairo_stroke(cr); } |
