Uses the mmread utility to count the number of frames in a .asf video file.
Updated 9 Dec 2011

View License

If you want to read in the last frame of a .asf file using mmread(), you can read in the entire file, but this can be very slow or cause Matlab to run out of memory.

You can read in only the last frame using mmread(), but to do this, you need to know the number of frames in the file.

mmcount() counts the number of frames in the file, after which mmread() can be used to read in the final frame. The time taken to count the frames and read in the final frame is much less than the time taken to read in the entire file with mmread().

mmcount() makes use of mmread() itself to do the counting.

Cite As

Kevin Bartlett (2024). mmcount.m (, MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R2011a
Compatible with any release
Platform Compatibility
Windows macOS Linux

Inspired by: mmread

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
Version Published Release Notes

Changed algorithm for locating final frame. At suggestion of Micah Richert, author of the mmread program, now use the estimated number of frames returned by mmread as an initial guess.