Andrea Girardi
Andrea Girardi

Reputation: 4427

Video capture on MacOS

i've a problem with openCV library under MacOs 10.4. When I try to execute this row to save some frame captured from webcam

CvVideoWriter *writer = cvCreateVideoWriter(
                             "out.avi", 
                             CV_FOURCC('M','J','P','G'), 
                             fps, 
                             imgSize);

i can see this on stdrr:

OpenCV ERROR: Internal error (Cannot create data reference from file name) in function icvCreateVideoWriter, cvcap_qt.cpp(1291) Terminating the application...

Any idea? If I try to save some images it works fine.

thanks to all! Andrea

Upvotes: 1

Views: 673

Answers (1)

Mark Pim
Mark Pim

Reputation: 10064

Does your program have write permissions in the directory you're running from?

Have you tried putting in an absolute address to, say, your home folder?

What happens if you change the file name, or the FourCC code?

Upvotes: 1

Related Questions