Why does VideoReader return an empty video object on Linux?
Mostrar comentarios más antiguos
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').Video
ans =
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.
Respuesta aceptada
Más respuestas (0)
Categorías
Más información sobre Startup and Shutdown en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
