Metal iOS 15.5 to 16.0 API Differences

MTLAccelerationStructure.h
Added MTLAccelerationStructureGeometryDescriptor.primitiveDataBuffer
Added MTLAccelerationStructureGeometryDescriptor.primitiveDataBufferOffset
Added MTLAccelerationStructureGeometryDescriptor.primitiveDataStride
Added MTLAccelerationStructureGeometryDescriptor.primitiveDataElementSize
Added MTLAccelerationStructureTriangleGeometryDescriptor.vertexFormat
Added MTLAccelerationStructureTriangleGeometryDescriptor.transformationMatrixBuffer
Added MTLAccelerationStructureTriangleGeometryDescriptor.transformationMatrixBufferOffset
Added MTLAccelerationStructureMotionTriangleGeometryDescriptor.vertexFormat
Added MTLAccelerationStructureMotionTriangleGeometryDescriptor.transformationMatrixBuffer
Added MTLAccelerationStructureMotionTriangleGeometryDescriptor.transformationMatrixBufferOffset
Added MTLAccelerationStructure.gpuResourceID
MTLAccelerationStructureCommandEncoder.h
Added MTLAccelerationStructureRefitOptions
Added MTLAccelerationStructureRefitOptionVertexData
Added MTLAccelerationStructureRefitOptionPerPrimitiveData
Added -[MTLAccelerationStructureCommandEncoder refitAccelerationStructure:descriptor:destination:scratchBuffer:scratchBufferOffset:options:]
Added MTLAccelerationStructurePassSampleBufferAttachmentDescriptor
Added MTLAccelerationStructurePassSampleBufferAttachmentDescriptor.sampleBuffer
Added MTLAccelerationStructurePassSampleBufferAttachmentDescriptor.startOfEncoderSampleIndex
Added MTLAccelerationStructurePassSampleBufferAttachmentDescriptor.endOfEncoderSampleIndex
Added MTLAccelerationStructurePassSampleBufferAttachmentDescriptorArray
Added -[MTLAccelerationStructurePassSampleBufferAttachmentDescriptorArray objectAtIndexedSubscript:]
Added -[MTLAccelerationStructurePassSampleBufferAttachmentDescriptorArray setObject:atIndexedSubscript:]
Added MTLAccelerationStructurePassDescriptor
Added +[MTLAccelerationStructurePassDescriptor accelerationStructurePassDescriptor]
Added MTLAccelerationStructurePassDescriptor.sampleBufferAttachments
MTLArgument.h
Added MTLBindingType
Added MTLBindingTypeBuffer
Added MTLBindingTypeThreadgroupMemory
Added MTLBindingTypeTexture
Added MTLBindingTypeSampler
Added MTLBindingTypeImageblockData
Added MTLBindingTypeImageblock
Added MTLBindingTypeVisibleFunctionTable
Added MTLBindingTypePrimitiveAccelerationStructure
Added MTLBindingTypeInstanceAccelerationStructure
Added MTLBindingTypeIntersectionFunctionTable
Added MTLBindingTypeObjectPayload
Added MTLBinding
Added MTLBinding.name
Added MTLBinding.type
Added MTLBinding.access
Added MTLBinding.index
Added MTLBinding.used
Added MTLBinding.argument
Added MTLBufferBinding
Added MTLBufferBinding.bufferAlignment
Added MTLBufferBinding.bufferDataSize
Added MTLBufferBinding.bufferDataType
Added MTLBufferBinding.bufferStructType
Added MTLBufferBinding.bufferPointerType
Added MTLThreadgroupBinding
Added MTLThreadgroupBinding.threadgroupMemoryAlignment
Added MTLThreadgroupBinding.threadgroupMemoryDataSize
Added MTLTextureBinding
Added MTLTextureBinding.textureType
Added MTLTextureBinding.textureDataType
Added MTLTextureBinding.depthTexture
Added MTLTextureBinding.arrayLength
Added MTLObjectPayloadBinding
Added MTLObjectPayloadBinding.objectPayloadAlignment
Added MTLObjectPayloadBinding.objectPayloadDataSize
Modified MTLArgumentTypeBuffer
Availability
FromAvailable
ToDeprecated

Modified MTLArgumentTypeThreadgroupMemory
Availability
FromAvailable
ToDeprecated

Modified MTLArgumentTypeTexture
Availability
FromAvailable
ToDeprecated

Modified MTLArgumentTypeSampler
Availability
FromAvailable
ToDeprecated

Modified MTLArgumentTypeImageblockData
Availability
FromAvailable
ToDeprecated

Modified MTLArgumentTypeImageblock
Availability
FromAvailable
ToDeprecated

Modified MTLArgumentTypeVisibleFunctionTable
Availability
FromAvailable
ToDeprecated

Modified MTLArgumentTypePrimitiveAccelerationStructure
Availability
FromAvailable
ToDeprecated

Modified MTLArgumentTypeInstanceAccelerationStructure
Availability
FromAvailable
ToDeprecated

Modified MTLArgumentTypeIntersectionFunctionTable
Availability
FromAvailable
ToDeprecated

Modified MTLArgument
Availability
FromAvailable
ToDeprecated

MTLBinaryArchive.h
Added MTLBinaryArchiveErrorInternalError
MTLBuffer.h
Added MTLBuffer.gpuAddress
MTLCommandBuffer.h
Added -[MTLCommandBuffer accelerationStructureCommandEncoderWithDescriptor:]
Modified MTLCommandBufferErrorBlacklisted
Availability
FromAvailable
ToDeprecated

MTLCommandEncoder.h
Modified MTLResourceUsageSample
Availability
FromAvailable
ToDeprecated

MTLComputePipeline.h
Added MTLComputePipelineReflection.bindings
Added MTLComputePipelineState.gpuResourceID
Modified MTLComputePipelineReflection.arguments
Availability
FromAvailable
ToDeprecated

MTLDevice.h
Added MTLIOCompressionMethod
Added MTLIOCompressionMethodZlib
Added MTLIOCompressionMethodLZFSE
Added MTLIOCompressionMethodLZ4
Added MTLIOCompressionMethodLZMA
Added MTLIOCompressionMethodLZBitmap
Added MTLGPUFamilyMetal3
Added MTLSparsePageSize
Added MTLSparsePageSize16
Added MTLSparsePageSize64
Added MTLSparsePageSize256
Added -[MTLDevice newRenderPipelineStateWithMeshDescriptor:options:reflection:error:]
Added -[MTLDevice newRenderPipelineStateWithMeshDescriptor:options:completionHandler:]
Added -[MTLDevice newIOHandleWithURL:error:]
Added -[MTLDevice newIOCommandQueueWithDescriptor:error:]
Added -[MTLDevice newIOHandleWithURL:compressionMethod:error:]
Added -[MTLDevice sparseTileSizeInBytesForSparsePageSize:]
Added -[MTLDevice sparseTileSizeWithTextureType:pixelFormat:sampleCount:sparsePageSize:]
Added -[MTLDevice newArgumentEncoderWithBufferBinding:]
Added -[MTLDevice heapAccelerationStructureSizeAndAlignWithSize:]
Added -[MTLDevice heapAccelerationStructureSizeAndAlignWithDescriptor:]
Modified MTLFeatureSet_iOS_GPUFamily1_v1
Availability
FromAvailable
ToDeprecated

Modified MTLFeatureSet_iOS_GPUFamily2_v1
Availability
FromAvailable
ToDeprecated

Modified MTLFeatureSet_iOS_GPUFamily1_v2
Availability
FromAvailable
ToDeprecated

Modified MTLFeatureSet_iOS_GPUFamily2_v2
Availability
FromAvailable
ToDeprecated

Modified MTLFeatureSet_iOS_GPUFamily3_v1
Availability
FromAvailable
ToDeprecated

Modified MTLFeatureSet_iOS_GPUFamily1_v3
Availability
FromAvailable
ToDeprecated

Modified MTLFeatureSet_iOS_GPUFamily2_v3
Availability
FromAvailable
ToDeprecated

Modified MTLFeatureSet_iOS_GPUFamily3_v2
Availability
FromAvailable
ToDeprecated

Modified MTLFeatureSet_iOS_GPUFamily1_v4
Availability
FromAvailable
ToDeprecated

Modified MTLFeatureSet_iOS_GPUFamily2_v4
Availability
FromAvailable
ToDeprecated

Modified MTLFeatureSet_iOS_GPUFamily3_v3
Availability
FromAvailable
ToDeprecated

Modified MTLFeatureSet_iOS_GPUFamily4_v1
Availability
FromAvailable
ToDeprecated

Modified MTLFeatureSet_iOS_GPUFamily1_v5
Availability
FromAvailable
ToDeprecated

Modified MTLFeatureSet_iOS_GPUFamily2_v5
Availability
FromAvailable
ToDeprecated

Modified MTLFeatureSet_iOS_GPUFamily3_v4
Availability
FromAvailable
ToDeprecated

Modified MTLFeatureSet_iOS_GPUFamily4_v2
Availability
FromAvailable
ToDeprecated

Modified MTLFeatureSet_iOS_GPUFamily5_v1
Availability
FromAvailable
ToDeprecated

Modified MTLGPUFamilyMac1
Availability
FromAvailable
ToDeprecated

Modified MTLGPUFamilyMacCatalyst1
Availability
FromAvailable
ToDeprecated

Modified MTLGPUFamilyMacCatalyst2
Availability
FromAvailable
ToDeprecated

Modified MTLDevice.barycentricCoordsSupported
Availability
FromAvailable
ToDeprecated

Modified -[MTLDevice newLibraryWithFile:error:]
AvailabilityDeprecation Message
FromAvailablenone
ToDeprecatedUse -newLibraryWithURL:error: instead

Modified -[MTLDevice supportsFeatureSet:]
AvailabilityDeprecation Message
FromAvailablenone
ToDeprecatedUse supportsFamily instead

MTLHeap.h
Added MTLHeapDescriptor.sparsePageSize
Added -[MTLHeap newAccelerationStructureWithSize:]
Added -[MTLHeap newAccelerationStructureWithDescriptor:]
Added -[MTLHeap newAccelerationStructureWithSize:offset:]
Added -[MTLHeap newAccelerationStructureWithDescriptor:offset:]
MTLIndirectCommandBuffer.h
Added MTLIndirectCommandBufferDescriptor.supportRayTracing
Added MTLIndirectCommandBuffer.gpuResourceID
MTLIntersectionFunctionTable.h
Added MTLIntersectionFunctionTable.gpuResourceID
MTLIOCommandBuffer.h
Added MTLIOStatus
Added MTLIOStatusPending
Added MTLIOStatusCancelled
Added MTLIOStatusError
Added MTLIOStatusComplete
Added MTLIOCommandBufferHandler
Added MTLIOCommandBuffer
Added -[MTLIOCommandBuffer addCompletedHandler:]
Added -[MTLIOCommandBuffer loadBytes:size:sourceHandle:sourceHandleOffset:]
Added -[MTLIOCommandBuffer loadBuffer:offset:size:sourceHandle:sourceHandleOffset:]
Added -[MTLIOCommandBuffer loadTexture:slice:level:size:sourceBytesPerRow:sourceBytesPerImage:destinationOrigin:sourceHandle:sourceHandleOffset:]
Added -[MTLIOCommandBuffer copyStatusToBuffer:offset:]
Added -[MTLIOCommandBuffer commit]
Added -[MTLIOCommandBuffer waitUntilCompleted]
Added -[MTLIOCommandBuffer tryCancel]
Added -[MTLIOCommandBuffer addBarrier]
Added -[MTLIOCommandBuffer pushDebugGroup:]
Added -[MTLIOCommandBuffer popDebugGroup]
Added -[MTLIOCommandBuffer enqueue]
Added -[MTLIOCommandBuffer waitForEvent:value:]
Added -[MTLIOCommandBuffer signalEvent:value:]
Added MTLIOCommandBuffer.label
Added MTLIOCommandBuffer.status
Added MTLIOCommandBuffer.error
MTLIOCommandQueue.h
Added MTLIOPriority
Added MTLIOPriorityHigh
Added MTLIOPriorityNormal
Added MTLIOPriorityLow
Added MTLIOCommandQueueType
Added MTLIOCommandQueueTypeConcurrent
Added MTLIOCommandQueueTypeSerial
Added MTLIOErrorDomain
Added MTLIOError
Added MTLIOErrorURLInvalid
Added MTLIOErrorInternal
Added MTLIOCommandQueue
Added -[MTLIOCommandQueue enqueueBarrier]
Added -[MTLIOCommandQueue commandBuffer]
Added -[MTLIOCommandQueue commandBufferWithUnretainedReferences]
Added MTLIOCommandQueue.label
Added MTLIOScratchBuffer
Added MTLIOScratchBuffer.buffer
Added MTLIOScratchBufferAllocator
Added -[MTLIOScratchBufferAllocator newScratchBufferWithMinimumSize:]
Added MTLIOCommandQueueDescriptor
Added MTLIOCommandQueueDescriptor.maxCommandBufferCount
Added MTLIOCommandQueueDescriptor.priority
Added MTLIOCommandQueueDescriptor.type
Added MTLIOCommandQueueDescriptor.maxCommandsInFlight
Added MTLIOCommandQueueDescriptor.scratchBufferAllocator
Added MTLIOFileHandle
Added MTLIOFileHandle.label
MTLIOCompressor.h
Added MTLIOCompressionStatus
Added MTLIOCompressionStatusComplete
Added MTLIOCompressionStatusError
Added MTLIOCompressionContext
Added MTLIOCompressionContextDefaultChunkSize()
Added MTLIOCreateCompressionContext()
Added MTLIOCompressionContextAppendData()
Added MTLIOFlushAndDestroyCompressionContext()
MTLLibrary.h
Added MTLFunctionTypeMesh
Added MTLFunctionTypeObject
Added MTLLanguageVersion3_0
Added MTLLibraryOptimizationLevel
Added MTLLibraryOptimizationLevelDefault
Added MTLLibraryOptimizationLevelSize
Added MTLCompileOptions.optimizationLevel
Modified MTLLanguageVersion1_0
AvailabilityDeprecation Message
FromAvailablenone
ToDeprecatedUse a newer language standard

MTLRenderCommandEncoder.h
Added MTLRenderStageObject
Added MTLRenderStageMesh
Added -[MTLRenderCommandEncoder setObjectBytes:length:atIndex:]
Added -[MTLRenderCommandEncoder setObjectBuffer:offset:atIndex:]
Added -[MTLRenderCommandEncoder setObjectBufferOffset:atIndex:]
Added -[MTLRenderCommandEncoder setObjectBuffers:offsets:withRange:]
Added -[MTLRenderCommandEncoder setObjectTexture:atIndex:]
Added -[MTLRenderCommandEncoder setObjectTextures:withRange:]
Added -[MTLRenderCommandEncoder setObjectSamplerState:atIndex:]
Added -[MTLRenderCommandEncoder setObjectSamplerStates:withRange:]
Added -[MTLRenderCommandEncoder setObjectSamplerState:lodMinClamp:lodMaxClamp:atIndex:]
Added -[MTLRenderCommandEncoder setObjectSamplerStates:lodMinClamps:lodMaxClamps:withRange:]
Added -[MTLRenderCommandEncoder setObjectThreadgroupMemoryLength:atIndex:]
Added -[MTLRenderCommandEncoder setMeshBytes:length:atIndex:]
Added -[MTLRenderCommandEncoder setMeshBuffer:offset:atIndex:]
Added -[MTLRenderCommandEncoder setMeshBufferOffset:atIndex:]
Added -[MTLRenderCommandEncoder setMeshBuffers:offsets:withRange:]
Added -[MTLRenderCommandEncoder setMeshTexture:atIndex:]
Added -[MTLRenderCommandEncoder setMeshTextures:withRange:]
Added -[MTLRenderCommandEncoder setMeshSamplerState:atIndex:]
Added -[MTLRenderCommandEncoder setMeshSamplerStates:withRange:]
Added -[MTLRenderCommandEncoder setMeshSamplerState:lodMinClamp:lodMaxClamp:atIndex:]
Added -[MTLRenderCommandEncoder setMeshSamplerStates:lodMinClamps:lodMaxClamps:withRange:]
Added -[MTLRenderCommandEncoder drawMeshThreadgroups:threadsPerObjectThreadgroup:threadsPerMeshThreadgroup:]
Added -[MTLRenderCommandEncoder drawMeshThreads:threadsPerObjectThreadgroup:threadsPerMeshThreadgroup:]
Added -[MTLRenderCommandEncoder drawMeshThreadgroupsWithIndirectBuffer:indirectBufferOffset:threadsPerObjectThreadgroup:threadsPerMeshThreadgroup:]
Added -[MTLRenderCommandEncoder memoryBarrierWithScope:afterStages:beforeStages:]
Added -[MTLRenderCommandEncoder memoryBarrierWithResources:count:afterStages:beforeStages:]
Modified -[MTLRenderCommandEncoder useResource:usage:]
Availability
FromAvailable
ToDeprecated

Modified -[MTLRenderCommandEncoder useResources:count:usage:]
Availability
FromAvailable
ToDeprecated

Modified -[MTLRenderCommandEncoder useHeap:]
Availability
FromAvailable
ToDeprecated

Modified -[MTLRenderCommandEncoder useHeaps:count:]
Availability
FromAvailable
ToDeprecated

MTLRenderPipeline.h
Added MTLRenderPipelineReflection.vertexBindings
Added MTLRenderPipelineReflection.fragmentBindings
Added MTLRenderPipelineReflection.tileBindings
Added MTLRenderPipelineReflection.objectBindings
Added MTLRenderPipelineReflection.meshBindings
Added MTLRenderPipelineState.maxTotalThreadsPerObjectThreadgroup
Added MTLRenderPipelineState.maxTotalThreadsPerMeshThreadgroup
Added MTLRenderPipelineState.objectThreadExecutionWidth
Added MTLRenderPipelineState.meshThreadExecutionWidth
Added MTLRenderPipelineState.maxTotalThreadgroupsPerMeshGrid
Added MTLRenderPipelineState.gpuResourceID
Added MTLMeshRenderPipelineDescriptor
Added MTLMeshRenderPipelineDescriptor.label
Added MTLMeshRenderPipelineDescriptor.objectFunction
Added MTLMeshRenderPipelineDescriptor.meshFunction
Added MTLMeshRenderPipelineDescriptor.fragmentFunction
Added MTLMeshRenderPipelineDescriptor.maxTotalThreadsPerObjectThreadgroup
Added MTLMeshRenderPipelineDescriptor.maxTotalThreadsPerMeshThreadgroup
Added MTLMeshRenderPipelineDescriptor.objectThreadgroupSizeIsMultipleOfThreadExecutionWidth
Added MTLMeshRenderPipelineDescriptor.meshThreadgroupSizeIsMultipleOfThreadExecutionWidth
Added MTLMeshRenderPipelineDescriptor.payloadMemoryLength
Added MTLMeshRenderPipelineDescriptor.maxTotalThreadgroupsPerMeshGrid
Added MTLMeshRenderPipelineDescriptor.objectBuffers
Added MTLMeshRenderPipelineDescriptor.meshBuffers
Added MTLMeshRenderPipelineDescriptor.fragmentBuffers
Added MTLMeshRenderPipelineDescriptor.rasterSampleCount
Added MTLMeshRenderPipelineDescriptor.alphaToCoverageEnabled
Added MTLMeshRenderPipelineDescriptor.alphaToOneEnabled
Added MTLMeshRenderPipelineDescriptor.rasterizationEnabled
Added MTLMeshRenderPipelineDescriptor.maxVertexAmplificationCount
Added MTLMeshRenderPipelineDescriptor.colorAttachments
Added MTLMeshRenderPipelineDescriptor.depthAttachmentPixelFormat
Added MTLMeshRenderPipelineDescriptor.stencilAttachmentPixelFormat
Added -[MTLMeshRenderPipelineDescriptor reset]
Modified MTLRenderPipelineReflection.vertexArguments
Availability
FromAvailable
ToDeprecated

Modified MTLRenderPipelineReflection.fragmentArguments
Availability
FromAvailable
ToDeprecated

Modified MTLRenderPipelineReflection.tileArguments
Availability
FromAvailable
ToDeprecated

Modified MTLRenderPipelineDescriptor.sampleCount
Availability
FromAvailable
ToDeprecated

MTLResource.h
Modified MTLResourceOptionCPUCacheModeDefault
Availability
FromAvailable
ToDeprecated

Modified MTLResourceOptionCPUCacheModeWriteCombined
Availability
FromAvailable
ToDeprecated

MTLResourceStateCommandEncoder.h
Added -[MTLResourceStateCommandEncoder moveTextureMappingsFromTexture:sourceSlice:sourceLevel:sourceOrigin:sourceSize:toTexture:destinationSlice:destinationLevel:destinationOrigin:]
MTLSampler.h
Added MTLSamplerState.gpuResourceID
MTLTexture.h
Added MTLTexture.gpuResourceID
MTLTypes.h
Added MTLResourceID
MTLVisibleFunctionTable.h
Added MTLVisibleFunctionTable.gpuResourceID