Native: Slice Markers prev/next buttons


(Denim) #1

Hi, a suggestion for a small but very useful workflow improvement - and I think this should be a native one:

Buttons for jumping to previous/next slice marker in the Sample Editor. Could be next to for example the “Slice” button. Also: view-wise, it should jump so that the slice marker is positioned in the center of the view you get to, and preserve the zoom level.

Most audio editor programs supporting markers of various sorts have this functionality, and is a big timesaver, at least for me.

Why: I do a lot of long audio recordings in renoise, and often I need to slice them up by hand (not automatically), and then I first usually slice everything roughly while zoomed all the way out, and then start to zoom in on each single slice marker to do fine adjustments. But it’s hard to navigate in a long waveform while zoomed in, so then I need to zoom all the way out again, and in again, and it’s very tedious. Prev/next buttons as described would be a huge timesaver in these cases.


(Raul (ulneiz)) #2

[ALT Right] and (ALT Left) are free. Maybe it is possible to create a tool (script with LUA) with 2 functions that do both jumps and assign those 2 commands.

-- Change the sample position of an existing slice marker. see also property 
-- 'samples[].slice_markers'.
-- When moving a marker behind or before an existing other marker, existing 0S
-- effects or notes will automatically be updated to ensure that the old slices
-- are played back just as before.
renoise.song().instruments[].samples[]:move_slice_marker(old_marker_pos, new_marker_pos)

(trueschool) #3

I like this idea. That’d definitely help my workflow.


(Raul (ulneiz)) #4

Apparently it is not possible. The .selected_slice_marker_index property does not exist in the API. Therefore, it is not possible to find the slice_marker selected at any time.
We only have one table with the indexes of each slice_marker, but not the selected index.

The :move_slice_marker function only serves to change the value of a particular index in the table: renoise.song().selected_sample.slice_markers.

That is, we can manipulate the indexes, but not navigate between them.

It seems that the only solution is to click with the mouse on the slice marker.


(Raul (ulneiz)) #5

The function would be quite simple if such property existed. It would look like this (select next slice marker):

local function next_slice_marker()
  local song=renoise.song()
  local sss=song.selected_sample
  if (sss) then
    local mrk=#song.selected_sample.slice_markers  --0 or >=1
    --print(mrk)
    if (mrk>=1) then
      --song.selected_slice_marker_index not exixt inside the API (return a number, or nil?)
      local ssmi=song.selected_slice_marker_index
      if (ssmi<mrk) then
        song.selected_slice_marker_index=ssmi+1
      end
    end
  end
end
next_slice_marker()

(Denim) #6

Thanks all, for your feedback, and looks like a good solution Raul! Too bad the API don’t support this behaviour though, but maybe an update in the future will allow it. Would be oh so sweet.