Hi MaxDevelopers !
The SDK documentation in the chapter "dictionaries" mention a function
jsonreader_parse() which, I guess is able to parse JSON files. For one of my externals, I would like to parse a JSON file but not fetch it in a dictionary structure (I have a custom data structure). So I would very much like to use such a function instead of writing my own parser…
But I can’t find any documentation about this
jsonreader_parse() (neither can I even find the prototype of it).
Is it yet possible to use this function ? How do I use it ?
In Max we do everything with dictionaries, and jsonreader_parse() is an internal implementation that is setup to work with dictionaries. If you would like to work with custom data structure serialization then you will need to write or find a parser such as those at http://json.org .
You may find it easier to just load into a dictionary and iterate across its values to convert it to your structure.
Thank’s for your replies and info !
I’ll see what I do. I’m not decided yet…
(I’ve already written a parser of my own using Bison (to read DOT files) so it may be as easy to use Bison to generate a JSON parser as to load in a dictionary and then iterate across. Maybe not).
I’ll keep you posted anyway.
C74 RSS Feed | © Copyright Cycling '74