VintaSoft Twain .NET SDK 15.1: Documentation for .NET developer
Vintasoft.WinTwain Namespace / AcquiredImage Class / GetAsBitmap Methods / GetAsBitmap(Boolean) Method
Syntax Exceptions Remarks Requirements SeeAlso
In This Topic
    GetAsBitmap(Boolean) Method (AcquiredImage)
    In This Topic
    Returns this image as System.Drawing.Bitmap object.
    Syntax
    'Declaration
    
    Public Overloads Function GetAsBitmap( _
    ByVal safeBitmap
    Determines that safe bitmap should be returned (16-bpp gray image should be converted to 8-bpp gray image).
    As Boolean _
    ) As System.Drawing.Bitmap
    public System.Drawing.Bitmap GetAsBitmap(
    bool safeBitmap
    )
    public: System.Drawing.Bitmap* GetAsBitmap(
    bool safeBitmap
    )
    public:
    System.Drawing.Bitmap^ GetAsBitmap(
    bool safeBitmap
    )

    Parameters

    safeBitmap
    Determines that safe bitmap should be returned (16-bpp gray image should be converted to 8-bpp gray image).

    Return Value

    This image as System.Drawing.Bitmap.
    Exceptions
    ExceptionDescription
    Thrown if error occurs at the image processing.
    Remarks

    This method should be used if 16-bpp gray image should be returned as 8-bpp gray image because earlier versions of GDI+ cannot work with 16-bit gray images.

    Requirements

    Target Platforms: .NET 9; .NET 8; .NET 7; .NET 6; .NET Framework 4.8, 4.7, 4.6, 4.5, 4.0, 3.5

    See Also