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

# ImageProcessingTools オブジェクトの SmoothImageBySquareAverage メソッド

このメソッドは、正方形近傍で平均化することで画像を平滑化します。これにより、画像内の急激な濃度差が取り除かれます。たとえば、画像にノイズ (ランダムな黒いドットやしみなど) が含まれている場合に有効です。画像上の文字の線が細い場合は、このメソッドを使用しないでください。

> [!WARNING]
>
> このメソッドは、グレー画像およびカラー画像にのみ使用できます。

## 構文

```vb Visual Basic .NET theme={null}
Function SmoothImageBySquareAverage( _
  Image As Image, _
  SquareSize As Integer, _
) As Image
```

```cpp C++ theme={null}
HRESULT SmoothImageBySquareAverage(
  IImage*  Image,
  int      SquareSize,
  IImage** Result
);
```

## パラメーター

**Image**

\[in] この変数は、前処理の対象となる [**Image**](https://docs.abbyy.com/ja/flexi-capture/sdk/api-reference/image.md) オブジェクトを参照します。

**SquareSize**

\[in] この変数は、正方形近傍の一辺の長さを指定します。3 以上の奇数を指定する必要があります。

**Result**

\[out, retval] 出力画像へのアクセスを提供する [**IImage**](https://docs.abbyy.com/ja/flexi-capture/sdk/api-reference/image.md)\*\*\*\*\* ポインター変数へのポインターです。

## 戻り値

このメソッドには固有の戻り値はありません。[ABBYY FlexiCapture SDK 関数の標準の戻り値](https://docs.abbyy.com/ja/flexi-capture/sdk/api-reference/errorcodes.md)のいずれかを返します。

## 関連項目

[**ImageProcessingTools**](https://docs.abbyy.com/ja/flexi-capture/sdk/api-reference/imageprocessingtools.md)
