I guess this leads to a feature request for future versions of the scripting API to allow scripts to perform arbitrary drawing operations in the sample view.
+1, would be wicked to see whats being done, before doing it…
also, could we have the choice of the slices being in new instrument slots, instead of a keymapped 1 instrument per chop? i for one would appreciate being able to unravel loops with sampleslicer to new sampleslots…
Such a slicer would be great!
I need this , since I can’t export from renoise my turntable recorded wav’s into Recycle and am to lazy to chop something renoise manualy into 32 chops.
- it would cut out the need of such of external slicer. I already threw out a couple of vst’s because of
the build in dsp’s.
It-Alien, have you already looked if the previous mentioned even is possible in LUA?
ps. the already developed tools are great!
Very nice job everybody and Renoise thank you for making scripting possible!
+1
moving the loop markers is possible; the only issue may be doing this with a timer. I didn’t look at it until now. I will try to do it soon
I have made a sketch of the visualization functionality, which seems to work fine. Unfortunately, there is a problem with modal dialogs (see here) so I had to turn this tool into a non-modal dialog; the code then needs more modifications in order to be crash-proof, so I will not publish it officially for now.
please check if it does fulfil your needs.
note: I have decided to use fake selection blocks in order to visualize the slices instead of loop markers. I think this solution is far better and, although the initial selection gets restored if no slicing is done when the dialog closes, it’s anyway more error-proof
when I run that, the selection moves back and forth a bit, then I get:
main.lua:436: ‘invalid selection range. end must be <= start.’
(btw I found it easiest to set start and end to 1 and number_of_frames respectively before setting a selection)
Changing from 4 slices to 16, I got:
[i]"Script ‘C:\Users\plugexpert\AppData\Roaming\Renoise\V2.6.0\Scripts\Tools\com.renoise.SampleSlicer.xrnx\main.lua’ failed in one of its notifiers. The notifier will be disabled to prevent further errors:
std::logic_error: ‘invalid selection range. end must be <= start.’
stack traceback:
[C]: ?
[C]: in function ‘__newindex’
[string “do…”]:22: in function <[string “do…”]:11>
main.lua:436: in function main.lua:410"[/i]
yeah, thanks, already fixed it locally. also, I forgot to say that the mockup does not contain the “Slice” and “Cancel” buttons, but I guess you noticed it already
also, changing slicing mode to BPM does not work.
apart from this, do you like the way it works?
I like that it visually runs through the sample and gives an indication of where the sample gets cut.
Oh, theres an error in the error message. Fixed
yeah was wondering about that
but i like the way it works now,its a good solution you found i think
attached is a version which hopefully fixes all the above mentioned issues. the buttons will be back when the problem with modal dialogs will be fixed or I will get a non-modal, crash-proof version done
looks good,when i choose either seconds or bpm the “visualization” stops though??
it created a new one apparently, because though the same thing as above happens for me, the error now is in main.lua line 448 ^^
(the sample I have loaded is kinda short (0.5 secs), but that shouldn’t make a difference, right?)
This:
[i]"Script ‘C:\Users\plugexpert\AppData\Roaming\Renoise\V2.6.0\Scripts\Tools\com.renoise.SampleSlicer.xrnx\main.lua’ failed in one of its notifiers. The notifier will be disabled to prevent further errors:
std::logic_error: ‘invalid selection range. end must be <= start.’
stack traceback:
[C]: ?
[C]: in function ‘__newindex’
[string “do…”]:22: in function <[string “do…”]:11>
main.lua:448: in function main.lua:422"[/i]
Also trying to get a sample sync value of 1 on the slices in th renoise install amen break gives an error notice. Something like this value can’t be set or is too small, trying to change it to a higher value though is difficult as every time a new slice gets animated, the error notice pops up .
I did not know yet b3 was released.
in b3 the visualization works fine, only the error mentioned by jonas occurs.
but I can see now what you are trying to accomplish It-Alien
personally I would prefer this kind of slicer
I have added the “Slice!” button again, since this version seems to work fine. I have fused the function which previews the slicing with the one which actually does the slicing, in order to be more error-proof.
In my brief tests I didn’t find anything wrong so, if you also think it works well, I will publish it officially
Nice1!
By the way, why is a sync value of 1 forbidden in the script?
EDIT:
[i]Got the following bug, changing the sync value to 2, using 32 slices on the default Renoise install amen break:
"Script ‘C:\Users\plugexpert\AppData\Roaming\Renoise\V2.6.0\Scripts\Tools\com.renoise.SampleSlicer.xrnx\main.lua’ failed in one of its notifiers:
main.lua:424: attempt to compare number with string
stack traceback:
main.lua:424: in function ‘slice_it’
main.lua:206: in function main.lua:205"[/i]
One slice did get created, turning beat-sync on seems to be the culprit.
thanks for the report. Now samples can be synched to 1 line and the error should not occur again