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

Method OnInstanceVisible

trinity/Interior/Tr2InteriorScene.cpp:1041–1060  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1039}
1040
1041void Tr2InteriorScene::OnInstanceVisible( ITr2InteriorCullable* cullable, const Matrix& objectToWorld )
1042{
1043 Tr2VisibilityEvent event;
1044 event.m_eventType = Tr2VisibilityEvent::INSTANCE_VISIBLE;
1045 event.m_userData = cullable;
1046 event.m_objectToWorldMatrix = objectToWorld;
1047
1048 if( m_visibilityQueryType == PRIMARY_QUERY )
1049 {
1050 m_visibilityResults->AddVisibilityEvent( event );
1051 }
1052 else if( m_visibilityQueryType == PICKING_QUERY )
1053 {
1054 ITr2Renderable* renderable = dynamic_cast<ITr2Renderable*>( cullable );
1055 if( renderable )
1056 {
1057 m_visibleObjects.push_back( renderable );
1058 }
1059 }
1060}
1061
1062// --------------------------------------------------------------------------------------
1063// Description

Callers

nothing calls this directly

Calls 1

AddVisibilityEventMethod · 0.80

Tested by

no test coverage detected