MCPcopy Create free account
hub / github.com/NatronGitHub/Natron / declareTrackerPythonField

Method declareTrackerPythonField

Engine/Node.cpp:677–699  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

675}
676
677void
678Node::declareTrackerPythonField()
679{
680 if (getScriptName_mt_safe().empty()) {
681 return;
682 }
683
684 assert(_imp->trackContext);
685 std::string appID = getApp()->getAppIDString();
686 std::string nodeName = getFullyQualifiedName();
687 std::string nodeFullName = appID + "." + nodeName;
688 std::string err;
689 std::string script = nodeFullName + ".tracker = " + nodeFullName + ".getTrackerContext()\n";
690 if ( !appPTR->isBackground() ) {
691 getApp()->printAutoDeclaredVariable(script);
692 }
693 bool ok = NATRON_PYTHON_NAMESPACE::interpretPythonScript(script, &err, 0);
694 assert(ok);
695 if (!ok) {
696 throw std::runtime_error("Node::declareTrackerPythonField(): interpretPythonScript(" + script + ") failed!");
697 }
698 _imp->trackContext->declarePythonFields();
699}
700
701NodeCollectionPtr
702Node::getGroup() const

Callers

nothing calls this directly

Calls 6

getAppFunction · 0.85
emptyMethod · 0.80
getAppIDStringMethod · 0.80
isBackgroundMethod · 0.45
declarePythonFieldsMethod · 0.45

Tested by

no test coverage detected