MCPcopy Create free account
hub / github.com/VCVRack/Rack / dataToJson

Method dataToJson

src/core/CV_MIDICC.cpp:108–119  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

106 }
107
108 json_t* dataToJson() override {
109 json_t* rootJ = json_object();
110
111 json_t* ccsJ = json_array();
112 for (int id = 0; id < 16; id++) {
113 json_array_append_new(ccsJ, json_integer(learnedCcs[id]));
114 }
115 json_object_set_new(rootJ, "ccs", ccsJ);
116
117 json_object_set_new(rootJ, "midi", midiOutput.toJson());
118 return rootJ;
119 }
120
121 void dataFromJson(json_t* rootJ) override {
122 json_t* ccsJ = json_object_get(rootJ, "ccs");

Callers

nothing calls this directly

Calls 1

toJsonMethod · 0.45

Tested by

no test coverage detected