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

# PIXGpuCaptureNextFrame (XBOX One 系列)

> 擷取 GPU 的下一個畫面資料。

從 GPU 擷取下一個畫面的資料。

<a id="syntaxSection" />

## 語法

```cpp theme={null}
HRESULT PIXGpuCaptureNextFrame(  
         UINT Flags,  
         LPCWSTR lpOutputFileName  
)  
```

<a id="parametersSection" />

### 參數

*Flags*   \_In\_\
類型：UINT

用於控制此 PIX GPU 擷取的旗標，為 [D3D12XBOX\_PIX\_CAPTURE\_FLAGS](/zh-TW/reference/graphics/d3d12_x/enums/d3d12xbox_pix_capture_flags) 列舉常數的位元 OR 組合。

*lpOutputFileName*   \_In\_z\_\
類型：LPCWSTR

用來儲存資料的檔案名稱。

<a id="retvalSection" />

### 傳回值

類型：HRESULT

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

<a id="remarksSection" />

## 備註

此函式會執行 PIX GPU 擷取，將下一個單一畫面擷取至主機上的檔案以供稍後分析，而不需呼叫 [PIXGpuBeginCapture](/zh-TW/reference/graphics/d3d12_x/interfaces/id3d12commandqueue/methods/id3d12commandqueue_pixgpubegincapture) 或 [PIXGpuEndCapture](/zh-TW/reference/graphics/d3d12_x/interfaces/id3d12commandqueue/methods/id3d12commandqueue_pixgpuendcapture)。此函式擷取的資料會以 .xpix 檔案的形式儲存在主機上。您必須先將檔案複製到開發電腦，才能進行分析。如需 PIX GPU 擷取的詳細資訊，請參閱 [PIX GPU 擷取](https://learn.microsoft.com/en-us/gaming/gdk/_content/gc/tools-console/xbox-tools-and-apis/pix/gpu/pix-gpu-capture)。

<a id="requirementsSection" />

## 需求

**標頭：** d3d12\_x.h

**程式庫：** d3d12\_x.lib

**支援的平台：** XBOX One 系列

<a id="seealsoSection" />

## 另請參閱

[ID3D12CommandQueue](/zh-TW/reference/graphics/d3d12_x/interfaces/id3d12commandqueue/id3d12commandqueue)\
[d3d12\_x](/zh-TW/reference/graphics/d3d12_x/d3d12_x_members)


## Related topics

- [PIX GPU Trace captures on XBOX Series consoles](/tools/tools-console/pix/gpu-trace/index.md)
- [XAppCaptureVideoCaptureSettings](/zh-CN/reference/system/xappcapture/structs/xappcapturevideocapturesettings.md)
- [PIX GPU capture and performance analysis](/tools/tools-console/pix/gpu/index.md)
- [PIXCaptureParameters](/zh-CN/reference/tools/pix3/structs/pixcaptureparameters.md)
- [XAppCaptureGetVideoCaptureSettings](/zh-CN/reference/system/xappcapture/functions/xappcapturegetvideocapturesettings.md)
