Enum ResizeType

Enum ResizeType

名称: Aspose.Imaging アセンション: Aspose.Imaging.dll (25.4.0)

リサイクルタイプを指定します。

public enum ResizeType

Fields

AdaptiveResample = 8

適応アルゴリズムを使用して、重量化および混合理性機能および lanczos3 インターポレーションアルゴリズムに基づいています。

Bell = 16

ベル・インターポレーション方法

BilinearResample = 9

画像プレフィルタリングは、必要に応じて、再サンプル前に騒音を取り除くことが許可されます。

CatmullRom = 11

Catmull-Rom キューブ・インターポレーション・メソッド

CenterToCenter = 5

新しいイメージの中心は、オリジナルのイメージの中心と一致します。

CubicBSpline = 13

CubicBSpline キューブインターポレーション方法

CubicConvolution = 12

CUBIC CONVOLUTION インターポレーション方法

HighQualityResample = 10

高品質のサンプル

LanczosResample = 6

ランチョスアルゴリズムをA=3で使用するサンプル。

LeftBottomToLeftBottom = 4

新しい画像の左下点は、オリジナルの画像の左下点と一致します。

LeftTopToLeftTop = 1

新しい画像の左上点は、オリジナルの画像の左上点と一致します。

Mitchell = 14

ミッチェルキューブインターポレーション方法

NearestNeighbourResample = 7

最寄りの近隣アルゴリズムを使用してリサンプルします。

None = 0

ピクセルはリサイクル作業中に保存されません。

RightBottomToRightBottom = 3

新しい画像の右下点は、オリジナルの画像の右下点と一致します。

RightTopToRightTop = 2

新しい画像の正しいトップポイントは、オリジナルの画像の正しいトップポイントと一致します。

SinC = 15

シンク(Lanczos3)キューブインターポレーション方法

Examples

特定のリサイクルタイプを使用して画像をリサイクルします。

using (var image = Image.Load("Photo.jpg"))
                                                   {
                                                       image.Resize(640, 480, ResizeType.CatmullRom);
                                                       image.Save("ResizedPhoto.jpg");

                                                       image.Resize(1024, 768, ResizeType.CubicConvolution);
                                                       image.Save("ResizedPhoto2.jpg");

                                                       var resizeSettings = new ImageResizeSettings
                                                       {
                                                           Mode = ResizeType.CubicBSpline,
                                                           FilterType = ImageFilterType.SmallRectangular
                                                       };

                                                       image.Resize(800, 800, resizeSettings);
                                                       image.Save("ResizedPhoto3.jpg");
                                                   }

この例では、画像を積み重ね、さまざまなリサイクル方法を使用してリサイクルします。

string dir = "c:\\temp\\";

                                                                                     using (Aspose.Imaging.Image image = Aspose.Imaging.Image.Load(dir + "sample.gif"))
                                                                                     {
                                                                                         // Scale up by 2 times using Nearest Neighbour resampling.
                                                                                         image.Resize(image.Width* 2, image.Height* 2, Aspose.Imaging.ResizeType.NearestNeighbourResample);
                                                                                         image.Save(dir + "upsample.nearestneighbour.gif");
                                                                                     }

                                                                                     using (Aspose.Imaging.Image image = Aspose.Imaging.Image.Load(dir + "sample.gif"))
                                                                                     {
                                                                                         // Scale down by 2 times using Nearest Neighbour resampling.
                                                                                         image.Resize(image.Width / 2, image.Height / 2, Aspose.Imaging.ResizeType.NearestNeighbourResample);
                                                                                         image.Save(dir + "downsample.nearestneighbour.gif");
                                                                                     }

                                                                                     using (Aspose.Imaging.Image image = Aspose.Imaging.Image.Load(dir + "sample.gif"))
                                                                                     {
                                                                                         // Scale up by 2 times using Bilinear resampling.
                                                                                         image.Resize(image.Width* 2, image.Height* 2, Aspose.Imaging.ResizeType.BilinearResample);
                                                                                         image.Save(dir + "upsample.bilinear.gif");
                                                                                     }

                                                                                     using (Aspose.Imaging.Image image = Aspose.Imaging.Image.Load(dir + "sample.gif"))
                                                                                     {
                                                                                         // Scale down by 2 times using Bilinear resampling.
                                                                                         image.Resize(image.Width / 2, image.Height / 2, Aspose.Imaging.ResizeType.BilinearResample);
                                                                                         image.Save(dir + "downsample.bilinear.gif");
                                                                                     }
 日本語