public Point3D[,] EvaluateSurface(SurfaceParametricEquation surface) { var samples = GetSamples(); Point3D[,] points = new Point3D[UCount, VCount]; for (int i = 0; i < UCount; i++) { for (int j = 0; j < VCount; j++) { var sample = samples[i, j]; double u = sample.X; double v = sample.Y; points[i, j] = surface.Evaluate(u, v); } } return(points); }
public Vector[,] EvaluateSurface(SurfaceParametricEquation surface) { var samples = GetSamples(); var points = new Vector[UCount, VCount]; for (var i = 0; i < UCount; i++) { for (var j = 0; j < VCount; j++) { var sample = samples[i, j]; var u = sample.X; var v = sample.Y; points[i, j] = surface.Evaluate(u, v); } } return(points); }