C# Class ImageMagick.MagickNET

Class that can be used to initialize Magick.NET.
显示文件 Open project: dlemstra/Magick.NET Class Usage Examples

Public Methods

Method Description
GetFormatInformation ( FileInfo file ) : MagickFormatInfo

Returns the format information of the specified format based on the extension of the file.

GetFormatInformation ( MagickFormat format ) : MagickFormatInfo

Returns the format information of the specified format.

GetFormatInformation ( string fileName ) : MagickFormatInfo

Returns the format information of the specified format based on the extension of the file. If that fails the format will be determined by 'pinging' the file.

Initialize ( string path ) : void

Adds the specified path to the environment path. You should place the ImageMagick xml files in that directory.

SetGhostscriptDirectory ( string path ) : void

Sets the directory that contains the Ghostscript file gsdll32.dll / gsdll64.dll.

SetGhostscriptFontDirectory ( string path ) : void

Sets the directory that contains the Ghostscript font files.

SetLogEvents ( LogEvents events ) : void

Set the events that will be written to the log. The log will be written to the Log event and the debug window in VisualStudio. To change the log settings you must use a custom log.xml file.

SetRandomSeed ( int seed ) : void

Sets the pseudo-random number generator secret key.

SetTempDirectory ( string path ) : void

Sets the directory that will be used when ImageMagick does not have enough memory for the pixel cache.

Private Methods

Method Description
CheckImageMagickFiles ( string path ) : void
OnLog ( UIntPtr type, IntPtr text ) : void
SetLogEvents ( ) : void

Method Details

GetFormatInformation() public static method

Returns the format information of the specified format based on the extension of the file.
public static GetFormatInformation ( FileInfo file ) : MagickFormatInfo
file System.IO.FileInfo The file to get the format for.
return MagickFormatInfo

GetFormatInformation() public static method

Returns the format information of the specified format.
public static GetFormatInformation ( MagickFormat format ) : MagickFormatInfo
format MagickFormat The image format.
return MagickFormatInfo

GetFormatInformation() public static method

Returns the format information of the specified format based on the extension of the file. If that fails the format will be determined by 'pinging' the file.
public static GetFormatInformation ( string fileName ) : MagickFormatInfo
fileName string The name of the file to get the format for.
return MagickFormatInfo

Initialize() public static method

Adds the specified path to the environment path. You should place the ImageMagick xml files in that directory.
public static Initialize ( string path ) : void
path string The path that contains the ImageMagick xml files.
return void

SetGhostscriptDirectory() public static method

Sets the directory that contains the Ghostscript file gsdll32.dll / gsdll64.dll.
public static SetGhostscriptDirectory ( string path ) : void
path string The path of the Ghostscript directory.
return void

SetGhostscriptFontDirectory() public static method

Sets the directory that contains the Ghostscript font files.
public static SetGhostscriptFontDirectory ( string path ) : void
path string The path of the Ghostscript font directory.
return void

SetLogEvents() public static method

Set the events that will be written to the log. The log will be written to the Log event and the debug window in VisualStudio. To change the log settings you must use a custom log.xml file.
public static SetLogEvents ( LogEvents events ) : void
events LogEvents The events that will be logged.
return void

SetRandomSeed() public static method

Sets the pseudo-random number generator secret key.
public static SetRandomSeed ( int seed ) : void
seed int The secret key.
return void

SetTempDirectory() public static method

Sets the directory that will be used when ImageMagick does not have enough memory for the pixel cache.
public static SetTempDirectory ( string path ) : void
path string The path where temp files will be written.
return void