MeshBuilder.AddRevolvedGeometry()
或者MeshBuilder.AddSurfaceOfRevolution()
应该这样做。
在此处和此处查看带有注释的源代码
/// <summary>
/// Adds a surface of revolution
/// </summary>
/// <param name="origin">The origin.</param>
/// <param name="axis">The axis.</param>
/// <param name="section">The points defining the curve to revolve.</param>
/// <param name="sectionIndices">The indices of the line segments of the section.</param>
/// <param name="thetaDiv">The number of divisions.</param>
/// <param name="textureValues">The texture values.</param>
public void AddSurfaceOfRevolution(
Point3D origin, Vector3D axis, IList<Point> section, IList<int> sectionIndices,
int thetaDiv = 37, IList<double> textureValues = null)
和
/// <summary>
/// Adds a surface of revolution.
/// </summary>
/// <param name="points">The points (x coordinates are distance from the origin along the axis of revolution, y coordinates are radius, )</param>
/// <param name="textureValues">The v texture coordinates, one for each point in the <paramref name="points" /> list.</param>
/// <param name="origin">The origin of the revolution axis.</param>
/// <param name="direction">The direction of the revolution axis.</param>
/// <param name="thetaDiv">The number of divisions around the mesh.</param>
/// <remarks>
/// See http://en.wikipedia.org/wiki/Surface_of_revolution.
/// </remarks>
public void AddRevolvedGeometry(IList<Point> points, IList<double> textureValues, Point3D origin, Vector3D direction, int thetaDiv)