Re: omxplayer - GPU enabled video player
Right, so you're using ffmpeg .h files but linking against libav. I'm surprised this worked out well.
Re: omxplayer - GPU enabled video player
Ok, I changed a few lines in DllAvFilter.h and DllAvFilter.h and finally got it to compile with libav under raspbian. Unfortunately, omxplayer doesn't output a picture so I'm still doing something wrong, but that'll have to wait till tomorrow.
I might have changed another include path, but can't remember now. Finally needed another package "apt-get install libswscale-dev" and then "export LD_LIBRARY_PATH=/opt/vc/lib" and then "make".
Code: Select all
DllAvUtil.h:
...
extern "C" {
#if (defined USE_EXTERNAL_FFMPEG)
#if (defined HAVE_LIBAVUTIL_AVUTIL_H)
#include <libavutil/avutil.h>
#include <libavutil/mathematics.h> // add this line
#include <libavfilter/vsrc_buffer.h> // add this line
...
DllAvFilter.h:
...
#if LIBAVFILTER_VERSION_INT >= AV_VERSION_INT(2,8,0)
#include <libavcodec/avcodec.h> // change this
#elif LIBAVFILTER_VERSION_INT >= AV_VERSION_INT(2,7,0)
...
virtual int avfilter_request_frame(AVFilterLink *link) { return ::avfilter_request_frame(link); }
// add below (not sure what I'm doing is right)
#if LIBAVFILTER_VERSION_INT >= AV_VERSION_INT(2,15,0)
virtual int av_vsrc_buffer_add_frame(AVFilterContext *buffer_filter, AVFrame *frame, int flags) {
AVRational pixel_aspect;
pixel_aspect.num=1;
pixel_aspect.den=1;
return ::av_vsrc_buffer_add_frame(buffer_filter, frame, flags, pixel_aspect);
}
#elif LIBAVFILTER_VERSION_INT >= AV_VERSION_INT(2,13,0)
...
Re: omxplayer - GPU enabled video player
Managed to get it working correctly by setting the video to 1280x720 , 720p , CEA mode 4.karapuzo wrote:Is there anyway to play with the aspect ratio using parameters for omxplayer?
My TV is a bit quirky - it's 1024x768 but the physical ration is 16:9 - so the pixels are in a sense rectangular instead of square.
omxplayer shows 16:9 video with large black bars across the top and bottom. (xbmc has the same problem - even after doing calibration)
When I am using VLC I am setting the ration to 4:3 (even thought the video is 16:9) and that fills the entire screen.
The TV displays the ratio correctly now.
Re: omxplayer - GPU enabled video player
No. I'm linking against the files provided by the Arch ffmpeg package, which includes the libav* headers and libraries. That's how Arch works. There is no separate libav (or -dev) package in Arch.You should stop trying to judge Arch in Debian terms.tk321 wrote:Right, so you're using ffmpeg .h files but linking against libav. I'm surprised this worked out well.
That's why it works. It's a consistent Arch build. There is nothing surprising about.
Re: omxplayer - GPU enabled video player
Has anyone successfully got any sort of network streaming to work with this guy? The source code has a few references to http, mms, and rtmp, but I haven't been able to get them to work as a stream. I've gotten http to work playing a video file sitting on a server, but never a http stream or mms stream out of something like vlc on another machine.
Re: omxplayer - GPU enabled video player
I have it streaming sopcast from my PC. works great.
omxplayer -o hdmi http://192.168.0.2:8902/tv.ts
omxplayer -o hdmi http://192.168.0.2:8902/tv.ts
Re: omxplayer - GPU enabled video player
And viewing TWiT Live with omxplayer -o local http://bglive-a.bitgravity.com/twit/live/low works as well, which is quite useful. Even though it does crash occasionally.
One thing which is total a bummer is the fact that it won't decode mpeg-2 streams. I've successfully streamed TV channels from a server, but the server, which has the TV card, needs to transcode the stream into an mpeg-4 stream at 30%-40% CPU usage, which is not acceptable to me.
I'd love to hear about a solution of having the raspi decode 3-4 Mbps mpeg-2 streams.
One thing which is total a bummer is the fact that it won't decode mpeg-2 streams. I've successfully streamed TV channels from a server, but the server, which has the TV card, needs to transcode the stream into an mpeg-4 stream at 30%-40% CPU usage, which is not acceptable to me.
I'd love to hear about a solution of having the raspi decode 3-4 Mbps mpeg-2 streams.
Re: omxplayer - GPU enabled video player
I'm probably missing something (and i installed from the deb referenced in this thread rather than building myself) but how exactly does one pipe these key commands into omxplayer? Simply typing them on an attached keyboard doesnt work, neither does echo 'p' > /dev/tty1spennig wrote:There are a set of key-presses and effects in omxplayer.cpp, including p and space to pause, arrow keys to move, q to quit, s for subtitles and more that you can RTFS for.
Re: omxplayer - GPU enabled video player
I found some of them worked OK with keyboard. For example the cursor keys move about in the video. I've defected to OpenELEC though as you get a gui front-end (although I think it drives Omxplayer) which makes it easier to skip about however you want. It does require a separate SD card though, so may not be ideal for everyone.alanpich wrote:I'm probably missing something (and i installed from the deb referenced in this thread rather than building myself) but how exactly does one pipe these key commands into omxplayer? Simply typing them on an attached keyboard doesnt work, neither does echo 'p' > /dev/tty1spennig wrote:There are a set of key-presses and effects in omxplayer.cpp, including p and space to pause, arrow keys to move, q to quit, s for subtitles and more that you can RTFS for.
Alex Eames RasPi.TV, RasP.iO
Re: omxplayer - GPU enabled video player
I'm trying my hardest to avoid xbmc purely because I don't want the gui on the main display (the aim of my project is to get the gui running over http, and the main display just to show the video). Starting omxplayer from tty1 console accepts the space/pause command, but i cant figure out where to pipe it over ssh or from any other process
Re: omxplayer - GPU enabled video player
Hey Siriusfox,siriusfox wrote:Has anyone successfully got any sort of network streaming to work with this guy? The source code has a few references to http, mms, and rtmp, but I haven't been able to get them to work as a stream. I've gotten http to work playing a video file sitting on a server, but never a http stream or mms stream out of something like vlc on another machine.
I am also messing around with streaming (Shoutcast at the mo) and wasn't getting very far

Code: Select all
~$ omxplayer -o hdmi http://listen.di.fm/public3/lounge.pls
Code: Select all
~$ omxplayer -o hdmi http://160.79.128.61:5036

Code: Select all
Using network protocols without global network initialization. Please use avformat_network_init(), this will become mandatory later.
Using network protocols without global network initialization. Please use avformat_network_init(), this will become mandatory later.
Using network protocols without global network initialization. Please use avformat_network_init(), this will become mandatory later.
[mp3 @ 0x14ef650] Header missing
[mp3 @ 0x14e70a0] max_analyze_duration 5000000 reached at 5015510
[mp3 @ 0x14e70a0] Estimating duration from bitrate, this may be inaccurate
file : http://160.79.128.61:5036 reult 0 format mp3 audio streams 1 video streams 0 chapters 0 subtitles 0
Audio codec mp3 channels 2 samplerate 44100 bitspersample 16
[mp3 @ 0x14eeb90] Header missing
I ate all the Pi
Re: omxplayer - GPU enabled video player
Can a playlist be setup with omxplayer?
Re: omxplayer - GPU enabled video player
Hi there,
As this is my first post, I'd like to greet all Raspberry Pi designers and users. It's a great community and (since last friday :] ) I'm thrilled to be a part of it. I just looked into the sources of omxplayer, and discovered, that the -d switch (deinterlace) works only for SD video (namely less or equal than 720x576).
So my question is: as - judging from the source - deinterlacing on RPi is hardware based, are there there any hardware reasons for applying such limit or can we safely deinterlace and scale 1080i to 720p?
As this is my first post, I'd like to greet all Raspberry Pi designers and users. It's a great community and (since last friday :] ) I'm thrilled to be a part of it. I just looked into the sources of omxplayer, and discovered, that the -d switch (deinterlace) works only for SD video (namely less or equal than 720x576).
So my question is: as - judging from the source - deinterlacing on RPi is hardware based, are there there any hardware reasons for applying such limit or can we safely deinterlace and scale 1080i to 720p?
Re: omxplayer - GPU enabled video player
I've been wondering the same thing... google says no. I've tried a few formats to no avail (m3u & pls). Hmm - I might try xml...pauly24 wrote:Can a playlist be setup with omxplayer?
I wouldn't know where to start trying to make that happen, but it would certainly be handy!
I ate all the Pi
-
- Raspberry Pi Engineer & Forum Moderator
- Posts: 6033
- Joined: Wed Aug 17, 2011 7:41 pm
- Location: Cambridge
Re: omxplayer - GPU enabled video player
No, deinterlace is done in (vectorised) software on GPU. It uses quite an advanced algorithm, and can only deal with SD.matias wrote:So my question is: as - judging from the source - deinterlacing on RPi is hardware based, are there there any hardware reasons for applying such limit or can we safely deinterlace and scale 1080i to 720p?
I do have a plan to implement something cheaper, that can go up to 1080i, but there are a lot of plans on my list...
Re: omxplayer - GPU enabled video player
Hello everyone,
on debian wheezy I had to use aptitude instead of apt-get to solve the dependencies.
on debian wheezy I had to use aptitude instead of apt-get to solve the dependencies.
Re: omxplayer - GPU enabled video player
Also, the libpcre3 lib is in /lib/arm-linux-gnueabi
so my sym link was
sudo ln -s /lib/arm-linux-gnueabi/libpcre.so.3 /lib/libpcre.so.1
so my sym link was
sudo ln -s /lib/arm-linux-gnueabi/libpcre.so.3 /lib/libpcre.so.1
Re: omxplayer - GPU enabled video player
seem to have omxplayer installed but I don't know how to run it, any help would be appreciated as I am a linux newbie thanks
tried typing both omxplayer and sudo omxplayer at prompt in terminal but can't find it?
tried typing both omxplayer and sudo omxplayer at prompt in terminal but can't find it?
Re: omxplayer - GPU enabled video player
it works like that, omxplayer, if not, you didn't install itniall300 wrote:seem to have omxplayer installed but I don't know how to run it, any help would be appreciated as I am a linux newbie thanks
tried typing both omxplayer and sudo omxplayer at prompt in terminal but can't find it?
Re: omxplayer - GPU enabled video player
managed to get to the omxplayer directory typed "./omxplayer" error while loading shared libraries: libavutil.so.51: cannot open shared object file: no such file or directory
Re: omxplayer - GPU enabled video player
you didn't installed it well - try the debian packageniall300 wrote:managed to get to the omxplayer directory typed "./omxplayer" error while loading shared libraries: libavutil.so.51: cannot open shared object file: no such file or directory
Re: omxplayer - GPU enabled video player
ok now if i type omxplayer within the bin directory it gives me a list of "switches" or options such as -h / help etc, if i type omxplayer followed by filename.avi it says
have a nice day?
have a nice day?
Re: omxplayer - GPU enabled video player
Ok, first enable sound:
sudo modprobe snd_bcm2835
then, specify the sound, if hdmi, or local (headphones)
omxplayer -o hdmi testfile.avi
sudo modprobe snd_bcm2835
then, specify the sound, if hdmi, or local (headphones)
omxplayer -o hdmi testfile.avi
-
- Raspberry Pi Engineer & Forum Moderator
- Posts: 6033
- Joined: Wed Aug 17, 2011 7:41 pm
- Location: Cambridge
Re: omxplayer - GPU enabled video player
omxplayer doesn't use ALSA so no need for modprobe.netomx wrote:Ok, first enable sound:
sudo modprobe snd_bcm2835
then, specify the sound, if hdmi, or local (headphones)
omxplayer -o hdmi testfile.avi
Re: omxplayer - GPU enabled video player
thanks for all the help it seems that maybe my power supply maybe the problem it only outputs 400ma. I believe i need at least 700ma, will get e new power supply and try again