> ## 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.

# Signal2X (XBOX Series 主機)

> Signal2X (XBOX Series 主機) — 將柵欄更新為指定的值。適用於 XBOX 遊戲開發的 Direct3D 12 圖形 API 參考。

將柵欄更新為指定的值。

## 語法

```cpp theme={null}
HRESULT Signal2X(  
         ID3D12Fence* pFence,  
         UINT64 Value,  
         D3D12XBOX_SYNC_PARAMS* pSyncBottomOfPipeParams,  
         D3D12XBOX_SYNC_PARAMS* pSyncTopOfPipeParams  
)  
```

### 參數

*pFence*   \_In\_\
類型：ID3D12Fence\*

ID3D12Fence 物件的指標。

*Value*   \_In\_\
類型：UINT64

要將柵欄設定成的值。

*pSyncBottomOfPipeParams*   \_In\_opt\_\
類型：[D3D12XBOX\_SYNC\_PARAMS\*](/zh-TW/reference/graphics/d3d12_xs/structs/d3d12xbox_sync_params)

選用的一組管線底部同步處理與控制指示詞，會在更新柵欄時執行。

*pSyncTopOfPipeParams*   \_In\_opt\_\
類型：[D3D12XBOX\_SYNC\_PARAMS\*](/zh-TW/reference/graphics/d3d12_xs/structs/d3d12xbox_sync_params)

此參數會被忽略。對於訊號/等候配對中所需的管線頂端排清，請使用 [WaitX](/zh-TW/reference/graphics/d3d12_xs/interfaces/ID3D12CommandQueue/methods/id3d12commandqueue_waitx)。
若有其他自訂同步處理需求，請參閱 [SyncBottomOfPipeX](/zh-TW/reference/graphics/d3d12_xs/interfaces/ID3D12GraphicsCommandList6/methods/id3d12graphicscommandlist6_syncbottomofpipex) 和 [SyncTopOfPipeX](/zh-TW/reference/graphics/d3d12_xs/interfaces/ID3D12GraphicsCommandList6/methods/id3d12graphicscommandlist6_synctopofpipex)。

### 傳回值

類型：HRESULT

其中一個 [Direct3D 12 傳回碼](https://msdn.microsoft.com/library/windows/desktop/dn706075\(v=vs.85\).aspx)。

## 備註

請呼叫 **Signal2X**，而非 **Signal**。**Signal2X** 可讓您在執行訊號時完整控制管線排清 (包括不排清)。

如需柵欄的相關資訊，請參閱[從 Direct3D 11 移植到 Direct3D 12](https://learn.microsoft.com/en-us/windows/win32/direct3d12/porting-from-direct3d-11-to-direct3d-12#cpugpu-synchronization) 中的 **CPU/GPU 同步處理**。

## 需求

**標頭：** d3d12\_xs.h\
**程式庫：** d3d12\_xs.lib\
**支援的平台：** XBOX Series 主機

## 另請參閱

[WaitX](/zh-TW/reference/graphics/d3d12_xs/interfaces/ID3D12CommandQueue/methods/id3d12commandqueue_waitx)\
[SyncBottomOfPipeX](/zh-TW/reference/graphics/d3d12_xs/interfaces/ID3D12GraphicsCommandList6/methods/id3d12graphicscommandlist6_syncbottomofpipex)\
[SyncTopOfPipeX](/zh-TW/reference/graphics/d3d12_xs/interfaces/ID3D12GraphicsCommandList6/methods/id3d12graphicscommandlist6_synctopofpipex)\
[ID3D12CommandQueue](/zh-TW/reference/graphics/d3d12_x/interfaces/id3d12commandqueue/id3d12commandqueue)


## Related topics

- [XBOX Series X|S 總覽](/zh-TW/paths/series-xs/overview.md)
- [XBOX 主機遊戲的認證測試 XBOX 需求](/zh-TW/publishing/certification/console-cert-tested-requirements.md)
- [Play Anywhere(主機 + PC)總覽](/zh-TW/paths/play-anywhere/overview.md)
- [XR-130 XBOX Series X|S 世代](/zh-TW/publishing/certification/xr/xr-130.md)
- [NDA 主題目錄 - Microsoft Learn 線上連結](/zh-TW/nda/nda-topic-directory.md)
