C# 클래스 Framework.Core.Helpers.Images.DefaultImageUtility

Default IImageUtility implementation. Using GDI+ to process images.
상속: IImageUtility
파일 보기 프로젝트 열기: coreframework/Core-Framework

공개 메소드들

메소드 설명
AddWatermark ( String source, String watermark, String destination ) : void

Adds a watermark to source.

ResizeImage ( Image source, String resized, int width, int height ) : void

Resizes the image.

If any of passed width or height is equal to 0 then parameter is excluded from calculations. If both parameters are equal to 0 then original image will serve as thumbnail. The result thumbnail will not be wider than width and will not be higher than height.

ResizeImage ( Stream source, String resized, int width, int height ) : void

Resizes the image.

If any of passed width or height is equal to 0 then parameter is excluded from calculations. If both parameters are equal to 0 then original image will serve as thumbnail. The result thumbnail will not be wider than width and will not be higher than height.

ResizeImage ( String source, String resized, int width, int height ) : void

Resizes the image.

If any of passed width or height is equal to 0 then parameter is excluded from calculations. If both parameters are equal to 0 then original image will serve as thumbnail. The result thumbnail will not be wider than width and will not be higher than height.

비공개 메소드들

메소드 설명
GetEncoderInfo ( String mimeType ) : System.Drawing.Imaging.ImageCodecInfo
GetMimeType ( String fileName ) : String
SaveImage ( Bitmap image, String targetFile ) : void

메소드 상세

AddWatermark() 공개 메소드

Adds a watermark to source.
public AddWatermark ( String source, String watermark, String destination ) : void
source String The source file.
watermark String The watermark file.
destination String The destination file.
리턴 void

ResizeImage() 공개 메소드

Resizes the image.
If any of passed width or height is equal to 0 then parameter is excluded from calculations. If both parameters are equal to 0 then original image will serve as thumbnail. The result thumbnail will not be wider than width and will not be higher than height.
public ResizeImage ( Image source, String resized, int width, int height ) : void
source Image The input image.
resized String Target resized file path.
width int Width of the target.
height int Height of the target.
리턴 void

ResizeImage() 공개 메소드

Resizes the image.
If any of passed width or height is equal to 0 then parameter is excluded from calculations. If both parameters are equal to 0 then original image will serve as thumbnail. The result thumbnail will not be wider than width and will not be higher than height.
public ResizeImage ( Stream source, String resized, int width, int height ) : void
source Stream The input stream.
resized String Target resized file path.
width int Width of the target.
height int Height of the target.
리턴 void

ResizeImage() 공개 메소드

Resizes the image.
If any of passed width or height is equal to 0 then parameter is excluded from calculations. If both parameters are equal to 0 then original image will serve as thumbnail. The result thumbnail will not be wider than width and will not be higher than height.
public ResizeImage ( String source, String resized, int width, int height ) : void
source String Name of the source file.
resized String Name of the target file.
width int Width of the target. If it is equal to 0 then it will not be included into calculations.
height int Height of the target. If it is equal to 0 then it will not be included into calculations.
리턴 void