void TextureUploadProcessor::runLoop_() { _needRedraw = false; if( GLContext::getCurrent() != getGLContext().get( )) getGLContext()->makeCurrent(); processorInputPtr_->applyAll( CONNECTION_ID ); _checkThreadOperation(); #ifdef _ITT_DEBUG_ __itt_task_begin ( ittTextureLoadDomain, __itt_null, __itt_null, ittTextureComputationTask ); #endif //_ITT_DEBUG_ const DashRenderStatus& renderStatus = _dashTree->getRenderStatus(); if( renderStatus.getFrameID() != _currentFrameID ) { _protectUnloading.clear(); CollectVisiblesVisitor collectVisibles( _dashTree, _protectUnloading ); DFSTraversal traverser; const RootNode& rootNode = _dashTree->getDataSource()->getVolumeInformation().rootNode; traverser.traverse( rootNode, collectVisibles, renderStatus.getFrameID( )); _textureCache.setProtectList( _protectUnloading ); _currentFrameID = renderStatus.getFrameID(); } _loadData(); processorOutputPtr_->commit( CONNECTION_ID ); #ifdef _ITT_DEBUG_ __itt_task_end( ittTextureLoadDomain ); #endif //_ITT_DEBUG_ }
void __cyg_profile_func_exit (void *, void *) { if (clock_domain && !g_bCAIRecursion) { g_bCAIRecursion = true; __itt_task_end(g_domain); g_bCAIRecursion = false; } }
mfxTraceU32 MFXTraceITT_EndTask(mfxTraceStaticHandle * //static_handle ,mfxTraceTaskHandle *handle ) { if (!handle) return 1; if (1 == handle->itt1.uint32) __itt_task_end(GetDomain()); return 0; }
void RunExample() { __itt_task_begin(pD, __itt_null, __itt_null, __itt_string_handle_create(L"End of run")); for(int i = 0; i < 50; ++i) { Example(i); } __itt_task_end(pD); }
void Example(int index) { __itt_task_begin(pD, __itt_null, __itt_null, pSH1); __itt_metadata_add(pD, __itt_null, pSH2, __itt_metadata_s32, 1, (void*)&index); __itt_metadata_str_add(pD, __itt_null, pSH1, L"Example is running", 0); if(index == 10) { Sleep(30); } else { Sleep(5); /* do nothing */ } __itt_task_end(pD); }
// Destructor // When the class goes out of scope, this marker will automatically be called // and the domain 'closed' //----------------------------------------------------------------------------- CPUTITTTaskMarker::~CPUTITTTaskMarker() { __itt_task_end(mpITTDomain); }
void TextureLoaderVisitor::visit( DashRenderNode& renderNode, VisitState& state ) { const LODNode& lodNode = renderNode.getLODNode(); if( !lodNode.isValid( )) return; if( !renderNode.isInFrustum( )) { state.setVisitChild( false ); return; } if( !renderNode.isLODVisible( )) return; state.setVisitChild( false ); const ConstCacheObjectPtr texPtr = renderNode.getTextureObject(); if( texPtr->isLoaded( )) return; TextureObject& texture = _cache.getNodeTexture( lodNode.getNodeId().getId( )); if( texture.isLoaded() ) { renderNode.setTextureObject( &texture ); _output->commit( CONNECTION_ID ); return; } else { const ConstCacheObjectPtr textureData = renderNode.getTextureDataObject(); if( textureData->isLoaded( )) { #ifdef _ITT_DEBUG_ __itt_task_begin ( ittTextureLoadDomain, __itt_null, __itt_null, ittTextureLoadTask ); #endif //_ITT_DEBUG_ TextureObject& lodTexture = _cache.getNodeTexture( lodNode.getNodeId().getId( )); lodTexture.setTextureDataObject( static_cast< const TextureDataObject * >( textureData.get() ) ); lodTexture.cacheLoad(); #ifdef _ITT_DEBUG_ __itt_task_end( ittTextureLoadDomain ); #endif //_ITT_DEBUG_ renderNode.setTextureObject( &lodTexture ); renderNode.setTextureDataObject( TextureDataObject::getEmptyPtr() ); _output->commit( CONNECTION_ID ); _needRedraw = true; } else { _allLoaded = false; LBVERB << "Texture data not loaded:" << lodNode.getNodeId() << std::endl; } } if( !isSynchronous( )) // only in asynchronous mode state.setBreakTraversal( _input->dataWaitingOnInput( CONNECTION_ID )); }
void stop(Module *M) { __itt_task_end(M); }