@hackage hosc-json0.16

Haskell Open Sound Control JSON Serialisation

hosc-json

hosc <-> json

HOSC                        JSON
--------------------------- -----------------------------------
Int32 0                     0
Float 0.0                   0.0
Double 0.1                  0.1
ASCII_String (pack "s")     "s"
Blob (pack [0,1])           {"blob":[0,1]}
TimeStamp 0.0               {"timestamp":0.0}
Midi (MIDI 0 1 2 3)         {"midi":[0,1,2,3]}
Message "/m" [Int32 0]      ["/m",0]
Bundle 0 [Message "/m" []]  ["#bundle",{"timestamp":0.0},["/m"]]

cli

json-cat, json-cgi, json-console, json-nrt, json-ws, print

© rd, 2013-2017, gpl