Skip to content

Commit febbb79

Browse files
committed
Update for multiple view changes
1 parent 00ecea0 commit febbb79

File tree

3 files changed

+11
-8
lines changed

3 files changed

+11
-8
lines changed

native~/Runtime/src/Cesium3DTilesetImpl.cpp

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,9 +133,12 @@ void Cesium3DTilesetImpl::Update(
133133
std::vector<ViewState> viewStates =
134134
CameraManager::getAllCameras(tileset, *this);
135135

136-
const ViewUpdateResult& updateResult = this->_pTileset->updateView(
136+
const ViewUpdateResult& updateResult = this->_pTileset->updateViewGroup(
137+
this->_pTileset->getDefaultViewGroup(),
137138
viewStates,
138139
DotNet::UnityEngine::Time::deltaTime());
140+
this->_pTileset->loadTiles();
141+
139142
this->updateLastViewUpdateResultState(tileset, updateResult);
140143

141144
for (auto pTile : updateResult.tilesFadingOut) {

native~/Runtime/src/CesiumCreditSystemImpl.cpp

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -51,12 +51,14 @@ void CesiumCreditSystemImpl::UpdateCredits(
5151
this->_creditsUpdated = false;
5252
}
5353

54+
const CesiumUtility::CreditsSnapshot& credits = _pCreditSystem->getSnapshot();
5455
const std::vector<CesiumUtility::Credit>& creditsToShowThisFrame =
55-
this->_pCreditSystem->getCreditsToShowThisFrame();
56+
credits.currentCredits;
57+
5658
size_t creditsCount = creditsToShowThisFrame.size();
57-
this->_creditsUpdated =
58-
forceUpdate || creditsCount != this->_lastCreditsCount ||
59-
this->_pCreditSystem->getCreditsToNoLongerShowThisFrame().size() > 0;
59+
this->_creditsUpdated = forceUpdate ||
60+
creditsToShowThisFrame.size() != _lastCreditsCount ||
61+
credits.removedCredits.size() > 0;
6062

6163
if (this->_creditsUpdated) {
6264
List1<CesiumForUnity::CesiumCredit> popupCredits =
@@ -95,8 +97,6 @@ void CesiumCreditSystemImpl::UpdateCredits(
9597
this->_creditsUpdated = true;
9698
this->_lastCreditsCount = creditsCount;
9799
}
98-
99-
this->_pCreditSystem->startNextFrame();
100100
}
101101

102102
namespace {

native~/extern/cesium-native

Submodule cesium-native updated 108 files

0 commit comments

Comments
 (0)