Whole thing with Randomness is you can never guarantee this. When first playing with it I went through a load and they were quite nice and moving then randomly hit one with all very similar values and so much louder and stronger than before.
Although did think after my last posting I might try a -(minus)number_of_samples / 10 to the Volume to bring it a little lower (although this risks pushing it out of range at times, although maybe I should add for if/then safety checks) to the Volume value which is strangely from 0-4 (not 0-1)
If I understand that is what it currently does in Regenerate mode. You can load/edit a new sample and hit Regenerate and it will use the current sample to create the Unison. New mode will generate a new Instrument from that sample (probably with a fixed 8 layers on first outing.)
Been meaning to install and test that as renaming and then installing the zips is a pain! In fact been meaning to check if I can just edit the version actually loaded within Renoise but am currently doing it the most long-winded way possible!
Will have to look into math functions, or something, to try and get the spreads a bit different. Sine and Cosine are always going to be weighted at the edges, the opposite to a Bell Curve (which would be more friendly) although for the 0-1 range that can be cured with a 1-x but the math side will need revision and current methods are just a stop-gap solution to get some kind of automatic distribution.
Only tried with single cycles and breaks so far. Some good results with both. Single cycles often get that wavery depth (although forced to play them in the higher registers) and after multiple clickings you can get some good effects on breaks, where it sounds like the players are slipping out of time and slowing down, especially if mixed with some pitch commands
Anybody is welcome to try and chuck in a hand. When I’m a bit more happy with it I’ll give it its own Tool thread (and publish to the site) but for now I’ll leave it in the Ideas one
I don’t understand the second sentence. I have the scripting terminal open at all times, save changes and re-run the tool from the context menu. Did I misunderstand something?
But User Tools are not Installed Tools. If you have anything that uses renoise.tool() it will not run from the Terminal but instead throw up an error that its not defined.
Hence to test full tools, rather than small chunks, (especially when it comes to testing GUI stuff!) I’ve been having to create the Tool, drag and drop it onto Renoise to reinstall the edited version and give it a go again.
If the tool is enabled (it will be automatically, after you use Create Tool), any change to the tool (i.e. edit and save in scripting terminal&editor) will re-initialize the script and the next time you call the rightmousebutton context menu entry, it’s already updated. No need to keep disabling and enabling a script (you, for instance, lose midi + keyboard binds when you disable+enable a scrip)
Gone from edge weighted trig functions (due to having no internet to read up on LUA math library) to linear random number spread. (Still might go inverse trig weighted (similar to a bell curve) at some point in future.)
“New” function now implemented and will generate a new Instrument from the selected sample and create a Unison out of it.
Both Regen and New will now take the existing value for Finetune (and Transpose) of the currently selected Sample and use this as the base to work tuning adjustments from. Vol and Pan are purely random, although tweaked slightly for better ranges.
Variables at the start of the program do now actually affect the size of the spread of random adjustment. No GUI yet to make adjustments easy though.
ToDo:
You will get an error if trying to run it on a Sliced sample. I need to add a check for slices and (pop-up/status-bar) warning message.
Maybe some of the renaming bits suggested by Esaruono. So far the New takes the name of the selected sample and adds Unison to the end for the name of the new Instrument.
GUI to set spread value for easy user access.
Consider non-linear spread of values.
Finalise limits of Finetune.
Thoughts and ideas?
EDIT: Forgot the to attach.
EDIT2: Changed file as Renoise doesn’t seem to like a local for “renoise.song()” being declared early in a Tool, before it actually opens a (Template) Song.