nice one. will try it out. might be useful to combine this one with the beatslicer?
when i read the title, the first thing i thought was ‘random cuts!’. this would ofcourse only be useful on certain samples, but it is a nice feature i think. if you cut a complex drumloop up at random and play with the pieces it can get you some strange and wonderful results.
If you want to make the selection status update automatically, just add this at the end of the show_main_gui function in gui.lua :
[luabox]
function update_gui()
if not (range == renoise.song().selected_sample.sample_buffer.selection_range) then
range = renoise.song().selected_sample.sample_buffer.selection_range
statustext.text = math.floor((range[2] - range[1])/44.1)/1000 … " sec"
end
end
Checks to “renoise.song().instruments[].samples[].sample_buffer.has_sample_data” are missing right now. Tool causes and error when opened on an empty sample.
std::logic_error: 'can not access properties of a sample buffer with no sample data.'
stack traceback:
[C]: ?
[C]: in function '__index'
[string "do..."]:36: in function <[string "do..."]:35>
.\gui.lua:138: in function <.\gui.lua:13>
And one of my favorite nit picking: renoise.tool():add_menu_entry { name = “Sample Editor:Sample Knife” } -> name = “Sample Editor:Sample Knife…”
A small gui cosmetics proposal: Renoise supports part of the unicode symbol set in its GUI, so you can use text = “◂”, text = “▸” for the buttons.