Home Reference Source

src/octree/world/IntermediateWorldOctant.js

  1. import { WorldOctant } from "./WorldOctant";
  2.  
  3. /**
  4. * A world octant that doesn't reside in LOD zero.
  5. *
  6. * This octant is a container for resampled volume data. Additionally, it stores
  7. * information about the existence of its potential children.
  8. */
  9.  
  10. export class IntermediateWorldOctant extends WorldOctant {
  11.  
  12. /**
  13. * Constructs a new intermediate world octant.
  14. */
  15.  
  16. constructor() {
  17.  
  18. super();
  19.  
  20. /**
  21. * An 8-bit mask that indicates the existence of the eight potential
  22. * children.
  23. *
  24. * The order of the children follows the common octant layout from the
  25. * external `sparse-octree` module:
  26. *
  27. * ```text
  28. * 3____7
  29. * 2/___6/|
  30. * | 1__|_5
  31. * 0/___4/
  32. * ```
  33. *
  34. * @type {Number}
  35. */
  36.  
  37. this.children = 0;
  38.  
  39. }
  40.  
  41. }