CircleGeometry.js 545 B

12345678910111213141516171819202122232425
  1. import { Geometry } from '../core/Geometry.js';
  2. import { CircleBufferGeometry } from './CircleBufferGeometry.js';
  3. class CircleGeometry extends Geometry {
  4. constructor( radius, segments, thetaStart, thetaLength ) {
  5. super();
  6. this.type = 'CircleGeometry';
  7. this.parameters = {
  8. radius: radius,
  9. segments: segments,
  10. thetaStart: thetaStart,
  11. thetaLength: thetaLength
  12. };
  13. this.fromBufferGeometry( new CircleBufferGeometry( radius, segments, thetaStart, thetaLength ) );
  14. this.mergeVertices();
  15. }
  16. }
  17. export { CircleGeometry };