1
0
mirror of https://github.com/troisjs/trois.git synced 2024-11-24 12:22:03 +08:00
trois/src/geometries/TubeGeometry.js
Kevin Levron 2b441f7cd7 wip
2021-03-06 23:14:22 +01:00

19 lines
517 B
JavaScript

import { Curve, TubeGeometry } from 'three';
import Geometry from './Geometry.js';
export default {
extends: Geometry,
props: {
path: Curve,
tubularSegments: { type: Number, default: 64 },
radius: { type: Number, default: 1 },
radiusSegments: { type: Number, default: 8 },
closed: { type: Boolean, default: false },
},
methods: {
createGeometry() {
this.geometry = new TubeGeometry(this.path, this.tubularSegments, this.radius, this.radiusSegments, this.closed);
},
},
};