Extracting frames form H264 4K video files (panasonic GH4)

1 vue (au cours des 30 derniers jours)
Emmanuel
Emmanuel le 4 Juin 2015
Matlab (R2011b) won't read correctly my GH4 video files. VideoReader object can be created, but matlab cannot determine the total number of frames: get(video) returns a blank field for numberOfFrames. Not a problem per se, but when attempting a read(video, i:j), the first frame is ok but then the following frames are all the same. Without any error message.
It happens with both 4K or 2K 100(Full HD) 100 Mbps video files, .MOV or .MP4 (all are H264 I think, had to install the Klite codec pack to read them). Only the more compressed, 50 Mbps files are correctly read it seems.
Interestingly, if I do a data = read(video), I run out of memory: "not enough memory for 192 frames". OK. So it seems that matlab is able to count the frames, finally. The strange part is that if I do a get(video) again, the numberOfFrames is 192 now. And if I try read(video, i:j), now all frames get extracted, except that sometimes two consecutive frames are identical.
Found lots of discussion around VideoReader problems, up to rev 2014b. For example http://www.mathworks.com/matlabcentral/newsreader/view_thread/326286. But none solutioned my problem. I installed GStreamer 1.4 on my 32bit win7 machine, with no results.
Any help greatly appreciated, thanks.

Réponses (0)

Produits

Community Treasure Hunt

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

Start Hunting!

Translated by