MCPcopy Create free account
hub / github.com/WarmUpTill/SceneSwitcher / Load

Method Load

lib/macro/macro-input.cpp:29–47  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

27}
28
29void MacroInputVariables::Load(obs_data_t *obj)
30{
31 OBSDataArrayAutoRelease array =
32 obs_data_get_array(obj, "inputVariables");
33 const size_t count = obs_data_array_count(array);
34 for (size_t i = 0; i < count; i++) {
35 OBSDataAutoRelease arrayObj = obs_data_array_item(array, i);
36 const bool isInvalid =
37 obs_data_get_bool(arrayObj, "invalidVariable");
38 if (isInvalid) {
39 _inputVariables.emplace_back();
40 } else {
41 const auto name =
42 obs_data_get_string(arrayObj, "variableName");
43 _inputVariables.emplace_back(
44 GetWeakVariableByName(name));
45 }
46 }
47}
48
49void MacroInputVariables::SetValues(const StringList &values)
50{

Callers

nothing calls this directly

Calls 1

GetWeakVariableByNameFunction · 0.85

Tested by

no test coverage detected