Class ThumbnailExtractor

    Definition

    Namespace:
    Tizen.Multimedia.Util
    Assembly:
    Tizen.Multimedia.Util.dll

    Provides the ability to extract the thumbnail from media files.

    public static class ThumbnailExtractor
    Inheritance
    object
    ThumbnailExtractor

    Methods

    View Source

    ExtractAsync(string, CancellationToken)

    Extracts the thumbnail for the given media with the specified path.

    Declaration
    public static Task<ThumbnailExtractionResult> ExtractAsync(string path, CancellationToken cancellationToken)
    Parameters
    Type Name Description
    string path

    The path of the media file to extract the thumbnail.

    System.Threading.CancellationToken cancellationToken

    The token to stop the operation.

    Returns
    Type Description
    System.Threading.Tasks.Task<TResult><ThumbnailExtractionResult>

    A task that represents the asynchronous extracting operation.

    Remarks

    The size of the thumbnail will be the default size(320x240).

    Exceptions
    Type Condition
    System.ArgumentNullException

    path is null.

    System.IO.FileNotFoundException

    path does not exist.

    System.InvalidOperationException

    An internal error occurs.

    System.UnauthorizedAccessException

    The caller does not have required privilege for accessing the path.

    FileFormatException

    The specified file is not supported.

    View Source

    ExtractAsync(string, Size, CancellationToken)

    Extracts the thumbnail for the given media with the specified path and size.

    Declaration
    public static Task<ThumbnailExtractionResult> ExtractAsync(string path, Size size, CancellationToken cancellationToken)
    Parameters
    Type Name Description
    string path

    The path of the media file to extract the thumbnail.

    Size size

    The size of the thumbnail.

    System.Threading.CancellationToken cancellationToken

    The token to stop the operation.

    Returns
    Type Description
    System.Threading.Tasks.Task<TResult><ThumbnailExtractionResult>

    A task that represents the asynchronous extracting operation.

    Remarks

    If the width is not a multiple of 8, it can be changed by the inner process.
    The width will be a multiple of 8 greater than the set value.

    Exceptions
    Type Condition
    System.ArgumentNullException

    path is null.

    System.IO.FileNotFoundException

    path does not exist.

    System.InvalidOperationException

    An internal error occurs.

    System.UnauthorizedAccessException

    The caller does not have required privilege for accessing the path.

    System.ArgumentOutOfRangeException

    The width or the height of size is less than or equal to zero.

    FileFormatException

    The specified file is not supported.

    View Source

    ExtractAsync(string, Size)

    Extracts the thumbnail for the given media with the specified path and size.

    Declaration
    public static Task<ThumbnailExtractionResult> ExtractAsync(string path, Size size)
    Parameters
    Type Name Description
    string path

    The path of the media file to extract the thumbnail.

    Size size

    The size of the thumbnail.

    Returns
    Type Description
    System.Threading.Tasks.Task<TResult><ThumbnailExtractionResult>

    A task that represents the asynchronous extracting operation.

    Remarks

    If the width is not a multiple of 8, it can be changed by the inner process.
    The width will be a multiple of 8 greater than the set value.

    Exceptions
    Type Condition
    System.ArgumentNullException

    path is null.

    System.IO.FileNotFoundException

    path does not exist.

    System.InvalidOperationException

    An internal error occurs.

    System.UnauthorizedAccessException

    The caller does not have required privilege for accessing the path.

    System.ArgumentOutOfRangeException

    The width or the height of size is less than or equal to zero.

    FileFormatException

    The specified file is not supported.

    View Source

    ExtractAsync(string)

    Extracts the thumbnail for the given media with the specified path.

    Declaration
    public static Task<ThumbnailExtractionResult> ExtractAsync(string path)
    Parameters
    Type Name Description
    string path

    The path of the media file to extract the thumbnail.

    Returns
    Type Description
    System.Threading.Tasks.Task<TResult><ThumbnailExtractionResult>

    A task that represents the asynchronous extracting operation.

    Remarks

    The size of the thumbnail will be the default size (320x240).

    Exceptions
    Type Condition
    System.ArgumentNullException

    path is null.

    System.IO.FileNotFoundException

    path does not exist.

    System.InvalidOperationException

    An internal error occurs.

    System.UnauthorizedAccessException

    The caller does not have required privilege for accessing the path.

    FileFormatException

    The specified file is not supported.

    • View Source
    Back to top Copyright © 2016-2024 Samsung
    Generated by DocFX