編集

次の方法で共有


Metal Namespace

The Metal namespace provides GPU-accelerated 3D rendering and data-parallel computation.

Classes

IMTLRenderCommandEncoder_Extensions
MTLArgument

Encapsulates a single parameter to a Metal function.

MTLArgumentDescriptor

An description of an argument inside an argument buffer.

MTLArgumentEncoder_Extensions

Extension methods for the IMTLArgumentEncoder protocol.

MTLArrayType

Encapsulates the details of an array argument to a Metal function.

MTLAttribute
MTLAttributeDescriptor
MTLAttributeDescriptorArray
MTLBlitCommandEncoder_Extensions

Extension methods to the IMTLBlitCommandEncoder interface to support all the methods from the IMTLBlitCommandEncoder protocol.

MTLBuffer_Extensions

Extension methods to the IMTLBuffer interface to support all the methods from the IMTLBuffer protocol.

MTLBufferLayoutDescriptor
MTLBufferLayoutDescriptorArray
MTLCaptureManager

Manages GPU captures for apps launched from Xcode.

MTLCaptureScope

Protocol for custom capture scope boundary for debugging from Xcode.

MTLCommandBuffer_Extensions

Extension methods to the IMTLCommandBuffer interface to support all the methods from the IMTLCommandBuffer protocol.

MTLCommandBufferErrorExtensions

Extension methods for the Metal.MTLCommandBufferError enumeration.

MTLCompileOptions

Configures the compilation of a Metal shader library.

MTLComputeCommandEncoder_Extensions

Extension methods to the IMTLComputeCommandEncoder interface to support all the methods from the IMTLComputeCommandEncoder protocol.

MTLComputePipelineDescriptor

Describes the compute state used during a compute operation pass. (See also IMTLComputePipelineState.)

MTLComputePipelineReflection

Encapsulates the details of the arguments of the compute function used to create an IMTLComputePipelineState object.

MTLComputePipelineState_Extensions

Extension methods to the IMTLComputePipelineState interface to support all the methods from the IMTLComputePipelineState protocol.

MTLDepthStencilDescriptor

Configures a depth stencil test operation.

MTLDevice

Represents a single GPU.

MTLDevice_Extensions

Extension methods to the IMTLDevice interface to support all the methods from the MTLDevice protocol.

MTLDrawable

Interface definition for objects that can receive rendering commands.

MTLDrawable_Extensions

Extension methods to the IMTLDrawable interface to support all the methods from the MTLDrawable protocol.

MTLFunction_Extensions

Extension methods to the IMTLFunction interface to support all the methods from the IMTLFunction protocol.

MTLFunctionConstant
MTLFunctionConstantValues
MTLHeap_Extensions

Extension methods to the IMTLHeap interface to support all the methods from the IMTLHeap protocol.

MTLHeapDescriptor
MTLIndirectCommandBufferDescriptor
MTLLibrary_Extensions

Extension methods to the IMTLLibrary interface to support all the methods from the IMTLLibrary protocol.

MTLLibraryErrorExtensions

Extension methods for the Metal.MTLLibraryError enumeration.

MTLParallelRenderCommandEncoder_Extensions

Extension methods to the IMTLParallelRenderCommandEncoder interface to support all the methods from the IMTLParallelRenderCommandEncoder protocol.

MTLPipelineBufferDescriptor

Contains a mutability description for a buffer.

MTLPipelineBufferDescriptorArray

An array of buffer mutability descriptors.

MTLPointerType
MTLRenderCommandEncoder_Extensions

Extension methods to the IMTLRenderCommandEncoder interface to support all the methods from the IMTLRenderCommandEncoder protocol.

MTLRenderPassAttachmentDescriptor

Configures a render target of a framebuffer.

MTLRenderPassColorAttachmentDescriptor

A MTLRenderPassAttachmentDescriptor that holds the clear color for the rendering pass.

MTLRenderPassColorAttachmentDescriptorArray

Holds an array of MTLRenderPassColorAttachmentDescriptor objects.

MTLRenderPassDepthAttachmentDescriptor

A MTLRenderPassAttachmentDescriptor that holds the clear depth for a rendering pass.

MTLRenderPassDescriptor

Defines the rendering target for pixels generated by a rendering pass.

MTLRenderPassStencilAttachmentDescriptor

A MTLRenderPassAttachmentDescriptor that holds the clear stencil for a rendering pass.

MTLRenderPipelineColorAttachmentDescriptor

Configures a color attachment associated with a rendering pipeline.

MTLRenderPipelineColorAttachmentDescriptorArray

An array of MTLRenderPipelineColorAttachmentDescriptor objects.

MTLRenderPipelineDescriptor

Configures a rendering pipeline with rasterization properties, visibility, blending, and shader functions.

MTLRenderPipelineErrorExtensions

Extension methods for the Metal.MTLRenderPipelineError enumeration.

MTLRenderPipelineReflection

The arguments (see MTLArgument) of a vertex or fragment function within a IMTLRenderPipelineState.

MTLRenderPipelineState_Extensions

Extension methods to the IMTLRenderPipelineState interface to support all the methods from the IMTLRenderPipelineState protocol.

MTLResource_Extensions

Extension methods to the IMTLResource interface to support all the methods from the IMTLResource protocol.

MTLSamplerDescriptor

Configures a sampler (see IMTLSamplerState).

MTLSharedEventHandle
MTLSharedEventListener
MTLSharedTextureHandle
MTLStageInputOutputDescriptor
MTLStencilDescriptor

Configures a stencil test operation.

MTLStructMember

Describes a single field within a MTLStructType struct.

MTLStructType

Defines a type representing a struct, which can be passed as an argument to Metal functions.

MTLTexture_Extensions

Extension methods to the IMTLTexture interface to support all the methods from the IMTLTexture protocol.

MTLTextureDescriptor

Configuration for IMTLTexture objects.

MTLTextureReferenceType
MTLTileRenderPipelineColorAttachmentDescriptor
MTLTileRenderPipelineColorAttachmentDescriptorArray
MTLTileRenderPipelineDescriptor
MTLType
MTLVertexAttribute

An attribute for per-vertex input to a vertex shader function.

MTLVertexAttributeDescriptor

An attribute for per-vertex input for a vertex shader function.

MTLVertexAttributeDescriptorArray

Holds an array of MTLVertexAttributeDescriptor objects.

MTLVertexBufferLayoutDescriptor

Configures how vertex and attribute data are fetched by a vertex shader function.

MTLVertexBufferLayoutDescriptorArray

Holds an array of MTLVertexBufferLayoutDescriptor objects.

MTLVertexDescriptor

Maps vertex data in memory to attributes in a vertex shader.

MTLVertexFormatExtensions

Extensions methods for MTLVertexFormat.

Structs

MTLClearColor

An RGBA color representing a clear pixel.

MTLClearValue

Struct that contains values that are used to clear various buffers and stencils.

MTLDispatchThreadgroupsIndirectArguments

Represents the number of threadgroups in each grid dimension for indirectly dispatched threadgroups.

MTLDrawIndexedPrimitivesIndirectArguments

Represents the data layout needed to draw indexed primitives.

MTLDrawPatchIndirectArguments
MTLDrawPrimitivesIndirectArguments

Represents the data layout needed to draw primitives.

MTLOrigin

The location of a pixel in an image or texture.

MTLQuadTessellationFactorsHalf
MTLRegion

A rectangle of pixels in an image or texture.

MTLSamplePosition

A sample position.

MTLScissorRect

The retangle used for the scissor fragment test.

MTLSize

The dimensions of a grid, image, texture, or threadgroup.

MTLSizeAndAlign
MTLStageInRegionIndirectArguments
MTLTriangleTessellationFactorsHalf
MTLViewport

Defines the clipping viewport.

Interfaces

IMTLArgumentEncoder

Encodes data into argument buffers.

IMTLBlitCommandEncoder

Protocol for writing data into frame buffers.

IMTLBuffer

System protocol for raw data that is accessible in strides.

IMTLCaptureScope

Custom capture scope boundary for debugging from Xcode.

IMTLCommandBuffer

Protocol for commands that are run on a GPU

IMTLCommandEncoder

System protocol for enqueuing and writing commands into a buffer.

IMTLCommandQueue

System protocol for objects that can queue command buffers for running on a GPU.

IMTLComputeCommandEncoder

Protocol for encoding and running parallel commands on a GPU.

IMTLComputePipelineState

System protocol that represents a compiled compute program.

IMTLDepthStencilState

System protocol for describing how the depth stencil should interact with the depth buffer during rendering.

IMTLDevice

System protocol for interacting with a single graphics device.

IMTLDrawable

Interface representing the required methods (if any) of the protocol MTLDrawable.

IMTLEvent
IMTLFence
IMTLFunction

System protocol for shader functions that are suitable for use on a GPU in a shader or compute function.

IMTLHeap
IMTLIndirectCommandBuffer
IMTLIndirectRenderCommand
IMTLLibrary

System protocol for libraries of shaders.

IMTLParallelRenderCommandEncoder

System protocol for breaking a single rendering pass into parallel command sets.

IMTLRenderCommandEncoder

System protocol for encoding render commands and state into a buffer.

IMTLRenderPipelineState

System protocol for encoding the state of a rendering pipeline.

IMTLResource

System protocol for for allocated segments of GPU memory.

IMTLSamplerState

System protocol the way that shaders or compute kernels will sample textures.

IMTLSharedEvent
IMTLTexture

System protocol for image data that is used by vertex shaders, fragment shaders, and compute kernels.

Enums

MTLArgumentAccess

Function access restrictions of argument data in the shader code.

MTLArgumentBuffersTier

Enumerates argument buffer tiers.

MTLArgumentType

The resource type of an argument of a function.

MTLAttributeFormat

Enumerates formats for function attributes.

MTLBarrierScope
MTLBlendFactor

Argument values for use with MTLBlendOperation.

MTLBlendOperation

How the source and destination values are combined.

MTLBlitOption

Enumerates blitting options.

MTLColorWriteMask

Permits or restricts writing to specific color channels.

MTLCommandBufferError

Enumeration of error codes describing why a command buffer has failed.

MTLCommandBufferStatus

The state of the command-buffer state-machine. Enqueued->Committed->Scheduled->Completed.

MTLCompareFunction

Holds a comparison test. When the comparison test passes, the incoming fragment is compared to the stored data at the specified location.

MTLCpuCacheMode

Enumerates what cache mode is used for CPU mapping of a resource.

MTLCullMode

Enumerates modes for culling and which types of primitives are culled.

MTLDataType

The data type of a function argument, as used in the shader language code.

MTLDepthClipMode

Enumerates values that indicate whether to clip or clamp depth values.

MTLDispatchType
MTLFeatureSet

Enumerates the hardware feature sets that are available on a device.

MTLFunctionType

The type of a Metal function.

MTLIndexType

The index type for an index buffer.

MTLIndirectCommandType
MTLLanguageVersion

Enumerates Metal shader programming language versions.

MTLLibraryError

Enumerates errors possible in the creation of an MTLLibrary or MTLFunction object.

MTLLoadAction

An action performed at the start of a rendering pass.

MTLMultisampleDepthResolveFilter

Enumerates MSAA dept resolve filter operations.

MTLMultisampleStencilResolveFilter
MTLMutability

Enumerates buffer mutability descriptions.

MTLPatchType
MTLPipelineOption

Options relating to argument information in the creation of a pipeline.

MTLPixelFormat

The format used by pixels, including color, depth, compression technigue, and data type for components.

MTLPrimitiveTopologyClass
MTLPrimitiveType

Enumerates the primitive geometry used for drawing commands.

MTLPurgeableState

The purgeable state of the resource.

MTLReadWriteTextureTier
MTLRenderPipelineError

Enumerates errors possible in the creation of a MTLRenderPipelineState.

MTLRenderStages
MTLResourceOptions

Holds options used by buffer and texture objects.

MTLResourceUsage

Enumerates resource usage patterns.

MTLSamplerAddressMode

The wrapping mode. Used when a fetch falls outside the bounds of a texture.

MTLSamplerBorderColor
MTLSamplerMinMagFilter

Options for calculating the pixel value returned within a mipmap level.

MTLSamplerMipFilter

Options for calculating the pixel value returned with multiple mipmap levels.

MTLStencilOperation

What to do if a stencil value passes or fails a comparison test.

MTLStepFunction
MTLStorageMode

Enumerates CPU cache modes for resource mapping.

MTLStoreAction

The action to be performed at the end of a rendering pass.

MTLStoreActionOptions

Enumerates store action options.

MTLTessellationControlPointIndexType
MTLTessellationFactorFormat
MTLTessellationFactorStepFunction
MTLTessellationPartitionMode
MTLTextureType

The dimensionality of each texture and how multiple images are arranged.

MTLTextureUsage

Enumerates the ways in which a IMTLTexture may be used.

MTLTriangleFillMode

How to rasterize triangle and triangle-strip primitives.

MTLVertexFormat

Enumerates vertex data formats (type and number).

MTLVertexStepFunction

The frequency at which the vertex shader function should fetch attribute data.

MTLVisibilityResultMode

Enumerates values that control how and whether to monitor samples that pass depth and stencil tests.

MTLWinding

Vertex winding rule for front-facing primitives.

Delegates

MTLDeallocator

Completion handler for deallocating a buffer.

MTLDeviceNotificationHandler
MTLNewComputePipelineStateWithReflectionCompletionHandler
MTLNewRenderPipelineStateWithReflectionCompletionHandler
MTLSharedEventNotificationBlock

Remarks

The Metal framework, introduced in iOS 8, provides low-level control of Graphical Processing Unit (GPU) accelerated rendering and data-parallel computation (GPGPU).

The Metal framework provides low-level access to the A7 GPU. Metal provides precompiled shaders, state objects, and explicit command scheduling. Its facilities can be used for either 3D rendering or General-Purpose GPU computation.