jamoma / JamomaMax

Implementation of Jamoma for Cycling'74 Max:
http://www.jamoma.org
41 stars 9 forks source link

j.unit : doesn't work with list #871

Open avilleret opened 9 years ago

avilleret commented 9 years ago

as soon as I set the output, j.unitstops to work with list only the first converted element is fired

lossius commented 9 years ago

I'm not 100&% clear on what you mean. Do you mean that you can not use j.unit to convert e.g. a list of gain values in linear unit to decibel?

If so, that's a current limitation of the DataspaceLib itself.

avilleret commented 9 years ago

yes, I can't convert list of gain or angle it seems to only work with position but it seems to be a know issue then

lossius commented 9 years ago

Yes, this is a known limitation currently. The DataspaceLib implementation does not keep track of how many floats are required for various input and output units. If we extended it to keep track of this, it could see if the total number of floats received multiplies by this nicely, and if so, do a series of conversions in one go. In the meantime, here's a simple workaround in Max:


----------begin_max5_patcher----------
488.3ocyUssaiBCD8Y3qvxOyhvFBIceJ+GqpVY.KpiHFjuzltU8eesGC61ra
ZChFg5Cf0LdtbNyvL7RbDtp+DWiQeG8CTTzKwQQfJuhnQ4H7Q1o5NlFLCejq
0rVNNIbmgex.5KRQzTDIEkktw8P8uHzMS1MvL0OHjs+TwqMg7QHYoYIti6fC
5V+AkllgtezodqoiaLOOvCdfw+4JQCj09pCea2TNj1iBoyA.nzQkZyycf632
XVHvfcDuxWii8uRVVM3Bba6NOYJF4T4RoV4pSMI+IWh+ut6u5RaU81gOpclA
8w7RnqtIeFTN4cncwmh1zaGsOjZkBCZeCyvzCrZNpkIjn8B4f0f5DRNSg16x
sWroZxe+E08VIDjhOnjUTBUosEvDPFbTtrZV9EqYj0ulILbE95bNeWf5Kbxf
9on6MbxvfpPcWerfbGzb2Tdc9VwjsuaalbyZyPzgOU+m8+.I75OuXn6sp5IL
N1BP+kFMbsQHYFQu7M1jelMOHZZ3v0YSdIzrpNNvurK1TlKZxmAZJVMzraFn
grZnoXFnw8qFDYUPC4KUmhbFuuLZnKDMgQL1vvibkdLj.PbaVNzq7haS.QgL
HBQDq3OJlrOGzvTt8JF2REqJLeepL7SR7w9FtRZEiq0bY903ey1g6T.
-----------end_max5_patcher-----------