---
title: "copyMappings(sourceTexture:destinationTexture:operations:)"
framework: metal
role: symbol
role_heading: Instance Method
path: "metal/mtl4commandqueue/copymappings(sourcetexture:destinationtexture:operations:)"
---

# copyMappings(sourceTexture:destinationTexture:operations:)

Copies multiple regions within a source placement sparse texture to a destination placement sparse texture.

## Declaration

```swift
func copyMappings(sourceTexture: any MTLTexture, destinationTexture: any MTLTexture, operations: [MTL4CopySparseTextureMappingOperation])
```

## Parameters

- `sourceTexture`: The source placement sparse doc://com.apple.metal/documentation/Metal/MTLTexture.
- `destinationTexture`: The destination placement sparse doc://com.apple.metal/documentation/Metal/MTLTexture.
- `operations`: An array of doc://com.apple.metal/documentation/Metal/MTL4CopySparseTextureMappingOperation instances to perform.

## Discussion

Discussion You are responsible for ensuring the source and destination textures have the same placementSparsePageSize. Additionally, you are responsible for ensuring that the source and destination textures don’t use the same aliased tiles at the same time. note: If a sparse texture and a sparse buffer share the same backing tiles, these don’t provide you you with meaningful views of the other resource’s data.
