Hey AposMus, many thanks for your feedback. Your script is very interesting and works changing the visual value of the “single” destination, but it does not allow to change the parameter from the “single” destination but only from “general”. If I try to do it, it give me an error message.
This is a similar example of my situation, where I can select a different kind of filter shape from “general”, “Osc Zone” and “Wavetable”
Hope it can describe better my situation.
-- FILTER SHAPE SELECTION GENERAL
zone=this.parent:getZone()
filterShapes={
{name="LP24", index=0},
{name="LP12", index=2},
{name="BP12", index=4},
{name="BP24", index=5},
{name="HP24", index=10},
{name="HP12", index=12},
}
function getFilterShapeNames()
filterShapeNames={}
for i=1,#filterShapes do
filterShapeNames[i]=filterShapes[i].name
end
end
getFilterShapeNames()
-- keep track of last applied parameter values
last = {}
function filterShapeChanged()
setParameterOfZones("Filter.ShapeA",filterShapes[FilterShape].index)
end
defineParameter("FilterShape",nil,1,filterShapeNames,filterShapeChanged)
-- FILTER SHAPE SELECTION OSCs
defineSlotLocal("Filter.ShapeA")
filterShapesOSCs={
{name="LP24", index=0},
{name="LP12", index=2},
{name="BP12", index=4},
{name="BP24", index=5},
{name="HP24", index=10},
{name="HP12", index=12},
}
function getFilterShapeOSCsNames()
filterShapeOSCsNames={}
for i=1,#filterShapesOSCs do
filterShapeOSCsNames[i]=filterShapesOSCs[i].name
end
end
getFilterShapeOSCsNames()
-- keep track of last applied parameter values
last = {}
function filterShapeOSCsChanged()
this.parent:getZone("Synth Zone"):setParameter("Filter.ShapeA",filterShapesOSCs[FilterShapeOSCs].index)
end
defineParameter("FilterShapeOSCs",nil,1,filterShapeOSCsNames,filterShapeOSCsChanged)
-- FILTER SHAPE SELECTION WAVE
defineSlotLocal("Filter.ShapeA")
filterShapesWA={
{name="LP24", index=0},
{name="LP12", index=2},
{name="BP12", index=4},
{name="BP24", index=5},
{name="HP24", index=10},
{name="HP12", index=12},
}
function getFilterShapeWANames()
filterShapeWANames={}
for i=1,#filterShapesWA do
filterShapeWANames[i]=filterShapesWA[i].name
end
end
getFilterShapeWANames()
-- keep track of last applied parameter values
last = {}
function filterShapeWAChanged()
this.parent:getZone("Wavetable"):setParameter("Filter.ShapeA",filterShapesWA[FilterShapeWA].index)
end
defineParameter("FilterShapeWA",nil,1,filterShapeWANames,filterShapeWAChanged)