How to use the SplineCurve3 function from three

Find comprehensive JavaScript three.SplineCurve3 code examples handpicked from public code repositorys.

95
96
97
98
99
100
101
102
103
104
 *
 * @method getCurves
 * @return {Object}
 */
FlowField.prototype.getCurves = function (points) {
  var main = new THREE.SplineCurve3(points);

  var subsPoints = main.getPoints(this.parameters.subsPrecision);

  var subs = [];
fork icon57
star icon254
watch icon10

+ 15 other calls in file

74
75
76
77
78
79
80
81
82
83
    while(i<noise.length){
        spline.push(new THREE.Vector3( -this.size.x/2 + (ratio * i), noise[i], 0 ) )
        i++;
    };

    var curve = new THREE.SplineCurve3(spline);
    return curve.getPoints(511);

    return spline
};
fork icon40
star icon163
watch icon0

+ 7 other calls in file

60
61
62
63
64
65
66
67
68

//add paths to 3d object
var createTube = function(data){

        //create tubes
        var path3D = new THREE.SplineCurve3(data);
        var segments = data.length < options.maxSegments ? data.length : options.maxSegments;
        segments = Math.ceil(options.quality * segments);
        var tube = new THREE.TubeGeometry(path3D, segments, options.width, options.radiusSegments, false);
fork icon2
star icon11
watch icon4

+ 5 other calls in file

Other functions in three

Sorted by popularity

function icon

three.Vector3 is the most popular function in three (22341 examples)