diff -r a8052f8ab19c -r 192d7d7f7bb4 client/annotviz/app/js/doubleroll.js --- a/client/annotviz/app/js/doubleroll.js Fri Apr 10 16:45:34 2015 +0200 +++ b/client/annotviz/app/js/doubleroll.js Mon Apr 13 17:11:47 2015 +0200 @@ -23,9 +23,10 @@ lineInterval: 5000, noteHeight: undefined, range: { - bottom: 60, - top: 70, + bottom: 50, + top: 90, }, + dynamicRange: true, }, { height: 384, @@ -36,6 +37,7 @@ bottom: 0, top: 128, }, + dynamicRange: false, }, ], framerate: 25, @@ -102,11 +104,19 @@ lineInterval: lineInterval, offsetMusic: offsetMusic, }; + + var lineGraphics = new PIXI.Graphics() + .beginFill(this.lineFillColor) + .lineStyle(1, this.lineColor) + .moveTo(Math.floor(sceneWidth*zeroShift), 0) + .lineTo(-sceneWidth - Math.floor(sceneWidth*zeroShift), 0) + .endFill(); + this.container.addChild(lineGraphics); var yInit = opts.yInit || 0; var linesDown = true; _(opts.pianorolls).forEach(function(prDef, i) { - var prNoteHeight = noteHeight || prDef.noteHeight || prDef.height / (prDef.top - prDef.bottom); + var prNoteHeight = noteHeight || prDef.noteHeight || prDef.height / (prDef.range.top - prDef.range.bottom + 1); var prTimeWidth = prDef.timeWidth || timeWidth; pianorollList.push(new PianoRoll(_({ yInit: yInit, @@ -116,6 +126,7 @@ noteHeight: prNoteHeight, lineInterval: prDef.lineInterval, range: prDef.range, + dynamicRange: prDef.dynamicRange, }).defaults(pianorollOptions).value())); yInit += prDef.height; linesDown = !linesDown;