LineLoop.js 730 B

12345678910111213141516171819202122232425262728293031323334353637
  1. import { Line } from './Line.js';
  2. /**
  3. * A continuous line. This is nearly the same as {@link Line} the only difference
  4. * is that the last vertex is connected with the first vertex in order to close
  5. * the line to form a loop.
  6. *
  7. * @augments Line
  8. */
  9. class LineLoop extends Line {
  10. /**
  11. * Constructs a new line loop.
  12. *
  13. * @param {BufferGeometry} [geometry] - The line geometry.
  14. * @param {Material|Array<Material>} [material] - The line material.
  15. */
  16. constructor( geometry, material ) {
  17. super( geometry, material );
  18. /**
  19. * This flag can be used for type testing.
  20. *
  21. * @type {boolean}
  22. * @readonly
  23. * @default true
  24. */
  25. this.isLineLoop = true;
  26. this.type = 'LineLoop';
  27. }
  28. }
  29. export { LineLoop };
粤ICP备19079148号