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

# SetShapeEqCompCompressorMode

> SetShapeEqCompCompressorMode

# SetShapeEqCompCompressorMode

コンプレッション モードを設定します。

## Syntax

```cpp theme={null}
HRESULT SetShapeEqCompCompressorMode(  
         SHAPE_EQCOMP_CONTEXT* context,  
         SHAPE_EQCOMP_COMPRESSOR_MODE mode  
)  
```

### パラメーター

*context*   \_Inout\_\
型: [SHAPE\_EQCOMP\_CONTEXT\*](https://docs.xbox.com/ja-jp/reference/audio/shapeeqcompcontext/structs/shape_eqcomp_context.md)

SHAPE\_EQCOMP\_CONTEXT オブジェクトへのポインター。

*mode*   \
型: [SHAPE\_EQCOMP\_COMPRESSOR\_MODE](https://docs.xbox.com/ja-jp/reference/audio/shapeeqcompcontext/enums/shape_eqcomp_compressor_mode.md)

SHAPE\_EQCOMP\_COMPRESSOR\_MODE 列挙型のメンバー。

### 戻り値

型: HRESULT

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

## 解説

ノーマル モードでは、入力レベルは瞬時値であり、コンプレッションはサンプルごとに計算されます。RMS モードでは、現在の入力サンプルの絶対レベルではなく、直近 128 サンプルの移動平均 (RMS 値の近似を表す) が入力レベルとして使用されます。(移動平均は RMS 値の近似です。)

詳細については、[SHAPE の概要](https://docs.xbox.com/ja-jp/build/console-features/audio/overviews/shape-overview.md)の[イコライゼーションおよびコンプレッション](https://docs.xbox.com/ja-jp/build/console-features/audio/overviews/shape-overview.md#ID4ECF)を参照してください。

## 要件

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

**対応プラットフォーム:** XBOX One ファミリ本体および XBOX Series 本体

## 関連項目

[GetShapeEqCompCompressorMode](https://docs.xbox.com/ja-jp/reference/audio/shapeeqcompcontext/functions/getshapeeqcompcompressormode.md)\
[ShapeEqCompContext](https://docs.xbox.com/ja-jp/reference/audio/shapeeqcompcontext/shapeeqcompcontext_members.md)


## Related topics

- [GetShapeEqCompCompressorMode](https://docs.xbox.com/ja-jp/reference/audio/shapeeqcompcontext/functions/getshapeeqcompcompressormode.md)
- [SHAPE_EQCOMP_COMPRESSOR_MODE](https://docs.xbox.com/ja-jp/reference/audio/shapeeqcompcontext/enums/shape_eqcomp_compressor_mode.md)
- [ShapeEqCompContext](https://docs.xbox.com/ja-jp/reference/audio/shapeeqcompcontext/shapeeqcompcontext_members.md)
- [SetShapeEqCompEnableCompressor](https://docs.xbox.com/ja-jp/reference/audio/shapeeqcompcontext/functions/setshapeeqcompenablecompressor.md)
- [GetShapeEqCompEnableCompressor](https://docs.xbox.com/ja-jp/reference/audio/shapeeqcompcontext/functions/getshapeeqcompenablecompressor.md)
