MCPcopy Create free account
hub / github.com/carbonengine/trinity / RebuildCachedData

Method RebuildCachedData

trinity/Tr2GrannyAnimation.cpp:511–831  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

509}
510
511void Tr2GrannyAnimation::RebuildCachedData( BlueAsyncRes* p )
512{
513 if( p == m_geometryRes && IsInitialized() )
514 {
515 return;
516 }
517
518 if( p != m_grannyRes && p != m_geometryRes )
519 {
520 for( auto it = m_secondaryGrannyRes.begin(); it != m_secondaryGrannyRes.end(); it++ )
521 {
522 if( p == it->second )
523 {
524 if( it->second )
525 {
526 if( it->second->IsUsingCMF() )
527 {
528 if( !it->second->GetCMFData() )
529 {
530 CCP_LOGERR( "'%s' not found or not a valid CMF file", it->first.c_str() );
531 }
532 }
533#if WITH_GRANNY
534 else
535 {
536 if( !it->second->GetGrannyFile() )
537 {
538 CCP_LOGERR( "'%s' not found or not a valid Granny file", it->first.c_str() );
539 }
540 }
541#endif
542 }
543 return;
544 }
545 }
546 }
547
548 if( !m_grannyRes && !m_geometryRes )
549 {
550 return;
551 }
552
553 if( m_grannyRes )
554 {
555 if( m_grannyRes->IsUsingCMF() )
556 {
557 if( !m_grannyRes->GetCMFData() )
558 {
559 CCP_LOGERR( "'%s' not found or not a valid CMF file", m_resPath.c_str() );
560 return;
561 }
562 }
563#if WITH_GRANNY
564 else
565 {
566 if( !m_grannyRes->GetGrannyFile() )
567 {
568 CCP_LOGERR( "'%s' not found or not a valid Granny file", m_resPath.c_str() );

Callers

nothing calls this directly

Calls 12

IsUsingCMFFunction · 0.85
CreateMappingFunction · 0.85
sizeMethod · 0.80
emptyMethod · 0.80
ConsumeAnimationQueueMethod · 0.80
ifFunction · 0.50
beginMethod · 0.45
endMethod · 0.45
IsUsingCMFMethod · 0.45
GetCMFDataMethod · 0.45
CleanupMethod · 0.45

Tested by

no test coverage detected