MCPcopy Create free account
hub / github.com/MrKepzie/Natron / getCurrentTime

Method getCurrentTime

Engine/EffectInstance.cpp:5125–5146  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

5123}
5124
5125double
5126EffectInstance::getCurrentTime() const
5127{
5128 EffectDataTLSPtr tls = _imp->tlsData->getTLSData();
5129 AppInstPtr app = getApp();
5130 if (!app) {
5131 return 0.;
5132 }
5133 if (!tls) {
5134 return app->getTimeLine()->currentFrame();
5135 }
5136 if (tls->currentRenderArgs.validArgs) {
5137 return tls->currentRenderArgs.time;
5138 }
5139
5140
5141 if ( !tls->frameArgs.empty() ) {
5142 return tls->frameArgs.back()->time;
5143 }
5144
5145 return app->getTimeLine()->currentFrame();
5146}
5147
5148ViewIdx
5149EffectInstance::getCurrentView() const

Callers

nothing calls this directly

Calls 5

getAppFunction · 0.85
emptyMethod · 0.80
getTLSDataMethod · 0.45
currentFrameMethod · 0.45
getTimeLineMethod · 0.45

Tested by

no test coverage detected