grid

fun TriangleMeshBuilder.grid(width: Int, height: Int, coordinates: GridCoordinates = GridCoordinates.BIPOLAR, builder: TriangleMeshBuilder.(u: Double, v: Double) -> Unit)(source)

Create a 2D grid of width x height 3D elements. The builder function will get called with the u and v coordinates of each grid cell, so you have an opportunity to add meshes to the scene using those coordinates. The coordinate values will be scaled according to coordinates. Use:


fun TriangleMeshBuilder.grid(width: Int, height: Int, depth: Int, coordinates: GridCoordinates = GridCoordinates.BIPOLAR, builder: TriangleMeshBuilder.(u: Double, v: Double, w: Double) -> Unit)(source)

Create a 3D grid of width x height x depth 3D elements. The builder function will get called with the u, v and w coordinates of each grid cell, so you have an opportunity to add meshes to the scene using those coordinates. The coordinate values will be scaled according to coordinates. Use: