Hey danoise thanks for this tool!
I did a ruleset to override some of renoise’s default actions, kind of. A thing that bothered me about macros is that whenever I map certain macro to a knob, it would control that macro even if that instrument is not selected (this is expected), but if you map that knob to a vst parameter using the vst’s mapping functionality (if any) it would only work when the instrument containing the vst is selected (also expected).
What I did with your tool is mapping the knobs of my controller to the selected instrument’s macros this is a think I’ve been looking for a long time. Oh, and also mapping program changes to selected_instrument_index.
-----------------------------------------------------------
-- Ruleset definition for xRules
-- More info @ http://www.renoise.com/tools/xrules
-----------------------------------------------------------
return {
osc_enabled = false,
manage_voices = false,
description = "",
{
["osc_pattern"] = {
["pattern_in"] = "",
["pattern_out"] = "",
},
["name"] = "Input",
["actions"] = {
{
["route_message"] = "Current Ruleset:➜ Notes",
},
{
["route_message"] = "Current Ruleset:➜ CC",
},
{
["route_message"] = "Current Ruleset:➜ Macros",
},
{
["route_message"] = "Current Ruleset:➜ Instr. Selection",
},
},
["conditions"] = {},
["match_any"] = true,
["midi_enabled"] = true,
},
{
["osc_pattern"] = {
["pattern_in"] = "",
["pattern_out"] = "",
},
["name"] = "➜ Notes",
["actions"] = {
{
["output_message"] = "internal_raw",
},
},
["conditions"] = {
{
["message_type"] = {
["equal_to"] = "note_on",
},
},
{
2,
},
{
["message_type"] = {
["equal_to"] = "note_off",
},
},
},
["match_any"] = true,
["midi_enabled"] = false,
},
{
["osc_pattern"] = {
["pattern_in"] = "",
["pattern_out"] = "",
},
["name"] = "➜ CC",
["actions"] = {
{
["output_message"] = "internal_raw",
},
},
["conditions"] = {
{
["message_type"] = {
["equal_to"] = "controller_change",
},
},
},
["match_any"] = true,
["midi_enabled"] = false,
},
{
["osc_pattern"] = {
["pattern_in"] = "",
["pattern_out"] = "",
},
["name"] = "➜ Macros",
["actions"] = {
{
["call_function"] = "renoise.song().selected_instrument:macro(value_1 - 20).value = math.min(1.0, math.max(value_2/127, 0.0))",
},
{
["output_message"] = 1,
},
},
["conditions"] = {
{
["message_type"] = {
["equal_to"] = "controller_change",
},
},
},
["match_any"] = true,
["midi_enabled"] = false,
},
{
["osc_pattern"] = {
["pattern_in"] = "",
["pattern_out"] = "",
},
["name"] = "➜ Instr. Selection",
["actions"] = {
{
["call_function"] = "renoise.song().selected_instrument_index = values[1]+1",
},
{
["output_message"] = "internal_auto",
},
},
["conditions"] = {
{
["message_type"] = {
["equal_to"] = "program_change",
},
},
},
["match_any"] = true,
["midi_enabled"] = false,
}
}
(I don’t know how to fold code snipets, sorry for the long post)
I will be slowly adding stuff to this ruleset. In the meantime I would like to know if someone uses this tool to add similar functionality to renoise.
Chau!