Table of Contents

Method Retrieve

Namespace
OpenCvSharp
Assembly
OpenCvSharp.dll

Retrieve(OutputArray, int)

Decodes and returns the grabbed video frame.

The method decodes and returns the just grabbed frame. If no frames has been grabbed (camera has been disconnected, or there are no more frames in video file), the method returns false and the function returns an empty image (with %cv::Mat, test it with Mat::empty()).

public bool Retrieve(OutputArray image, int flag = 0)

Parameters

image OutputArray

the video frame is returned here. If no frames has been grabbed the image will be empty.

flag int

it could be a frame index or a driver specific flag

Returns

bool

Retrieve(OutputArray, CameraChannels)

Decodes and returns the grabbed video frame.

The method decodes and returns the just grabbed frame. If no frames has been grabbed (camera has been disconnected, or there are no more frames in video file), the method returns false and the function returns an empty image (with %cv::Mat, test it with Mat::empty()).

public bool Retrieve(OutputArray image, CameraChannels streamIdx)

Parameters

image OutputArray

the video frame is returned here. If no frames has been grabbed the image will be empty.

streamIdx CameraChannels

non-zero streamIdx is only valid for multi-head camera live streams

Returns

bool

Retrieve(Mat, int)

Decodes and returns the grabbed video frame.

The method decodes and returns the just grabbed frame. If no frames has been grabbed (camera has been disconnected, or there are no more frames in video file), the method returns false and the function returns an empty image (with %cv::Mat, test it with Mat::empty()).

public bool Retrieve(Mat image, int flag = 0)

Parameters

image Mat

the video frame is returned here. If no frames has been grabbed the image will be empty.

flag int

it could be a frame index or a driver specific flag

Returns

bool

Retrieve(Mat, CameraChannels)

Decodes and returns the grabbed video frame.

The method decodes and returns the just grabbed frame. If no frames has been grabbed (camera has been disconnected, or there are no more frames in video file), the method returns false and the function returns an empty image (with %cv::Mat, test it with Mat::empty()).

public bool Retrieve(Mat image, CameraChannels streamIdx)

Parameters

image Mat

the video frame is returned here. If no frames has been grabbed the image will be empty.

streamIdx CameraChannels

non-zero streamIdx is only valid for multi-head camera live streams

Returns

bool