Missing In Docs: sample_modulation_sets[]:insert_device_at()

There seems to be a missing parameter in the API docs for:

sample_modulation_sets:insert_device_at (device_path , missing param ,index)

The docs say:

– Insert a new device at the given position. “device_path” must be one of
– renoise.song().instruments.sample_modulation_sets.available_devices.
.
.
renoise.song().instruments.sample_modulation_sets:insert_device_at(device_path, index)
→ [returns new renoise.SampleModulationDevice object]

But in order to inset the device in a specific lane you need to put in an extra int so it becomes:

:insert_device_at(device_path, lane_index ,index)

Where lane_index is one of the following:

VOLUME = 1
PANNING = 2
PITCH = 3
CUTOFF = 4
RESONANCE = 5

Just Double checked here to make sure I didn’t have out of date docs but it looks to be the same:

I just ran into this same problem on R3.2.4 with Win10 x64. I can’t get the insert_device_at() to work for the sample_modulation_sets. This issue is directly related to this:

Did you try to add the extra undocumented lane_index parameter? This was only something missing in the docs. You just need to add a number 1-5 for the following ‘lanes’:

VOLUME = 1
PANNING = 2
PITCH = 3
CUTOFF = 4
RESONANCE = 5

sample_modulation_sets:insert_device_at(device_path, lane_index ,index)

///////////////////

Not sure it will help with your other issue however.

It is related. Thanks for the note! I will try it!

The API does not give access to this index. For example, there is no way to select the Vol, Pan, Pitch, Cut, Res tabs.
Try building a tool that can change these tabs. A slider for example. You will see that you cannot.

Apparently the API is missing some things related to the selection of these tabs and the correct selection of the devices within each chain.

Also, the devices are listed inside each modulation_set in a somewhat messy way. This needs a general overhaul to fix the API.

I think the modulation devices should always be accumulated in this order: Vol → Pan → Pitch → Cut → Res

Note: Each modulation set is limited to 12 devices per target, and has 6 targets to deposit (Vol, Pan Pitch …). From the API, It is necessary to be able to select the target previously to be able to insert.

Related Doc

renoise.SampleModulationDevice.TARGET_VOLUME
renoise.SampleModulationDevice.TARGET_PANNING
renoise.SampleModulationDevice.TARGET_PITCH
renoise.SampleModulationDevice.TARGET_CUTOFF
renoise.SampleModulationDevice.TARGET_RESONANCE
renoise.SampleModulationDevice.TARGET_DRIVE

– Where the modulation gets applied (Volume, Pan, Pitch, Cutoff, Resonance).
renoise.song().instruments.sample_modulation_sets.devices.target
→ [read-only, enum = TARGET]

Edit: All of this has not yet been added in R3.3.0.

This still hasn’t been corrected in the docs. Also, for some reason when inserting a Stepper it has 513 steps?

Sorry, missed that one.

Docs will be updated in the new Renoise APi definitions thanks to unlessgames: sample modulation set fixes and updates by unlessgames · Pull Request #22 · renoise/definitions · GitHub

Also, for some reason when inserting a Stepper it has 513 steps?

This will be fixed as well in the next Renoise update.

1 Like