IC Imaging Control C++

OverlayBitmap::setDropOutColor Method

OverlayBitmap::setDropOutColor Method

Sets the dropout color.
bool setDropOutColor( COLORREF color);
Parameter Description

Specifies the color that is used as a dropout color. The color can be specified with the RGB macro. The default dropout color is black (RGB(0,0,0))

Return value:

true on success, false otherwise.


The dropout color determines, which pixels of the overlay bitmap are not copied to the live video. Each dropout colored pixel of the overlay bitmap is not copied on the video sample.

If the video format or the sinktype is an RGB color format such as RGB555, RGB565, RGB24 or RGB32, the dropout color can be specified with the standard RGB macro. For example, if the dropout color is magenta, it can be specified with RGB(255,0,255).

If a monochrome RGB8 video format or sinktype is used, the dropout color can also be specified using the RGB macro. The single values for red, green and blue must be equal to each other: RGB(100,100,100). IC Imaging Control tries to find the nearest color to the specified dropout color in the color palette of the overlay bitmap. If no matching color is found, the video can not be seen. Instead of the live video a only non-transparent bitmap is displayed. If a bitmap is unintentional not transparent, another dropout color can be used.

The default dropout color is black (RGB(0,0,0)). If the overlay bitmap is created, it is filled with this color automatically.


This example demonstrates how to fill the complete overlay bitmap with the color magenta that was set as the current dropout color. This makes the complete overlay bitmap transparent on the video stream.

smart_ptr<DShowLib::OverlayBitmap> pOverlayBitmap;
pOverlayBitmap = m_Grabber.getOverlay( ePP_DEVICE );
pOverlayBitmap->setDropOutColor( RGB(255,0,255));   // Magenta
// Fill the bitmap with the dropout color to make it completely transparent.

See also: OverlayBitmap, OverlayBitmap::fill, OverlayBitmap::getDropOutColor

<< OverlayBitmap

Get in touch with us

About The Imaging Source

Established in 1990, The Imaging Source is one of the leading manufacturers of industrial cameras, frame grabbers and video converters for production automation, quality assurance, logistics, medicine, science and security.

Our comprehensive range of cameras with USB 3.1, USB 3.0, USB 2.0, GigE interfaces and other innovative machine vision products are renowned for their high quality and ability to meet the performance requirements of demanding applications.

Automated Imaging Association ISO 9001:2015 certified

Contact us