181{
182 if (!op) {
184 "Cannot set null operator");
185 return;
186 }
187
189 const char* new_name = op->get_type_name().data();
190
192 "Switching operator: '{}' → '{}'",
193 old_name, new_name);
194
195 std::vector<PointVertex> vertices;
196
197 if (
auto* old_graphics =
dynamic_cast<PhysicsOperator*
>(
m_operator.get())) {
198 vertices = old_graphics->extract_vertices();
199
201 "Extracted {} vertices from old operator",
202 vertices.size());
205 }
206
207 if (auto* new_graphics = dynamic_cast<PhysicsOperator*>(op.get())) {
208 new_graphics->initialize(vertices);
209
210 if (auto* physics = dynamic_cast<PhysicsOperator*>(op.get())) {
212 }
213
215 "Initialized new graphics operator with {} points",
216 vertices.size());
217 }
218
220
221 if (
auto* physics =
dynamic_cast<PhysicsOperator*
>(
m_operator.get())) {
223 physics->enable_spatial_interactions(should_interact);
224 }
225
227 "Operator switched successfully to '{}'", new_name);
228}
#define MF_INFO(comp, ctx,...)
#define MF_ERROR(comp, ctx,...)
#define MF_DEBUG(comp, ctx,...)
Topology get_topology() const
Get the current topology.
Kinesis::SamplerBounds m_bounds
std::vector< PointVertex > generate_initial_vertices()
std::unique_ptr< NetworkOperator > m_operator
@ NodeProcessing
Node graph processing (Nodes::NodeGraphManager)
@ Nodes
DSP Generator and Filter Nodes, graph pipeline, node management.
@ SPATIAL
Dynamic proximity-based (nodes within radius interact)