IC Imaging Control C++



The FrameNotificationSink is a sink type that gives direct access to image data as it becomes available to the application, before even being copied into a dedicated image buffer.

This sink is most useful when the application needs to copy the image data into buffers of a third-party image processing library, because it it possible to avoid a copy operation.

A simple setup example is shown here:

class listener : public FrameNotificationSinkListener
    virtual void sinkConnected( const FrameTypeInfo& frameType ) override   {}
    virtual void sinkDisconnected() override                                {}
    virtual void frameReceived( IFrame& frame ) override
        // do something with frame
listener listener_instance;
tFrameNotificationSinkPtr pSink = FrameNotificationSink::create( listener_instance );
grabber.setSinkType( pSink );

The sink creation function create is passed an instance of a class derived from FrameNotificationSinkListener. When images are received from the device, the listener's frameReceived method is called.

Because there is no buffering in the sink, it is imperative for the code inside the frameReceived function to return quickly. There is no guarantee for it to be called for every frame if the system load is high, or the function takes a long time to complete relative to the frame interval.

A more complex example implementing ZeroCopy is located in %TOPLEVEL%\Samples\VC\ZeroCopyThirdParty.


Header File: tisudshl.h
Namespace: DShowLib
Introduced in version 3.5




Method Description

Creates a new FrameNotificationSink.


Retrieves the FrameTypeInfo of the current connection.


Returns if the sink is currently connected.

<< Classes

Get in touch with us

About The Imaging Source

Established in 1990, The Imaging Source is one of the leading manufacturers of industrial cameras, video converters and embedded vision components for factory automation, quality assurance, medicine, science, security and a variety of other markets.

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

ISO 9001:2015 certified MVTEC | Edge AI + Vision Alliance | EMVA

Contact us