How can I create a 3D cubic-bezier curved triangle from 3D points in Three.js?

后端 未结 3 1310
Happy的楠姐
Happy的楠姐 2021-01-07 01:28

Following this topic, I am trying to generate a 3D curved triangle as a NURBS surface, but I don\'t understand how to set up my 3D points to do that.

Here is the cur

3条回答
  •  清歌不尽
    2021-01-07 01:45

    In your code you use NURBSSurface function from NURBSSurface.js file, that function uses NURBSUtils.calcSurfacePoint function from NURBSUtils.js file. But the calcSurfacePoint calculate point for standard NUBRB surface where where parameter are from rectangle (u,v) wiki.

    You will not generate "3D cubic bezier triangle" in this way - to do this you need write your own code which will use bezier-triangle formulas (where the input parameters are triangle points in Barycentric_coordinate_system).

提交回复
热议问题