MCPcopy Create free account
hub / github.com/LabSound/LabSound / debugTraverse

Method debugTraverse

src/core/AudioContext.cpp:717–865  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

715}
716
717void AudioContext::debugTraverse(AudioNode * root)
718{
719 ASSERT(root);
720 // bail if shutting down.
721 auto ac = audioContextInterface().lock();
722 if (!ac)
723 return;
724
725 auto ctx = this;
726
727 ContextRenderLock renderLock(this, "lab::pull_graph");
728 if (!renderLock.context())
729 return; // return if couldn't acquire lock
730
731 if (!ctx->isInitialized())
732 {
733 return;
734 }
735
736 synchronizeConnections();
737
738 // Let the context take care of any business at the start of each render quantum.
739 ctx->handlePreRenderTasks(renderLock);
740
741 /* pass two, implement hardware input
742 // Prepare the local audio input provider for this render quantum.
743 if (optional_hardware_input && src)
744 {
745 optional_hardware_input->set(src);
746 }
747 */
748
749 // process the graph by pulling the inputs, which will recurse the
750 // entire processing graph.
751
752 enum WorkType
753 {
754 processNode,
755 silenceOutputs,
756 unsilenceOutputs,
757 setOutputChannels,
758 sumInputs,
759 setZeroes,
760 manageEnvelope,
761 };
762
763 struct Work
764 {
765 AudioNode * node = nullptr;
766 WorkType type;
767 };
768
769 std::vector<Work> work;
770
771 std::vector<AudioNode *> node_stack;
772 static int color = 1;
773 root->color = color;
774 ++color;

Callers 1

playMethod · 0.80

Calls 15

schedulingStateNameFunction · 0.85
handlePreRenderTasksMethod · 0.80
sizeMethod · 0.80
renderingOutputMethod · 0.80
sourceNodeMethod · 0.80
numberOfInputsMethod · 0.80
inputMethod · 0.80
numberOfConnectionsMethod · 0.80
connectionMethod · 0.80
finishedMethod · 0.80
inputsAreSilentMethod · 0.80

Tested by

no test coverage detected