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

# GetDefaultMSAAParametersX (XBOX One 系列)

> 取得預設的多重取樣消除鋸齒 (MSAA) 參數。

取得預設的多重取樣消除鋸齒 (MSAA) 參數。

## 語法

```cpp theme={null}
HRESULT GetDefaultMSAAParametersX(  
         const DXGI_SAMPLE_DESC* pDesc,  
         D3D12XBOX_MSAA_SAMPLE_LOCATIONS* pSampleLocations,  
         D3D12XBOX_MSAA_CENTROID_PRIORITIES* pCentroidPriorities,  
         D3D12XBOX_MSAA_PARAMETERS* pMSAAParameters  
)  
```

### 參數

*pDesc*   \_In\_\
類型：[DXGI\_SAMPLE\_DESC](https://learn.microsoft.com/en-us/windows/win32/api/dxgicommon/ns-dxgicommon-dxgi_sample_desc)\*

指向 **DXGI\_SAMPLE\_DESC** 結構的指標，指定預定的品質和樣本數目。根據此資訊，函式傳回時會將適當的預設值放入 *pSampleLocations*、*pCentroidProperties* 和 *pMSAAParameters* (如果有將非 null 位址傳入這些參數)。

*pSampleLocations*   \_Inout\_opt\_\
類型：[D3D12XBOX\_MSAA\_SAMPLE\_LOCATIONS\*](/zh-TW/reference/graphics/d3d12_x/structs/d3d12xbox_msaa_sample_locations)

指向 **D3D12XBOX\_MSAA\_SAMPLE\_LOCATIONS** 結構的指標，根據 *pDesc* 中資訊產生的預設 MSAA 樣本位置會放在此處。若要表示不需要預設的 MSAA 樣本位置，請將此指標設定為 null。

*pCentroidPriorities*   \_Inout\_opt\_\
類型：[D3D12XBOX\_MSAA\_CENTROID\_PRIORITIES\*](/zh-TW/reference/graphics/d3d12_x/structs/d3d12xbox_msaa_centroid_priorities)

指向 **D3D12XBOX\_MSAA\_CENTROID\_PRIORITIES** 結構的指標，根據 *pDesc* 中資訊產生的預設 MSAA 質心屬性會放在此處。若要表示不需要預設的 MSAA 質心屬性，請將此指標設定為 null。

*pMSAAParameters*   \_Inout\_opt\_\
類型：[D3D12XBOX\_MSAA\_PARAMETERS\*](/zh-TW/reference/graphics/d3d12_x/structs/d3d12xbox_msaa_parameters)

指向 **D3D12XBOX\_MSAA\_PARAMETERS** 結構的指標，根據 *pDesc* 中資訊產生的預設 MSAA 參數會放在此處。若要表示不需要預設的 MSAA 參數，請將此指標設定為 null。

### 傳回值

類型：HRESULT

其中一個 [Direct3D 12 傳回碼](https://learn.microsoft.com/en-us/windows/desktop/direct3d12/d3d12-graphics-reference-returnvalues)。

## 備註

**DXGI\_SAMPLE\_DESC** 定義於 dxgicommon.h 中。您也可以改用對等的 [XG\_SAMPLE\_DESC](/zh-TW/reference/graphics/xg__NR/structs/xg_sample_desc)。**XG\_SAMPLE\_DESC** 定義於 xg.h 中。

## 需求

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

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

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

## 另請參閱

[ID3D12Device](/zh-TW/reference/graphics/d3d12_x/interfaces/id3d12device/id3d12device)\
[RSSetMSAAParametersX](/zh-TW/reference/graphics/d3d12_x/interfaces/id3d12graphicscommandlist/methods/id3d12graphicscommandlist_rssetmsaaparametersx)


## Related topics

- [FXLOUDNESS_PARAMETERS](/zh-TW/reference/audio/xaudio2xbox/structs/fxloudness_parameters.md)
- [GetRequiredParameterResourceSize](/zh-TW/reference/graphics/d3d12/interfaces/id3d12metacommand/methods/id3d12metacommand_getrequiredparameterresourcesize_public.md)
- [XUserGetDefaultAudioEndpointUtf16](/zh-TW/reference/system/xuser/functions/xusergetdefaultaudioendpointutf16.md)
- [PIXCaptureParameters](/zh-TW/reference/tools/pix3/structs/pixcaptureparameters.md)
- [XUserDefaultAudioEndpointKind](/zh-TW/reference/system/xuser/enums/xuserdefaultaudioendpointkind.md)
