MCPcopy Create free account
hub / github.com/OpenShot/libopenshot / stabilizerJson

Function stabilizerJson

examples/Example_opencv.cpp:239–256  ·  view source on GitHub ↗

Return JSON string for the stabilizer effect

Source from the content-addressed store, hash-verified

237
238// Return JSON string for the stabilizer effect
239string stabilizerJson(bool onlyProtoPath){
240
241 // Define path to save stabilized data
242 string protobufDataPath = "example_stabilizer.data";
243 // Set smoothing window value
244 string smoothingWindow = "30";
245
246 // Construct all the composition of the JSON string
247 string protobuf_data_path = jsonFormat("protobuf_data_path", protobufDataPath);
248 string smoothing_window = jsonFormat("smoothing_window", smoothingWindow, "int");
249
250 // Return only the the protobuf path in JSON format
251 if(onlyProtoPath)
252 return "{" + protobuf_data_path + "}";
253 // Return all the parameters for the pre-processing effect
254 else
255 return "{" + protobuf_data_path + "," + smoothing_window + "}";
256}
257
258string objectDetectionJson(bool onlyProtoPath){
259

Callers 1

mainFunction · 0.85

Calls 1

jsonFormatFunction · 0.85

Tested by

no test coverage detected