Click or drag to resize
Accord.NET (logo)

ImageDecoderDecodeFromFile Method (String, ImageInfo)

Decode first frame for the specified file.

Namespace:  Accord.Imaging.Formats
Assembly:  Accord.Imaging (in Accord.Imaging.dll) Version: 3.8.0
Syntax
public static Bitmap DecodeFromFile(
	string fileName,
	out ImageInfo imageInfo
)
Request Example View Source

Parameters

fileName
Type: SystemString
File name to read image from.
imageInfo
Type: Accord.Imaging.FormatsImageInfo
Information about the decoded image.

Return Value

Type: Bitmap
Return decoded image. In the case if file format support multiple frames, the method return the first frame.
Remarks

The method uses table of registered image decoders to find the one, which should be used for the specified file. If there is not appropriate decoder found, the method uses default .NET's image decoding routine (see FromFile(String)).

See Also