Plotter visual questions about script
-
I created a script for a custom plotter. I have two questions.
I intentionally set the knob for the amount to a low maximum because I don’t want the LFO to have too much effect. However, this results in the plotter not being clearly visible. Is there a way to make the plotter react more strongly in terms of visual representation?
And my other question is how to remove the text and centerline from my plotter using a script?
//vintage plotter LAF; const plotter = Content.addFloatingTile("plotter", 0, 0); const var LFO1 = Synth.getModulator("RC20"); const var Laf = Content.createLocalLookAndFeel(); laf.registerFunction("drawAnalyserBackground", function(g, obj) { //Console.print(trace(obj)); g.setGradientFill([Colours.cadetblue, 0, 0, Colours.orange, obj.area[2]*0.5, 100]); g.fillRoundedRectangle(obj.area, 4); }); laf.registerFunction("drawAnalyserPath", function(g, obj) { //Console.print(trace(obj)); g.setColour(Colours.white); g.setGradientFill([Colours.withAlpha(Colours.orangered, 0.5), 0, 0, Colours.withAlpha(Colours.red, 0.5), obj.area[2]*0.5, 100]); g.fillPath(obj.path, obj.area); g.setColour(Colours.white); g.drawPath(obj.path, obj.area, 1); }); plotter.setLocalLookAndFeel(laf);```
-
@tiesvdam said in Plotter visual questions about script:
I created a script for a custom plotter. I have two questions.
I intentionally set the knob for the amount to a low maximum because I don’t want the LFO to have too much effect. However, this results in the plotter not being clearly visible. Is there a way to make the plotter react more strongly in terms of visual representation?
And my other question is how to remove the text and centerline from my plotter using a script?
//vintage plotter LAF; const plotter = Content.addFloatingTile("plotter", 0, 0); const var LFO1 = Synth.getModulator("RC20"); const var Laf = Content.createLocalLookAndFeel(); laf.registerFunction("drawAnalyserBackground", function(g, obj) { //Console.print(trace(obj)); g.setGradientFill([Colours.cadetblue, 0, 0, Colours.orange, obj.area[2]*0.5, 100]); g.fillRoundedRectangle(obj.area, 4); }); laf.registerFunction("drawAnalyserPath", function(g, obj) { //Console.print(trace(obj)); g.setColour(Colours.white); g.setGradientFill([Colours.withAlpha(Colours.orangered, 0.5), 0, 0, Colours.withAlpha(Colours.red, 0.5), obj.area[2]*0.5, 100]); g.fillPath(obj.path, obj.area); g.setColour(Colours.white); g.drawPath(obj.path, obj.area, 1); }); plotter.setLocalLookAndFeel(laf);```
try scaling obj.area
-
@Lindon Thank you for the quick response. I just meant the vibration is not clearly visible. See example:
I know this is because the LFO is set to a low value. However, I hope there’s a way to make this larger with scripting, for example, showing -1st instead of -12.
-
@tiesvdam as I say scale your output
-
@Lindon Oh sorry i looked at the wrong area! Thanks!
-
@Lindon Again thanks for you tips but:
This makes it thicker, but the line doesn’t respond more intensely to the LFO, so it doesn’t go further down. What you mean isn’t exactly what I meant. Do you know a solution for this?
-
@tiesvdam look at the contents of obj.area - its an array[x,y,w,h] try using [x,y,w,h*2] to get a taller area to draw your path into....
so like this:
var a = obj.area; g.setColour(Colours.white); g.drawPath(obj.path, [a[0],a[1],a[2],a[3]*2], 1);