Is it Important to match the codec with the camera quality and extension of file? [closed]
I have used following line of code to the video writer CvVideoWriter* writer = cvCreateVideoWriter("D:\Cam.avi",CV_FOURCC('M','J','P','G'),10,size,1); I dont know whether that codec supports .avi file nor I know my camera has capabibility of producing that quality
FOURCC
first: please use cv::VideoWriter, not CvVideoWriter*
The syntax is correct no errors for the line.I tried with your line also and found no errors.
the c-api got deprecated in 2010, and it will force you using vfw on win. don't use that !