Skip to content

Commit bd38955

Browse files
committed
Fix logic
1 parent 9d2fe69 commit bd38955

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

packages/engine/Source/DataSources/DataSourceDisplay.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,7 @@ function DataSourceDisplay(options) {
115115
this._removeDataSourceCollectionListener = removeDataSourceCollectionListener;
116116

117117
this._ready = false;
118+
this._prevResult = this._ready;
118119
}
119120

120121
const ExtraVisualizers = [];
@@ -322,9 +323,12 @@ DataSourceDisplay.prototype.update = function (time) {
322323
result = visualizers[x].update(time) && result;
323324
}
324325

325-
if (!result) {
326+
// Request a rendering of the scene when all of the data sources
327+
// switch from false to true
328+
if (!this._prevResult && result) {
326329
this._scene.requestRender();
327330
}
331+
this._prevResult = result;
328332

329333
// once the DataSourceDisplay is ready it should stay ready to prevent
330334
// entities from breaking updates when they become "un-ready"

0 commit comments

Comments
 (0)