Load Json::Value into this object
| 134 | |
| 135 | // Load Json::Value into this object |
| 136 | void Wave::SetJsonValue(const Json::Value root) { |
| 137 | |
| 138 | // Set parent data |
| 139 | EffectBase::SetJsonValue(root); |
| 140 | |
| 141 | // Set data from Json (if key is found) |
| 142 | if (!root["wavelength"].isNull()) |
| 143 | wavelength.SetJsonValue(root["wavelength"]); |
| 144 | if (!root["amplitude"].isNull()) |
| 145 | amplitude.SetJsonValue(root["amplitude"]); |
| 146 | if (!root["multiplier"].isNull()) |
| 147 | multiplier.SetJsonValue(root["multiplier"]); |
| 148 | if (!root["shift_x"].isNull()) |
| 149 | shift_x.SetJsonValue(root["shift_x"]); |
| 150 | if (!root["speed_y"].isNull()) |
| 151 | speed_y.SetJsonValue(root["speed_y"]); |
| 152 | } |
| 153 | |
| 154 | // Get all properties for a specific frame |
| 155 | std::string Wave::PropertiesJSON(int64_t requested_frame) const { |
nothing calls this directly
no outgoing calls
no test coverage detected