Doc comments!
This commit is contained in:
parent
5fa89d1e47
commit
a5c86f9c31
1 changed files with 5 additions and 2 deletions
|
@ -11,7 +11,7 @@ import MetalKit
|
|||
|
||||
class Terrain: NSObject {
|
||||
|
||||
/// Creete a Metal vertex descriptor specifying how vertices will by laid out for input into our render pipeline and how we'll layout our Model IO vertices.
|
||||
/// Create a Metal vertex descriptor specifying how vertices will by laid out for input into our render pipeline and how we'll layout our Model IO vertices.
|
||||
class func buildVertexDescriptor() -> MTLVertexDescriptor {
|
||||
let mtlVertexDescriptor = MTLVertexDescriptor()
|
||||
|
||||
|
@ -35,6 +35,10 @@ class Terrain: NSObject {
|
|||
}
|
||||
|
||||
/// Create and condition mesh data to feed into a pipeline using the given vertex descriptor.
|
||||
/// @param dimensions Coordinate dimensions of the plane
|
||||
/// @param segments Number of segments to divide each dimension into
|
||||
/// @param device Metal device
|
||||
/// @param vertexDescriptor Description of how to lay out vertex data in GPU memory
|
||||
class func buildMesh(withDimensions dimensions: float2, segments: uint2, device: MTLDevice, vertexDescriptor: MTLVertexDescriptor) throws -> MTKMesh {
|
||||
let metalAllocator = MTKMeshBufferAllocator(device: device)
|
||||
|
||||
|
@ -58,7 +62,6 @@ class Terrain: NSObject {
|
|||
|
||||
let dimensions: float2
|
||||
let segments: uint2
|
||||
|
||||
let vertexDescriptor: MTLVertexDescriptor
|
||||
let mesh: MTKMesh
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue