Sfoglia il codice sorgente

Add function to check if base multires tiles are loaded.

pull/1067/head
Matthew Petroff 2 anni fa
parent
commit
621de7f6dd
1 ha cambiato i file con 19 aggiunte e 1 eliminazioni
  1. +19
    -1
      src/js/libpannellum.js

+ 19
- 1
src/js/libpannellum.js Vedi File

@@ -984,7 +984,25 @@ function Renderer(container, context) {
}
return false;
};

/**
* Check if base image tiles are loaded.
* @memberof Renderer
* @instance
* @returns {boolean} Whether or not base image tiles are loaded.
*/
this.isBaseLoaded = function() {
if (program.currentNodes.length >= 6) {
for (var i = 0; i < 6; i++) {
if (!program.currentNodes[i].textureLoaded) {
return false;
}
}
return true;
}
return false;
}

/**
* Retrieve renderer's canvas.
* @memberof Renderer


Caricamento…
Annulla
Salva