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

# IXtfInputClient::SendGamepadReportEx

> IXtfInputClient::SendGamepadReportEx

# IXtfInputClient::SendGamepadReportEx

コンソールにコントローラーの状態レポートを送信します。

## 構文

```cpp theme={null}
HRESULT SendGamepadReportEx(  
         UINT64 controllerId,  
         GAMEPAD_REPORT_EX report  
)  
```

### パラメーター

*controllerId*   \
型: UINT64

この [IXtfInputClient](/reference/tools/xtf/xtfinput/classes/IXtfInputClient/ixtfinputclient-xtfinput-xbox-windows-t) のデバイス識別子。\
コントローラー ID は、[IXtfInputClient::ConnectGamepad](/reference/tools/xtf/xtfinput/classes/IXtfInputClient/methods/connectgamepad-ixtfinputclient-xtfinput-xbox-windows-m) によって返されるコントローラー ID です。

*report*   \
型: [GAMEPAD\_REPORT\_EX](/reference/tools/xtf/xtfinput/structures/gamepad_report_ex)

レポートするコントローラーの状態。

### 戻り値

型: HRESULT

HRESULT の成功またはエラー コード。

## 解説

**SendGameReportEx** メソッドは、[GAMEPAD\_REPORT\_EX](/reference/tools/xtf/xtfinput/structures/gamepad_report_ex) で表されるコントローラーの状態を、[IXtfInputClient::ConnectGamepad](/reference/tools/xtf/xtfinput/classes/IXtfInputClient/methods/connectgamepad-ixtfinputclient-xtfinput-xbox-windows-m) によって作成された仮想コントローラーに送信します。1 回のボタンの押下と解放をシミュレーションするには、複数の状態を送信する必要があります。ボタン押下をシミュレーションするには、[GAMEPAD\_REPORT\_EX.Buttons](/reference/tools/xtf/xtfinput/structures/gamepad_report_ex) に適切なフラグを設定して **SendGamepadReportEx** を呼び出し、続いて [GAMEPAD\_REPORT\_EX.Buttons](/reference/tools/xtf/xtfinput/structures/gamepad_report_ex) を [GAMEPAD\_BUTTONS::NONE](/reference/tools/xtf/xtfinput/enumerations/GAMEPAD_BUTTONS-typedef-xtfinput-xbox-windows-t) に設定して **SendGamepadReportEx** を再度呼び出します。

**SendGamepadReportEx** は、物理コントローラーからのデータを模倣するために 60 Hz で呼び出すことができます。

## 要件

**ヘッダー:** XtfInput.h

**ライブラリ:** xtfinput.lib

**対応プラットフォーム:** Windows (XBOX コンソール ツール用)

## 関連項目

[XtfInput](/reference/tools/xtf/xtfinput/xtfinput-xbox-microsoft-n)\
[GAMEPAD\_REPORT\_EX](/reference/tools/xtf/xtfinput/structures/gamepad_report_ex)\
[IXtfInputClient::ConnectGamepad](/reference/tools/xtf/xtfinput/classes/IXtfInputClient/methods/connectgamepad-ixtfinputclient-xtfinput-xbox-windows-m)


## Related topics

- [IXtfInputClient::SendGamepadReportWithAudio](/ja-jp/reference/tools/xtf/xtfinput/classes/IXtfInputClient/methods/ixtfinputclient_sendgamepadreportwithaudio.md)
- [IXtfInputClient::SendGamepadReport メソッド](/ja-jp/reference/tools/xtf/xtfinput/classes/IXtfInputClient/methods/sendgamepadreport-ixtfinputclient-xtfinput-xbox-windows-m.md)
- [IXtfInputClient::ConnectGamepad メソッド](/ja-jp/reference/tools/xtf/xtfinput/classes/IXtfInputClient/methods/connectgamepad-ixtfinputclient-xtfinput-xbox-windows-m.md)
- [IXtfInputClient::DisconnectGamepad メソッド](/ja-jp/reference/tools/xtf/xtfinput/classes/IXtfInputClient/methods/disconnectgamepad-ixtfinputclient-xtfinput-xbox-windows-m.md)
- [IXtfInputClient::DisconnectAllGamepads メソッド](/ja-jp/reference/tools/xtf/xtfinput/classes/IXtfInputClient/methods/disconnectallgamepads-ixtfinputclient-xtfinput-xbox-windows-m.md)
