MCPcopy Create free account
hub / github.com/ImageEngine/cortex / endOcclusionQuery

Method endOcclusionQuery

src/IECoreGL/Selector.cpp:496–515  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

494 }
495
496 void endOcclusionQuery()
497 {
498 if( m_queries.size() )
499 {
500 glEndQueryARB( GL_SAMPLES_PASSED_ARB );
501 }
502
503 for( size_t i = 0, e = m_queries.size(); i < e; i++ )
504 {
505 GLuint samplesPassed = 0;
506 glGetQueryObjectuivARB( m_queries[i], GL_QUERY_RESULT_ARB, &samplesPassed );
507 if( samplesPassed )
508 {
509 m_hits.push_back( HitRecord( 0, 0, m_queryNames[i] ) );
510 }
511 }
512
513 glDeleteQueriesARB( m_queries.size(), &(m_queries[0]) );
514 m_baseState->add( const_cast<DepthTestStateComponent *>( State::defaultState()->get<DepthTestStateComponent>() ), false /* no override */ );
515 }
516
517};
518

Callers

nothing calls this directly

Calls 3

defaultStateFunction · 0.85
sizeMethod · 0.45
addMethod · 0.45

Tested by

no test coverage detected