You are not logged in.

#1 2012-12-26 23:07:52

felixculpa
Member
From: Alberta, Canada
Registered: 2012-06-12
Posts: 188

Mplayer vs FFplay?

What's the difference between playing movie files with Mplayer vs just using ffplay via the command line? I have been using Mplayer for years and just recently discovered ffplay, and it seems to play everything I need to play and has similar keyboard shortcuts (f = toggle fullscreen, arrow keys for seeking, etc). It is lacking .srt (subtitle) support, i.e. I can't toggle subtitles that are in the same directory; also I can't toggle an OSD or change volume at fullscreen. Other than that there doesn't seem to be any huge differences or reasons to not just use ffplay? Am I missing something?

I believe in KISS, and it seems ffplay would be the simplest solution for playing videos.

Offline

#2 2012-12-27 00:26:40

ngoonee
Forum Fellow
From: Between Thailand and Singapore
Registered: 2009-03-17
Posts: 6,854

Re: Mplayer vs FFplay?

Different software, that's all. What's the difference between Firefox and Chromium, for example?


Allan-Volunteer on the (topic being discussed) mailn lists. You never get the people who matters attention on the forums.
jasonwryan-Installing Arch is a measure of your literacy. Maintaining Arch is a measure of your diligence. Contributing to Arch is a measure of your competence.
Griemak-Bleeding edge, not bleeding flat. Edge denotes falls will occur from time to time. Bring your own parachute.

Offline

#3 2012-12-27 00:44:29

felixculpa
Member
From: Alberta, Canada
Registered: 2012-06-12
Posts: 188

Re: Mplayer vs FFplay?

Thanks for the clarification, that's all I needed. I will be using FFplay as my default media player unless I need to use .srt files.

smile

Offline

#4 2012-12-27 00:57:09

Gusar
Member
Registered: 2009-08-25
Posts: 3,472

Re: Mplayer vs FFplay?

It's not as simple as "different software".

ffplay is a reference app, it's meant to demonstrate how to use the ff libs, it's not meant to be a full playback solution. @felixculpa: You yourself have identified some things ffplay cannot do. There's tons more. Maybe you can get by with the spartan feature-set ffplay provides, in which case use it. I couldn't, I use quite a bit of stuff mplayer (mplayer2, actually) provides that ffplay does not:
extensive keyboard configuration like various levels of seeking (1s, 10s, 60s) and other stuff, also quite extensive mouse setup, automatically using multi-threaded decoding based on number of CPU cores, different video output methods (mostly xv and vdpau, but also gl sometimes), deinterlacing and sometimes other filters (both video and audio), watching TV (analog in the past, nowadays DVB), etc, etc...

As you can see quite a difference between a reference app and a full playback solution.

Edit: If you need a different player for some cases, why not just use it all the time? Using two apps when one would suffice isn't what I'd call KISS.

Last edited by Gusar (2012-12-27 01:01:12)

Offline

#5 2012-12-27 05:11:11

felixculpa
Member
From: Alberta, Canada
Registered: 2012-06-12
Posts: 188

Re: Mplayer vs FFplay?

Gusar wrote:

automatically using multi-threaded decoding based on number of CPU cores, different video output methods (mostly xv and vdpau, but also gl sometimes), deinterlacing and sometimes other filters (both video and audio)

Edit: If you need a different player for some cases, why not just use it all the time? Using two apps when one would suffice isn't what I'd call KISS.

The multi-threading actually sounds interesting, I  notice Mplayer will lag if I play HD videos while ffplay and vlc will play them back fine. Will using Mplayer2 with multi-threading resolve that issue? I can't do the single app as ffplay is needed* by other apps (such as mpd) so if I use mplayer or mplayer2 I will have two possible apps for media usage anyway.

Edit: * just a small correction, I meant that ffmpeg is required by mpd, and ffplay is a component of ffmpeg.

Last edited by felixculpa (2012-12-27 16:45:04)

Offline

#6 2012-12-27 11:49:11

Army
Member
Registered: 2007-12-07
Posts: 1,784

Re: Mplayer vs FFplay?

I like how ffplay plays audio files smile Try it out! Hint: Click on the playback window and see (or hear) what happens.

Offline

#7 2012-12-29 20:04:39

DrZaius
Member
Registered: 2008-01-02
Posts: 170

Re: Mplayer vs FFplay?

felixculpa wrote:

Thanks for the clarification, that's all I needed. I will be using FFplay as my default media player unless I need to use .srt files.

I haven't actually tried this, but ffplay may be able to play subtitles:

ffplay input.foo -vf subtitles=subtitle.srt

Your ffmpeg will require libass as a dependency with configure option --enable-libass for this to work. It also works with captions from TED talks:

ffplay ted.mp4 -vf subtitles=ted.json
Army wrote:

I like how ffplay plays audio files smile Try it out! Hint: Click on the playback window and see (or hear) what happens.

Also press "w" during playback.


Damned dirty ape.

Offline

#8 2013-01-05 00:56:30

felixculpa
Member
From: Alberta, Canada
Registered: 2012-06-12
Posts: 188

Re: Mplayer vs FFplay?

Silly me. I enabled the "Sna" acceleration option as documented on the Intel Wiki page, along with the "tear free" option and now HD videos don't lag at all in mplayer. Since this is the case I may just be sticking with Mplayer from now on.

Section "Device"
   Identifier  "Intel Graphics"
   Driver      "intel"
   Option      "AccelMethod"  "sna"
   Option     "TearFree" "true"
EndSection

Offline

#9 2013-01-05 01:03:03

WonderWoofy
Member
From: Los Gatos, CA
Registered: 2012-05-19
Posts: 8,412

Re: Mplayer vs FFplay?

Setting TearFree made mplayer totally freeze up X from time to time.  Typically when I was playing movies from my server over nfs4, but sometimes with local movies as well, though not as frequently.

Offline

#10 2013-01-05 01:14:42

felixculpa
Member
From: Alberta, Canada
Registered: 2012-06-12
Posts: 188

Re: Mplayer vs FFplay?

WonderWoofy wrote:

Setting TearFree made mplayer totally freeze up X from time to time.  Typically when I was playing movies from my server over nfs4, but sometimes with local movies as well, though not as frequently.

I set the option because it seemed to be crashing or freezing X for me, when I didn't have the TearFree mode enabled. I haven't experienced it since setting, but it was frequent beforehand.

Offline

#11 2013-01-05 03:31:18

WonderWoofy
Member
From: Los Gatos, CA
Registered: 2012-05-19
Posts: 8,412

Re: Mplayer vs FFplay?

Interesting, the stability is significantly better overall for me without it set.  I don't think I had ever used the SysRq key so much in all my life!

Offline

#12 2013-01-05 20:39:00

felixculpa
Member
From: Alberta, Canada
Registered: 2012-06-12
Posts: 188

Re: Mplayer vs FFplay?

I have learned you are correct. My X session seems to freeze up/crash whenever I access a file system through either NFS or SSH and then exit. Other than that it seems okey dokey.

Offline

#13 2013-01-05 21:27:14

WonderWoofy
Member
From: Los Gatos, CA
Registered: 2012-05-19
Posts: 8,412

Re: Mplayer vs FFplay?

Yes, that is the point at which I discovered this as well.  I also cannot seem to find any relevent documentation about the "TearFree" option either.  Except of course on our wiki.

Offline

#14 2013-01-05 21:39:51

Gusar
Member
Registered: 2009-08-25
Posts: 3,472

Re: Mplayer vs FFplay?

WonderWoofy wrote:

I also cannot seem to find any relevent documentation about the "TearFree" option either.

Probably because it's an experimental proof-of-concept feature. It's an attempt at doing screen updates via pageflipping. Usually, doing pageflipping requires an opengl-based compositor, TearFree is an attempt to do it without one.

Offline

#15 2013-01-05 21:50:51

WonderWoofy
Member
From: Los Gatos, CA
Registered: 2012-05-19
Posts: 8,412

Re: Mplayer vs FFplay?

Thanks Gusar.  That would explain why I cannot find any documentation on that one.  For now I will leave it off, but it sounds like a promising feature.

Offline

#16 2013-01-07 02:48:47

ConnorBehan
Trusted User (TU)
From: Long Island NY
Registered: 2007-07-05
Posts: 1,356
Website

Re: Mplayer vs FFplay?

felixculpa wrote:

The multi-threading actually sounds interesting, I  notice Mplayer will lag if I play HD videos while ffplay and vlc will play them back fine. Will using Mplayer2 with multi-threading resolve that issue?

Probably. You can also try "mplayer -ladvopts threads=<2 or more>" to get multi-threading.

By the way, reference players like this are pretty common. There's aplay in ALSA, playdv in libdv, sndfile-play in libsndfile and glav in mjpegtools.


6EA3 F3F3 B908 2632 A9CB E931 D53A 0445 B47A 0DAB
Great things come in tar.xz packages.

Offline

#17 2013-01-08 02:07:44

felixculpa
Member
From: Alberta, Canada
Registered: 2012-06-12
Posts: 188

Re: Mplayer vs FFplay?

Probably. You can also try "mplayer -ladvopts threads=<2 or more>" to get multi-threading.

You are a few days late, I discovered this not too long ago tongue

Offline

#18 2013-10-25 06:01:02

sant527
Member
Registered: 2009-06-21
Posts: 267

Re: Mplayer vs FFplay?

I am also interested in how to control the volume in ffplay. In this thread its not found. Also where is the config file for ffplay so that softvol = 600% something similar can be done. Also change seek time

Offline

#19 2013-10-28 21:31:54

teckk
Member
Registered: 2013-02-21
Posts: 210

Re: Mplayer vs FFplay?

Louder

ffplay -af 'volume=2.0' BirdBlueJay1.mp3

Quieter

ffplay -af 'volume=0.5' BirdBlueJay1.mp3

Last edited by teckk (2013-10-28 21:32:47)

Offline

#20 2013-10-28 21:45:48

Jristz
Member
From: America/Santiago
Registered: 2011-06-11
Posts: 924

Re: Mplayer vs FFplay?

Gusar wrote:
WonderWoofy wrote:

I also cannot seem to find any relevent documentation about the "TearFree" option either.

Probably because it's an experimental proof-of-concept feature. It's an attempt at doing screen updates via pageflipping. Usually, doing pageflipping requires an opengl-based compositor, TearFree is an attempt to do it without one.

The documentation is on the manpage...for the next major release of intel driver (3.0.0 I think), look the commit and I notice that tearfree drop performance a little, use more memory but reduce tearing, meaning that those fre.ezes are a clear bug (or undocummented feature)

Last edited by Jristz (2013-10-28 21:47:27)


Well, I suppose that this is somekind of signature, no?

Offline

Board footer

Powered by FluxBB