VideoReader doesn't seem to read videofiles (Ubuntu)
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
Tobias
am 20 Jul. 2015
Kommentiert: Tobias
am 21 Jul. 2015
I am having some trouble with VideoReader, using Ubuntu 14.04 and MATLAB 2015A. The amount of code I've written at this point is pretty straight forward:
vidObj = VideoReader('9/video.avi');
vidObj produces the following output:
vidObj =
VideoReader with properties:
General Properties:
Name: 'video.avi'
Path: '/home/xx/Dropbox/xx/9'
Duration: 8.1920
CurrentTime: 0
Tag: ''
UserData: []
Video Properties:
Width: 0
Height: 0
FrameRate: 0
BitsPerPixel: 0
VideoFormat: ''
I might add that the actual duration of the video is more like 2 seconds. Now, I've been looking into GStreamer and installed version 1.0 through a PPA and codecs packages (the latter through software center). It also seems to me that many people get an explicit error, when there are problems regarding this (looking at previously asked questions), which I am not getting. I have read, write and execute properties of the file in question.
2 Kommentare
Dinesh Iyer
am 20 Jul. 2015
Tobias,
First of VideoReader only supports Gstreamer version 0.10 and not version 1.0. My initial guess would be that the file has a video stream encoded in a format for which there are no codecs available on your system to read. Couple of things to try are?
1. Are you able to play this file using Totem Player which also uses Gstreamer?
2. Try to execute the following on the Linux console against Gstreamer 0.10
gst-launch-0.10 playbin2 uri=file:///home/xx/Dropbox/xx/9/video.avi video-sink=appsink audio-sink=fakesink text-sink=fakesink
and verify that it does not generate any errors.
Akzeptierte Antwort
Dinesh Iyer
am 21 Jul. 2015
Tobias, I am glad that installing the missing MPEG4 codecs resolved this issue.
Dinesh
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Audio and Video Data finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!