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

Method onKeyframeSetOnTrackCenter

Gui/TrackerPanel.cpp:1527–1559  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1525}
1526
1527void
1528TrackerPanel::onKeyframeSetOnTrackCenter(const TrackMarkerPtr &marker,
1529 int key)
1530{
1531 if (!marker) {
1532 return;
1533 }
1534 TrackKeysMap::iterator found = _imp->keys.find(marker);
1535
1536 if ( found == _imp->keys.end() ) {
1537 TrackKeys k;
1538 k.centerKeys.insert(key);
1539 _imp->keys[marker] = k;
1540 } else {
1541 std::pair<std::set<double>::iterator, bool> ret = found->second.centerKeys.insert(key);
1542 if (ret.second && found->second.visible) {
1543 NodeGuiPtr node = _imp->node.lock();
1544 if (!node) {
1545 return;
1546 }
1547 NodePtr internalNode = node->getNode();
1548 if (!internalNode) {
1549 return;
1550 }
1551 AppInstancePtr app = internalNode->getApp();
1552 if (!app) {
1553 return;
1554 }
1555 _imp->updateTrackKeysInfoBar( app->getTimeLine()->currentFrame() );
1556 app->addKeyframeIndicator(key);
1557 }
1558 }
1559}
1560
1561void
1562TrackerPanel::onKeyframeRemovedOnTrackCenter(const TrackMarkerPtr& marker,

Callers

nothing calls this directly

Calls 10

addKeyframeIndicatorMethod · 0.80
findMethod · 0.45
endMethod · 0.45
insertMethod · 0.45
lockMethod · 0.45
getNodeMethod · 0.45
getAppMethod · 0.45
currentFrameMethod · 0.45
getTimeLineMethod · 0.45

Tested by

no test coverage detected