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

# GetDevice

> IGameInputReading::GetDevice

# IGameInputReading::GetDevice

IGameInputReading に関連付けられているデバイスを取得します。

## 構文

```cpp theme={null}
void GetDevice(
    IGameInputDevice** device
);
```

### パラメーター

*device*   \_Outptr\_\
型: IGameInputDevice\*\*

IGameInputReading に関連付けられているデバイスです。

### 戻り値

型: void

## 解説

このメソッドを使用して、デバイスのメーカーとその機能に関する情報を取得します。たとえば、デバイス上のボタン、配列、軸の数を知る必要がある場合があります。これは、開発者が作成したバッファーを必要とする [IGameInputReading::GetGamepadState](https://docs.xbox.com/ja-jp/reference/input/gameinput/interfaces/igameinputreading/methods/igameinputreading_getgamepadstate.md) などの多くの Get\*State 関数に適切なサイズのバッファーを渡す必要がある際に重要になります。

## 要件

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

[Input API の概要](https://docs.xbox.com/ja-jp/build/core-features/common/input/overviews/input-overview.md)\
[IGameInputReading](https://docs.xbox.com/ja-jp/reference/input/gameinput/interfaces/igameinputreading/igameinputreading.md)\
[IGameInputReading::GetGamepadState](https://docs.xbox.com/ja-jp/reference/input/gameinput/interfaces/igameinputreading/methods/igameinputreading_getgamepadstate.md)

## バージョン履歴

| バージョン | 変更点 |
| - | - |
| **v0** | 導入。 |


## Related topics

- [GetDevice](https://docs.xbox.com/ja-jp/reference/graphics/d3d12/interfaces/id3d12devicechild/methods/id3d12devicechild_getdevice_public.md)
- [PartyNetwork::GetDevices](https://docs.xbox.com/ja-jp/services/playfab/multiplayer/networking/reference/classes/PartyNetwork/methods/partynetwork_getdevices.md)
- [PartyEndpoint::GetDevice](https://docs.xbox.com/ja-jp/services/playfab/multiplayer/networking/reference/classes/PartyEndpoint/methods/partyendpoint_getdevice.md)
- [IGameInputForceFeedbackEffect::GetDevice](https://docs.xbox.com/ja-jp/reference/input/gameinput/interfaces/igameinputforcefeedbackeffect/methods/igameinputforcefeedbackeffect_getdevice.md)
- [PartyChatControl::GetDevice](https://docs.xbox.com/ja-jp/services/playfab/multiplayer/networking/reference/classes/PartyChatControl/methods/partychatcontrol_getdevice.md)
