-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Provide meta data for inputs and outputs #5
Comments
Another possibility would be to store the port meta data as a JSON string in the value of a specific meta data key. But FAUST doesn't allow escaping double quotes or strings in single quotes, so we need to use single quotes in the JSON, which then would need to be replaced with double quotes again, before the JSON can be parsed. So overall not very elegant and harder to write too. For example:
There's a similar thing done in the FAUST examples: https://github.com/grame-cncm/faust/blob/master-dev/examples/smartKeyboard/dubDub.dsp#L37 |
Hello, I know you can attach metadata to particular functions, so perhaps this information is best there. This information is best not defined as a global, because users might want distinct information depending on which |
If adding this feature in short term, I think to go with a syntax similar to controls. |
This will end up in the FAUST XML/JSON output with keys like |
Regarding status of this issue
|
Can we revisit this feature now that we have a Python implementation? It should be much easier to parse meta data and extract proper keys from it with Python. |
Perhaps this is a topic worth discussing with faust devs? |
We tried to bring up the topic on the faust user mailing list back then, but there was no reaction from the devs: https://sourceforge.net/p/faudiostream/mailman/message/37087209/ We also brought the topic up in this related FAUST Github issue: grame-cncm/faust#435 (comment) But this also didn't go anywhere. |
It would be nice if there was some way to provide meta data for input and output ports, e.g. "name" and "symbol" or other tags / flags.
I'm not sure whether FAUST has a "proper" way of attaching meta data to inputs / outputs, but I guess we could just use the global meta data via
declare
to store it, e.g.:NB: It seems that meta keys must be valid identifiers, i.e. only [a-zA-Z0-9_] but the manual isn't very clear about that. So unfortunately it seems we can't use chars like
/
as key/sub-key separators.The architecture file could then provide the following methods:
similar to the existing
parameter_label
,parameter_symbol
, etc. methods.This would mean parsing the meta data keys into
(in_out, index, key)
triples. I'm not sure whether jinja2cpp already provides sufficient functionality for that?The text was updated successfully, but these errors were encountered: