Page 1 of 1
,h264 playback - help !
Posted: Wed May 04, 2016 8:03 am
by timmoore46
I'm a proud owner of the latest Pi complete with WiFi and a 8MP camera
After a bit of hassle with getting a 64GB sd card with Raspbian 18th March 2016 working on it, I tried this:-
raspivid -t 25000 -o video.h264
and lo a file duly arrived in the home directory ! Brill
Never having heard of .h264 left me with a struggle to find something to play it on.
Moving the file to Ubuntu 14.04 and downloading smplayer I could now watch 25 seconds of video ! I had hoped ! *LOL*
yes it played ! in about 5 seconds !
Any thoughts on what I have to do to watch this video at the right frame rate for smplayer...., would be greatly appreciated !
Tim
Re: ,h264 playback - help !
Posted: Wed May 04, 2016 8:06 am
by DirkS
Re: ,h264 playback - help !
Posted: Wed May 04, 2016 8:56 am
by timmoore46
Many thanks for that info, I will try it out !
by the way how do I install omxplayer ?
is it
sudo apt-get install omxplayer
???
Many thanks again,
Tim
Re: ,h264 playback - help !
Posted: Wed May 04, 2016 9:00 am
by SkyRise
Yes,
will install omxplayer
Also, when installing packages, apt keeps a copy of the file it downloaded for installation. This cache can become quite big over time.
A
will prune the download files from the cache.
Re: ,h264 playback - help !
Posted: Wed May 04, 2016 9:44 am
by timmoore46
Re: ,h264 playback - help !
Posted: Wed May 04, 2016 4:15 pm
by timmoore46
tried that and omxplayer and it installed but ./omxplayer yielded
No such file or directory....
all this was in the home directory...
so I'm still stuck..
Any more tips greatly appreciated ?
Tim
Re: ,h264 playback - help !
Posted: Wed May 04, 2016 4:21 pm
by DirkS
timmoore46 wrote:tried that and omxplayer and it installed but ./omxplayer yielded
Use it without the ./
Re: ,h264 playback - help !
Posted: Wed May 04, 2016 4:24 pm
by RaTTuS
if you want to play it back on other machines then you may want to container the file
as the .h264 is a raw file you need to tell it that it is
25fps
or it may just play back as fast as possible
Re: ,h264 playback - help !
Posted: Wed May 04, 2016 6:06 pm
by timmoore46
Got smplayer downloaded to the Pi and it took 3 minutes to play the 25second video clip
the version of smplayer was.....14.9.0
it took a bit to get smplayer to accept it !
file/multimedia (bottom right on screen), scrolled down its menu and settle on 'All Filesand high lighted video.h264
and it played it very very slowly !
What do I do next ?
Any thoughts anyone ?
Tim
Re: ,h264 playback - help !
Posted: Wed May 04, 2016 7:05 pm
by timmoore46
RaTTuS wrote:if you want to play it back on other machines then you may want to container the file
as the .h264 is a raw file you need to tell it that it is
25fps
or it may just play back as fast as possible
How do you tell it that its 25fps ?
Many thanks for responding !
Tim
Re: ,h264 playback - help !
Posted: Thu May 05, 2016 7:34 am
by ghans
You have to use a muxer like MP4Box after you've finished
recording to create "proper" .mp4 files from raw .h264.
Code: Select all
sudo apt-get install gpac
MP4Box -fps 30 -add infile.h264 outfile.mp4
omxplayer outfile.mp4
ghans
Re: ,h264 playback - help !
Posted: Thu May 05, 2016 6:58 pm
by timmoore46
Many many thaks for responding. I'll try MP4Box.
Tim
Re: ,h264 playback - help !
Posted: Thu May 05, 2016 9:48 pm
by timmoore46
I put the video.h264 file on a PC running Ubuntu 14.04 and installed 'gpac' and that automatically woke a variant of VLC which ran the video clip close to real time, but also put it into a continuous loop.
Now that's a huge improvement over being massively too slow or massively too fast.
Technically I don't know what I'm doing, just poking it with a stick until I stumble on a satisfactory solution.
I'm very very grateful for all the tips and suggestions the members of this Forum have offered !
Tim
Re: ,h264 playback - help !
Posted: Sat May 07, 2016 6:36 am
by ghans
Both the "raspivid" command and the "MP4Box" command
have an "fps" option - it obviously needs to be the same
for both commands.
ghans