ImageGear for C and C++ on Windows v20.5 - Updated
IG_gui_ip_color_reduce_dlg
API Reference Guide > GUI Component API Reference > GUI Component Functions Reference > Image Processing Functions > IG_gui_ip_color_reduce_dlg

This function shows the dialog that allows you to reduce the number of bits per pixel for the original image using different methods.

Declaration:

 
Copy Code
BOOL ACCUAPI IG_gui_ip_color_reduce_dlg (
        HWND hWnd, 
        LPAT_IGGUI_IP_COLOR_REDUCE lpIpColorReduceData
);

Arguments:

Name Type Description
hWnd HWND A handle of the parent window.
lpIpColorReduceData LPAT_IGGUI_IP_COLOR_REDUCE A pointer to the AT_IGGUI_IP_COLOR_REDUCE structure.

Return Value:

If the user specifies parameters and clicks the OK button, the return value is non-zero. If the user cancels or closes the dialog box or an error occurs, the return value is zero.

Supported Raster Image Formats:

Depending on the reduction options:

Sample:

Color

Example:

 
Copy Code
#include "IG_gui_common.h"
AT_IGGUI_IP_COLOR_REDUCE IpColorReduce;
IpColorReduce.cbSize = sizeof (IpColorReduce);
IpColorReduce.hWnd = hWnd;
IpColorReduce.hIGear = hIGear;
IpColorReduce.nReduceType = IG_IGGUI_IP_COLOR_REDUCE_BAYER;
if (IG_gui_ip_color_reduce_dlg (hWnd, &IpColorReduce))
{
InvalidateRect(hWnd, NULL, FALSE);
        UpdateWindow(hWnd);
}
Is this page helpful?
Yes No
Thanks for your feedback.