> ## Documentation Index
> Fetch the complete documentation index at: https://devdocs.xbox.com/llms.txt
> Use this file to discover all available pages before exploring further.

# AtomicCopyBufferUINT64

> 以原子方式将 UINT64 类型的主数据元素以及可选的相关资源从一个资源复制到另一个资源。

以原子方式将 UINT64 类型的主数据元素以及可选的相关资源从一个资源复制到另一个资源。

这些"相关资源"之所以如此命名，是因为它们依赖主数据元素来定位它们，通常关键元素是地址、索引或其他句柄，间接引用一个或多个相关资源。

此函数支持 UINT64（64 位）类型的主数据元素。此函数的另一个版本 [AtomicCopyBufferUINT](/reference/graphics/d3d12/interfaces/id3d12graphicscommandlist1/methods/id3d12graphicscommandlist1_atomiccopybufferuint_public) 支持 UINT（32 位）类型的主数据元素。

## 语法

```cpp theme={null}
void AtomicCopyBufferUINT64(
    ID3D12Resource  pDstBuffer,
    UINT64 DstOffset,
    ID3D12Resource  pSrcBuffer,
    UINT64 SrcOffset,
    UINT Dependencies,
    ID3D12Resource const  ppDependentResources,
    const D3D12_SUBRESOURCE_RANGE_UINT64  pDependentSubresourceRanges
)
```

### 参数

*pDstBuffer \[in]*\
类型：ID3D12Resource \*

[SAL](https://learn.microsoft.com/en-us/visualstudio/code-quality/annotating-function-parameters-and-return-values?view=vs-2015)：<code>*In*</code>

将 UINT64 主数据元素复制到的资源。

*DstOffset*\
类型：UINT64

进入目标资源缓冲区的偏移量，指定主数据元素被复制到的位置（以字节为单位）。此偏移量与资源缓冲区的基地址相结合，必须产生按 UINT64 值自然对齐的内存地址。

*pSrcBuffer \[in]*\
类型：ID3D12Resource \*

[SAL](https://learn.microsoft.com/en-us/visualstudio/code-quality/annotating-function-parameters-and-return-values)：<code>*In*</code>

从中复制 UINT64 主数据元素的资源。此数据通常是地址、索引或其他句柄，着色器代码可以使用它来定位对延迟敏感信息的最新版本。

*SrcOffset*\
类型：UINT64

进入源资源缓冲区的偏移量，指定主数据元素从何处复制（以字节为单位）。此偏移量与资源缓冲区的基地址相结合，必须产生按 UINT64 值自然对齐的内存地址。

*Dependencies*\
类型：UINT

相关资源的数量。

*ppDependentResources \[in]*\
类型：ID3D12Resource \*const \*

[SAL](https://learn.microsoft.com/en-us/visualstudio/code-quality/annotating-function-parameters-and-return-values)：<code>*In\_reads*(Dependencies)</code>

包含数据有效负载中相关元素的资源数组。

*pDependentSubresourceRanges \[in]*\
类型：const D3D12\_SUBRESOURCE\_RANGE\_UINT64 \*

[SAL](https://learn.microsoft.com/en-us/visualstudio/code-quality/annotating-function-parameters-and-return-values)：<code>*In\_reads*(Dependencies)</code>

指定数据有效负载中相关元素的子资源范围数组。这些元素在主数据元素本身以原子方式复制之前完全更新。这确保了整个操作在逻辑上是原子的；即主数据元素永远不会引用不完整的数据有效负载。

### 返回值

类型：void

无。

## 备注

此方法通常用于更新那些正常渲染管道延迟可能对用户体验有害的资源。例如，应用程序可以根据最新的用户输入（如来自头戴式显示器的传感器）计算视图矩阵，并使用此函数在已分派到 GPU 的命令列表中更新并激活此矩阵，以减少输入和渲染之间的可感知延迟。

## 要求

**头文件：** d3d12\_xs.h 或 d3d12\_x.h\
**库：** d3d12\_xs.lib 或 d3d12\_x.lib\
**支持的平台**：XBOX Series 主机和 XBOX One 系列

## 另请参阅

[ID3D12GraphicsCommandList1](/reference/graphics/d3d12/interfaces/id3d12graphicscommandlist1/id3d12graphicscommandlist1_public)


## Related topics

- [AtomicCopyBufferUINT](/zh-CN/reference/graphics/d3d12/interfaces/id3d12graphicscommandlist1/methods/id3d12graphicscommandlist1_atomiccopybufferuint_public.md)
- [D3D12_SUBRESOURCE_RANGE_UINT64](/zh-CN/reference/graphics/d3d12/structs/d3d12_subresource_range_uint64_public.md)
- [CopyBufferRegion](/zh-CN/reference/graphics/d3d12/interfaces/id3d12graphicscommandlist/methods/id3d12graphicscommandlist_copybufferregion_public.md)
- [CopyTiles](/zh-CN/reference/graphics/d3d12/interfaces/id3d12graphicscommandlist/methods/id3d12graphicscommandlist_copytiles_public.md)
- [GetCopyableFootprints](/zh-CN/reference/graphics/d3d12/interfaces/id3d12device/methods/id3d12device_getcopyablefootprints_public.md)
