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

Method JsonValue

src/EffectBase.cpp:96–119  ·  view source on GitHub ↗

Generate Json::Value for this object

Source from the content-addressed store, hash-verified

94
95// Generate Json::Value for this object
96Json::Value EffectBase::JsonValue() const {
97
98 // Create root json object
99 Json::Value root = ClipBase::JsonValue(); // get parent properties
100 root["name"] = info.name;
101 root["class_name"] = info.class_name;
102 root["description"] = info.description;
103 root["parent_effect_id"] = info.parent_effect_id;
104 root["has_video"] = info.has_video;
105 root["has_audio"] = info.has_audio;
106 root["has_tracked_object"] = info.has_tracked_object;
107 root["apply_before_clip"] = info.apply_before_clip;
108 root["order"] = Order();
109 root["mask_invert"] = mask_invert;
110 root["mask_time_mode"] = mask_time_mode;
111 root["mask_loop_mode"] = mask_loop_mode;
112 if (mask_reader)
113 root["mask_reader"] = mask_reader->JsonValue();
114 else
115 root["mask_reader"] = Json::objectValue;
116
117 // return JsonValue
118 return root;
119}
120
121// Load JSON string into this object
122void EffectBase::SetJson(const std::string value) {

Callers 2

SetJsonValueMethod · 0.45
SetParentEffectMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected