ImageGear Professional DLL v17.1 for Windows Accusoft
IG_ISIS_drv_read_gamma_file
Send Feedback  
ImageGear Professional DLL v17.1 for Windows > API Reference Guide > ISIS Component API Reference > ISIS Component Functions Reference > Driver Communication and Setup Functions > IG_ISIS_drv_read_gamma_file

Glossary Item Box

Obtain a user downloadable gamma table.

Declaration:

  Copy Code
AT_ERRCOUNT ACCUAPI IG_ISIS_drv_read_gamma_file(
        HISISDRV hDriver,
        AT_MODE nTag,
        HWND hWnd
);

Arguments:

hDriver The handle to the driver.
nTag Specifies the tag in which to store the downloadable gamma table. For scanners that support downloadable gamma tables, this tag should be set to one of the IG_ISIS_TAG_GAMMA_TABLEn tags.
hWnd A handle to the parent window.

Return Value:

Returns the number of ImageGear errors that occurred during this function call. If there are no errors, the return value is IGE_SUCCESS.

Supported Raster Image Formats:

This function does not process image pixels.

Remarks:

The IG_ISIS_drv_read_gamma_file function prompts the application user for a gamma file and then uses the file data to fill in a downloadable gamma correction table for the scanner.

Before calling IG_ISIS_drv_read_gamma_file, make sure the current scanner supports user downloadable gamma tables by querying the existence of the IG_ISIS_TAG_GAMMA_TABLEn tags. If the scanner supports one downloadable gamma table, then IG_ISIS_TAG_GAMMA_TABLE1 will be available. If the scanner supports more than one gamma table, then there will be n number such tags available.

Use IG_ISIS_drv_read_gamma_file to prompt the application user to choose a gamma file from a File Open dialog, and then set nTag to contain the gamma table read from the file. IG_ISIS_drv_read_gamma_file does not automatically forward the gamma table down to the scanner. If the user then selects to use the downloaded gamma table as a parameter for scanning, call IG_ISIS_drv_send_gammato send the gamma curve data to the scanner hardware.

The function will check for file format validity. However, there is no guarantee that a selected gamma table is valid. If scanning occurs while an invalid gamma correction curve is in use, unpredicatable program behavior may result.

The File Open dialog displayed by IG_ISIS_drv_read_gamma_file will automatically look for files in the current directory that ends in the extension .PXG. However, it can open any ASCII text file that specifies the gamma table using the standard format. See IG_ISIS_TAG_GAMMA_TABLEn for a discussion on the standard gamma correction table format.

See Also:

IG_ISIS_drv_send_dither

IG_ISIS_drv_read_gamma_file

IG_ISIS_drv_send_gamma

IG_ISIS_TAG_GAMMA

IG_ISIS_TAG_GAMMA_TABLEn

©2012. Accusoft Corporation. All Rights Reserved.