How to play video on a Pi ?


17 posts
by andy33 » Fri Jul 06, 2012 12:46 pm
How do you play video on a raspberry pi ? I have my sound working but cannot find a way to play video. Also which format does the video have to be? I'm using a Debian squeeze.

andy33
Posts: 37
Joined: Fri Jul 06, 2012 12:42 pm
by felix123 » Fri Jul 06, 2012 1:17 pm
omxplayer
Posts: 153
Joined: Tue May 15, 2012 6:06 am
by andy33 » Fri Jul 06, 2012 1:29 pm
Do you install omxplayer via the cli or through the guy and then how do you start it? I have tried installing via get-apt and it seemed to install ok, but I can't get it to start!
Posts: 37
Joined: Fri Jul 06, 2012 12:42 pm
by dom » Fri Jul 06, 2012 1:35 pm
Recommended is to install Wheezy, which has omxplayer installed by default:
http://www.raspberrypi.org/archives/1435
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 4059
Joined: Wed Aug 17, 2011 7:41 pm
Location: Cambridge
by JeremyF » Fri Jul 06, 2012 2:48 pm
andy33 wrote:How do you play video on a raspberry pi ? I have my sound working but cannot find a way to play video. Also which format does the video have to be? I'm using a Debian squeeze.

andy33

As dom said, for a beginner, it is easiest to get omxplayer by switching to Wheezy beta. Once you have it installed, the only formats you can play are H264 or Xvid (with any container, I believe)
{sig} Setup: Original version Raspberry Pi (B, rev1, 256MB), Dell 2001FP monitor (1600x1200), 8GB Class 4 SD Card with Raspbian and XBMC, DD-WRT wireless bridge
Posts: 516
Joined: Wed Jan 25, 2012 9:06 pm
by alexeames » Fri Jul 06, 2012 3:35 pm
And once you've got it on Wheezy, go to the folder where your H.264 mp4 files are and type...

Code: Select all
omxplayer -o hdmi /path/to/filename.mp4


...where -o hdmi directs the sound to the HDMI on the TV
Alex Eames RasPi.TV HDMIPi.com RasP.iO
User avatar
Posts: 2091
Joined: Sat Mar 03, 2012 11:57 am
Location: UK
by andy33 » Fri Jul 06, 2012 8:38 pm
I have now got wheezy running but I cannot find the omxplayer! Do I have to install it?
Posts: 37
Joined: Fri Jul 06, 2012 12:42 pm
by alexeames » Fri Jul 06, 2012 9:01 pm
you shouldn't need to find it. Just type
Code: Select all
omxplayer
and see what happens. :D
Alex Eames RasPi.TV HDMIPi.com RasP.iO
User avatar
Posts: 2091
Joined: Sat Mar 03, 2012 11:57 am
Location: UK
by andy33 » Sat Jul 07, 2012 2:18 pm
Thanks guys I now have it playing hd video with sound. I installed omxplayer on squeeze with help from the latest issue of The MagPi. http://www.themagpi.com/
Posts: 37
Joined: Fri Jul 06, 2012 12:42 pm
by PaulLatham17 » Fri Dec 21, 2012 11:25 pm
Hi! I've followed andy's link to the magazine website and I followed the instructions to downloading omxplayer but nothing happens! I'm new to all this kind of stuff and I'm doing my best to teach myself using YouTube and these forums but it's painfully slow! Any easily explained help welcome please! Thank you. Paul
Posts: 1
Joined: Fri Dec 21, 2012 11:14 pm
by mythbuster » Sun Dec 23, 2012 10:47 am
Rasbmc,you will need to download a new OS.Go to website:www.rasbmc.com
Posts: 2
Joined: Sun Dec 23, 2012 10:40 am
by f25 » Thu Apr 18, 2013 6:47 pm
I kicked the following:
Code: Select all
# omxplayer MyMovie.avi

Looks cool! You do not even need to have the GUI started (no startx) :-)
Posts: 5
Joined: Wed Apr 17, 2013 6:07 pm
by ofey » Tue Oct 15, 2013 10:08 pm
Hi,
I am also trying to play a video file called testvideo.h264
This video was created using
Code: Select all
raspivid -o video.h264 -t 10000

from the http://www.raspberrypi.org/camera camera module tutorial.
I have tried,
Code: Select all
$ omxplayer -g testvideo.h264
Video codec omx-h264 width 1920 height 1080 profile 100 fps 25.000000
Subtitle count: 0, state: off, index: 1, delay: 0

have a nice day ;)

It doesn't play.
What should I be doing?
Thanks,
Shane
Pi = too much fun!
Posts: 106
Joined: Tue Jul 16, 2013 9:41 pm
Location: St.Gallen, Switzerland/Dublin, Ireland
by Lucky75 » Tue Oct 15, 2013 11:35 pm
Yeah, I have the same question. How do you do this if you're running raspbmc and x is already running?
Posts: 3
Joined: Tue Oct 15, 2013 11:32 pm
by ghans » Wed Oct 16, 2013 8:22 am
RaspBMC does work without X. Why would you want to start omxplayer when
you have XBMC ? You might be able to quit XBMC or bring up virtual terminal, but
that should be already explained somwhere on the RaspBMC homepage /forum.


ghans
• Don't like the board ? Missing features ? Change to the prosilver theme ! You can find it in your settings.
• Don't like to search the forum BEFORE posting 'cos it's useless ? Try googling : yoursearchtermshere site:raspberrypi.org
Posts: 4755
Joined: Mon Dec 12, 2011 8:30 pm
Location: Germany
by Lucky75 » Wed Oct 16, 2013 2:08 pm
I was trying to do this: viewtopic.php?f=91&t=58349
Posts: 3
Joined: Tue Oct 15, 2013 11:32 pm
by ghans » Thu Oct 17, 2013 7:16 am
• Don't like the board ? Missing features ? Change to the prosilver theme ! You can find it in your settings.
• Don't like to search the forum BEFORE posting 'cos it's useless ? Try googling : yoursearchtermshere site:raspberrypi.org
Posts: 4755
Joined: Mon Dec 12, 2011 8:30 pm
Location: Germany