Mercurial > hg > piper-cpp
comparison utilities/json-to-capnp.cpp @ 51:f4244a2d55ac
Introduce and use output id mappers
author | Chris Cannam <c.cannam@qmul.ac.uk> |
---|---|
date | Fri, 16 Sep 2016 15:10:57 +0100 |
parents | a98ef4c2616b |
children | 38780f15ac8d |
comparison
equal
deleted
inserted
replaced
50:12e3b396544c | 51:f4244a2d55ac |
---|---|
63 VampnProto::buildFeature | 63 VampnProto::buildFeature |
64 (f, VampJson::toFeature(payload, serialisation)); | 64 (f, VampJson::toFeature(payload, serialisation)); |
65 | 65 |
66 } else if (type == "featureset") { | 66 } else if (type == "featureset") { |
67 auto fs = message.initRoot<FeatureSet>(); | 67 auto fs = message.initRoot<FeatureSet>(); |
68 PreservingPluginOutputIdMapper omapper; | |
68 VampnProto::buildFeatureSet | 69 VampnProto::buildFeatureSet |
69 (fs, VampJson::toFeatureSet(payload, serialisation)); | 70 (fs, VampJson::toFeatureSet(payload, omapper, serialisation), omapper); |
70 | 71 |
71 } else if (type == "loadrequest") { | 72 } else if (type == "loadrequest") { |
72 auto req = message.initRoot<LoadRequest>(); | 73 auto req = message.initRoot<LoadRequest>(); |
73 VampnProto::buildLoadRequest | 74 VampnProto::buildLoadRequest |
74 (req, VampJson::toLoadRequest(payload)); | 75 (req, VampJson::toLoadRequest(payload)); |