C# Класс BlogEngine.Core.FileSystem.Image

image specific class, will contain the extra methods and properties of an image
Наследование: System.IO.File
Показать файл Открыть проект

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

Метод Описание
CropImage ( int x, int y, int width, int height ) : Image

Crops an image by giving the crop start x & y co-ordinates and then the height & width to crop to. Making a perfect rectangle of the crop area.

Image ( ) : System

ctor, property free constructor, initiates the this.Image(file) passing in a null file reference

Image ( File obj ) : System

ctor, copys all the properties from the file object into the new object.

ModifyImage ( ) : Image

accepts change requests for an image for rotate & flip

ResizeImage ( Size newSize ) : Image

resizes the image to a new size. The image will be replaced

ResizeImage ( decimal Percent ) : Image

resizes the image to a new size based on a percentage

This may not be exactly to the percent as we must maintain aspect ratios.

ResizeImageThumbnail ( int MaxSize, byte originalContents ) : byte[]

Приватные методы

Метод Описание
ArrayToBmp ( byte inArray ) : Bitmap

converts a byte array to a bitmap

BmpToArray ( Bitmap bmp ) : byte[]

converts a bitmap to an array

resizeImage ( System imgToResize, Size size ) : Image

resizes an image to specific size

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

CropImage() публичный Метод

Crops an image by giving the crop start x & y co-ordinates and then the height & width to crop to. Making a perfect rectangle of the crop area.
public CropImage ( int x, int y, int width, int height ) : Image
x int the x co-ordinate
y int the y co-ordinate
width int the width to crop
height int the height to crop
Результат Image

Image() публичный Метод

ctor, property free constructor, initiates the this.Image(file) passing in a null file reference
public Image ( ) : System
Результат System

Image() публичный Метод

ctor, copys all the properties from the file object into the new object.
public Image ( File obj ) : System
obj System.IO.File
Результат System

ModifyImage() публичный Метод

accepts change requests for an image for rotate & flip
public ModifyImage ( ) : Image
Результат Image

ResizeImage() публичный Метод

resizes the image to a new size. The image will be replaced
public ResizeImage ( Size newSize ) : Image
newSize System.Drawing.Size the new Size for the image
Результат Image

ResizeImage() публичный Метод

resizes the image to a new size based on a percentage
This may not be exactly to the percent as we must maintain aspect ratios.
public ResizeImage ( decimal Percent ) : Image
Percent decimal
Результат Image

ResizeImageThumbnail() публичный статический Метод

public static ResizeImageThumbnail ( int MaxSize, byte originalContents ) : byte[]
MaxSize int
originalContents byte
Результат byte[]