Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

Thread Subject:
Error when trying to open AVI video

Subject: Error when trying to open AVI video

From: mpalmer@lmi.net

Date: 6 Jul, 2009 02:55:05

Message: 1 of 1

I wrote a few lines of code that read an AVI video. It works on some AVIs but not on others and I don't know why. In both instances number of frames is always a large #, so they're there, they just aren't being read.

Code:

mmrx = mmreader('movie.avi', 'tag', 'mrxx');
numframes = get(mmrx, 'NumberOfFrames');
vrxx = read(mmrx, [1 10]];

For the problem file, the error I get is

numframes = 1196718
Warning: The end of file was reached before the requested frames were read completely. Frames 1 through 1 were returned.

Why is this happening, when it sees the correct number of frames in numframes??? Both the files that work and those that don't are Divx. I am on a Mac.

Tags for this Thread

No tags are associated with this thread.

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Contact us