LEADTOOLS Image File Support (Leadtools.Codecs assembly) Send comments on this topic. | Back to Introduction - All Topics | Help Version 17.0.3.29
MarkersSupported Method
See Also 
Leadtools.Codecs Namespace > RasterCodecs Class : MarkersSupported Method



format
The Leadtools.RasterImageFormat to check
format
The Leadtools.RasterImageFormat to check
Checks whether the given file format supports markers

Syntax

Visual Basic (Declaration) 
Public Shared Function MarkersSupported( _
   ByVal format As RasterImageFormat _
) As Boolean
Visual Basic (Usage)Copy Code
Dim format As RasterImageFormat
Dim value As Boolean
 
value = RasterCodecs.MarkersSupported(format)
C# 
public static bool MarkersSupported( 
   RasterImageFormat format
)
C++/CLI 
public:
static bool MarkersSupported( 
   RasterImageFormat format
) 

Parameters

format
The Leadtools.RasterImageFormat to check

Return Value

true if the format supports markers; otherwise it is false.

Example

For an example, refer to RasterCodecs.ReadTags.

Remarks

This is a helper method that can be used to detect if a certain raster file format supports markers. For example, ReadMarkers(String) can be used to read the markers stored in a file. If the file format supports markers, such as EXIF, then these methods will successfully return the markers stored.

However, if the format does not support markers, such as BMP, an exception will be thrown by the RasterCodecs objects. You can use MarkersSupported to check if the file supports markers and only call the read methods if the return value is true.

Note that the RasterCodecs option uses this method internally to check if the file supports markers when the CodecsLoadOptions.Markers is set to true and only read the file marekrs if the file format supports them.

Requirements

Target Platforms: Silverlight, Windows XP, Windows Server 2003 family, Windows Server 2008 family, Windows Vista, Windows 7, MAC OS/X (Intel Only)

See Also