对于贝塞尔曲面片,我可以将其定义为曲面并绘制网格线,如示例代码所示:
import three;
size(10cm);
currentlight=Viewport;
surface s=surface(patch(new triple[][] {
{(0,0,0),(1,0,0),(1,0,0),(2,0,0)},
{(0,1,0),(1,0,1),(1,0,1),(2,1,0)},
{(0,1,0),(1,0,-1),(1,0,-1),(2,1,0)},
{(0,2,0),(1,2,0),(1,2,0),(2,2,0)}}));
//plot surface
draw(s,yellow);
//plot mesh line
draw(s.s[0].vequals(0.5),squarecap+2bp+blue,currentlight);
draw(s.s[0].uequals(0.5),squarecap+2bp+red,currentlight);
我怎样才能对 nurbs 曲面做类似的事情?