Changeset View
Changeset View
Standalone View
Standalone View
source/blender/nodes/NOD_geometry_exec.hh
| Show First 20 Lines • Show All 123 Lines • ▼ Show 20 Lines | template<typename T> Vector<T> extract_multi_input(StringRef identifier) | ||||
| while (true) { | while (true) { | ||||
| std::string sub_identifier = identifier; | std::string sub_identifier = identifier; | ||||
| if (index > 0) { | if (index > 0) { | ||||
| sub_identifier += "[" + std::to_string(index) + "]"; | sub_identifier += "[" + std::to_string(index) + "]"; | ||||
| } | } | ||||
| if (!input_values_.contains(sub_identifier)) { | if (!input_values_.contains(sub_identifier)) { | ||||
| break; | break; | ||||
| } | } | ||||
| values.append(input_values_.extract<T>(sub_identifier)); | values.append(input_values_.extract<T, StringRef>(sub_identifier)); | ||||
| index++; | index++; | ||||
JacquesLucke: Moving from a const value doesn't really make sense usually.
Why is this change necessary? | |||||
Done Inline ActionsAgh, turns out the first part wasn't necessary, it's just adding the second template parameter that does it. values.append(input_values_.extract<T, StringRef>(sub_identifier)); HooglyBoogly: Agh, turns out the first part wasn't necessary, it's just adding the second template parameter… | |||||
| } | } | ||||
| return values; | return values; | ||||
| } | } | ||||
| /** | /** | ||||
| * Get the input value for the input socket with the given identifier. | * Get the input value for the input socket with the given identifier. | ||||
| */ | */ | ||||
| template<typename T> const T &get_input(StringRef identifier) const | template<typename T> const T &get_input(StringRef identifier) const | ||||
| ▲ Show 20 Lines • Show All 116 Lines • Show Last 20 Lines | |||||
Moving from a const value doesn't really make sense usually.
Why is this change necessary?