All files / engine/Source/Scene ResourceLoaderState.js

100% Statements 1/1
100% Branches 0/0
100% Functions 0/0
100% Lines 1/1

Press n or j to go to the next uncovered block, b, p or k for the previous block.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57          1x                                                                                                      
/**
 * The {@link ResourceLoader} state.
 *
 * @private
 */
const ResourceLoaderState = {
  /**
   * The resource has not yet been loaded.
   *
   * @type {number}
   * @constant
   * @private
   */
  UNLOADED: 0,
  /**
   * The resource is loading. In this state, external resources are fetched as needed.
   *
   * @type {number}
   * @constant
   * @private
   */
  LOADING: 1,
  /**
   * The resource has finished loading, but requires further processing.
   *
   * @type {number}
   * @constant
   * @private
   */
  LOADED: 2,
  /**
   * The resource is processing. GPU resources are allocated in this state as needed.
   *
   * @type {number}
   * @constant
   * @private
   */
  PROCESSING: 3,
  /**
   * The resource has finished loading and processing; the results are ready to be used.
   *
   * @type {number}
   * @constant
   * @private
   */
  READY: 4,
  /**
   * The resource loading or processing has failed due to an error.
   *
   * @type {number}
   * @constant
   * @private
   */
  FAILED: 5,
};
export default Object.freeze(ResourceLoaderState);