I have an AVI file encoded in H.264 format. I am successfully able to read it in MATLAB on Windows 10. However, when opening the file with 'VideoReader' on Linux, I get the following output:
>> VideoReader('MyVideo.avi');ans = VideoReader with properties: General Properties: Name: 'MyVideo.avi' Path: '/home/user/Documents/MyVideo.avi' Duration: 300.0240 CurrentTime: 300.0240 NumFrames: <Calculating...> learn more Video Properties: Width: 0 Height: 0 FrameRate: 0 BitsPerPixel: 0 VideoFormat: ''
Notice that the 'Width', 'Height', 'FrameRate', and 'BitsPerPixel' properties are all 0 and the 'VideoFormat' string is empty. The 'mmfileinfo' command gives similar output:
>> mmfileinfo('MyVideo.avi').Videoans = struct with fields: Format: '' Height: [] Width: []
Finally, if I call 'readFrame' on this 'VideoReader' object, it errors with the following message:
No more frames available to read from file.
Best Answer