Help with the dict family!
m running into some confusion with the new dict objects. the problem is that the syntax isnt explained very well (or maybe i miss something? my english is ok but not the best…)
i ve got a pretty big synth patch. in each oscillator bpatcher i
ve got 2 multisliders with variable numbers of sliders. ive already set up an pattr system for the whole ui but i want to have my own presets for the multisliders (they are used to create wavetables), so i thought dict is the way to go!?
the preset should contain both multisliders and i want to give each preset a unique name in the moment of saving, for later recall. but it must be possible to recall the multislider presets seperatly from the rest of the ui. and finally when i recall a preset from pattrstorage i want to recall the multislider presets but not for the individual multisliders.
i thought it must be possible to create keys dynamiclly, but it seems like that they must be predefined? is that true?
as my first step i created a dict.pack for the 2 multisliders. but how can i name this packed lists in the moment of creation and how can is store loads of these.
when i load the data from the dict.pack into a dict it works fine, but when i want to add another preset it doesnt add it, it replaces the old preset!
or should i forget dict and find my way with pattrstorage (for me this seems to complicated because of the naming and seperation from the rest of the ui)
thanks in advance!
(i hope that wasn`t to confuse)
s definitly not true that i cant set keys after creating the object :-)
more simple: how is it possible to set a key with 2 lists?
----------begin_max5_patcher---------- 1415.3oc6ZtziaaCD.9r8uBAATfV.GCwmhp254hdo4XQQfrEytZirjgDc5lD j+6kbnjV4Wxz6ZSazzD.KKtjiF9w4Eo72lNIbQ0yxlvfeM3uBlL4aSmLAZxz vj16mDtJ84kEoMP2BKk+S0hmBmY+SJ4yJnYUPdPdWqkaVUsQUHUvPvss9wpR US9Wkl1P34QsMa6o5KqkV0HLuTENydI3ua6z5T0xGyKe3C0xkJa+nQj4wrYA HdhVVAD7b8M3n4Q8CJOCTMs59tDR3.snLcE7vB+s57zhAZcdYmRiLs88oSMe L6sglZ8LTF7GaJT43FUpRdYvjgQiCHCLlEPIwlKI.kNJevmIevWN9zrtVuV+ wVB8dCg9ohrCCIz4Bow.DKB.DQ.nAgiGkPQ2NKnNB8fT4eJQnbvyJV.ThNNk P2NJAgfNdXH5qOLzLmCJwvL.OHfRrjwhIIRt8VTf0DxmVSbvZhDibvmSHtKh Zi7YTaLmLHpMBSGEP2vv1es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9bJKNjveqWTG3Sh+7HM+bDNcDBj+zmHW3CdqE0qp9fcgOm YDKp80EvhrAtrmgx12YOWp1fYBzUIVFrrhbg09YsWfuDYq1M6PLbLkT6qsDY +oCL7lDd6t4X1ueE.sHwEiZ+4jA5yIW3i7l9vbIogHwu74TIUYX+pOjSwG+k DiguuRZHbonLg+RZ3TfUg+rePNwGOtd4RQGbuoNwI2W3ASbUe7j4r39Re32W QeXtXMy7WI8Lpq5ieVtH2Yaw.4h9.6S60vG6Y1jtd8mk0MsxDTkvUoOYeY.7 Yvs4k1aAIFVK+bdW+ISMR66S+WPoMBpO -----------end_max5_patcher-----------
Bit of a kludge as 1: i should be asleep and 2: I am only coming to terms with dict myself Also, it doesn’t use the hierarchical possibilities very well, – so there is plenty of scope for refinement. Using one entry (key value pair) for each multislider – rather than worrying about combining the two multislider value sets into one key…
nice! i never worked with sprintf, but i see it would be worth to do :-)
thank you very much! so now the only problem is to give the preset names like square32/square64 or something like that.