void InteriorExplorerState::Exit(int nextState) { Eegeo::Space::LatLongAltitude latLong = Eegeo::Space::LatLongAltitude::FromECEF(m_interiorsCameraController.GetCameraState().InterestPointEcef()); const float interestDistance = 500.0f; m_worldCameraController.SetView(latLong.GetLatitudeInDegrees(), latLong.GetLongitudeInDegrees(), m_interiorsCameraController.GetHeadingDegrees(), interestDistance); m_worldCameraController.GetGlobeCameraController().ApplyTilt(0.0f); if(m_pSubStateMachine->GetCurrentStateIndex() >= 0) { m_pSubStateMachine->StopStateMachine(); } m_tourService.UnregisterTourStartedCallback(m_tourStartedCallback); m_interiorExplorerUserInteractionModel.SetEnabled(true); }
void RouteSimulationExampleObserver::OnLinkReached(const Eegeo::Routes::Simulation::RouteSimulationSession& session) const { // At each new link, we change the model being drawn int vehicleIndex = rand() % (int)(m_vehicleModels.size()); Eegeo::Rendering::SceneModels::SceneModel* vehicleModel = m_vehicleModels.at(vehicleIndex); m_pModelBinding->SetModel(vehicleModel); const dv3& ecef = session.GetCurrentPositionEcef(); Eegeo::Space::LatLongAltitude latLongAltitude = Eegeo::Space::LatLongAltitude::FromECEF(ecef); Eegeo_TTY("New link reached at %f, %f\n", latLongAltitude.GetLatitudeInDegrees(), latLongAltitude.GetLongitudeInDegrees()); }