Example #1
0
CvCapture* cvCreateFileCapture_FFMPEG( const char* filename )
{
    CvCapture_FFMPEG* capture = new CvCapture_FFMPEG;
    if( capture->open( filename ))
        return capture;
    delete capture;
    return 0;
}
Example #2
0
CvCapture_FFMPEG* cvCreateFileCapture_FFMPEG( const char* filename )
{
    CvCapture_FFMPEG* capture = (CvCapture_FFMPEG*)malloc(sizeof(*capture));
    capture->init();
    if( capture->open( filename ))
        return capture;
    capture->close();
    free(capture);
    return 0;
}
Example #3
0
int main()
{
	CvCapture_FFMPEG c;
	c.init();
	auto success = c.open("rtsp://192.168.3.173/media/video1");

	while (c.grabFrame())
	{
		timespec timespec;
		get_monotonic_time(&timespec);
		printf("got frame %ld\n", timespec.tv_nsec);		;
	}

	return 0;
}