C# Класс Accord.Imaging.Filters.TransformToPolar

Transform rectangle image into circle (to polar coordinates).

The image processing routine does transformation of the source image into circle (polar transformation). The produced effect is similar to GIMP's "Polar Coordinates" distortion filter (or its equivalent in Photoshop).

The filter accepts 8 bpp grayscale and 24/32 bpp color images for processing.

Sample usage:

// create filter TransformToPolar filter = new TransformToPolar( ); filter.OffsetAngle = 0; filter.CirlceDepth = 1; filter.UseOriginalImageSize = false; filter.NewSize = new Size( 200, 200 ); // apply the filter Bitmap newImage = filter.Apply( image );

Initial image:

Result image:

Наследование: BaseTransformationFilter
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
TransformToPolar ( ) : System

Initializes a new instance of the TransformToPolar class.

Защищенные методы

Метод Описание
CalculateNewImageSize ( UnmanagedImage sourceData ) : Size

Calculates new image size.

ProcessFilter ( UnmanagedImage sourceData, UnmanagedImage destinationData ) : void

Process the filter on the specified image.

Описание методов

CalculateNewImageSize() защищенный метод

Calculates new image size.
protected CalculateNewImageSize ( UnmanagedImage sourceData ) : Size
sourceData UnmanagedImage Source image data.
Результат System.Drawing.Size

ProcessFilter() защищенный метод

Process the filter on the specified image.
protected ProcessFilter ( UnmanagedImage sourceData, UnmanagedImage destinationData ) : void
sourceData UnmanagedImage Source image data.
destinationData UnmanagedImage Destination image data.
Результат void

TransformToPolar() публичный метод

Initializes a new instance of the TransformToPolar class.
public TransformToPolar ( ) : System
Результат System