MayaFlux 0.5.0
Digital-First Multimedia Processing Framework
Loading...
Searching...
No Matches

◆ set_parameter()

void MayaFlux::Nodes::Network::TopologyOperator::set_parameter ( std::string_view  param,
double  value 
)
overridevirtual

Set operator parameter.

Implements MayaFlux::Nodes::Network::NetworkOperator.

Definition at line 241 of file TopologyOperator.cpp.

242{
243 if (param == "connection_radius") {
244 for (auto& topology : m_topologies) {
245 topology->set_connection_radius(static_cast<float>(value));
246 }
247 } else if (param == "k_neighbors") {
248 for (auto& topology : m_topologies) {
249 topology->set_k_neighbors(static_cast<size_t>(value));
250 }
251 } else if (param == "line_thickness") {
252 m_default_thickness = static_cast<float>(value);
253 for (auto& topology : m_topologies) {
254 topology->set_line_thickness(m_default_thickness);
255 }
256 }
257}
float value
std::vector< std::shared_ptr< GpuSync::TopologyGeneratorNode > > m_topologies

References m_default_thickness, m_topologies, and value.