Discussion:
[MPlayer-users] Opus audio
arthurpeabody
2018-10-19 13:04:50 UTC
Permalink
ldd /usr/bin/mplayer reveals its link to libopus
stan
2018-10-19 19:16:29 UTC
Permalink
On Fri, 19 Oct 2018 06:04:50 -0700
Post by arthurpeabody
ldd /usr/bin/mplayer reveals its link to libopus
I suspect that Mike is right, and that is just the result of the
embedded ffmpeg in mplayer. It isn't actually *mplayer* that is
linking to libopus, but ffmpeg. So technically, *mplayer* has no
support for opus in its code. From a user perspective, though, mplayer
seems to have opus support. :-)
Philipp Stanner
2018-10-19 19:20:43 UTC
Permalink
Ok, great to know :)

But some codecs are supported natively without linking to other
libraries? Thinking about it this way I wonder why anyone would support
codecs natively in any case, as you can just link to the responsible
libs.
Post by stan
On Fri, 19 Oct 2018 06:04:50 -0700
Post by arthurpeabody
ldd /usr/bin/mplayer reveals its link to libopus
I suspect that Mike is right, and that is just the result of the
embedded ffmpeg in mplayer.  It isn't actually *mplayer* that is
linking to libopus, but ffmpeg.  So technically, *mplayer* has no
support for opus in its code.  From a user perspective, though,
mplayer
seems to have opus support.  :-)
_______________________________________________
MPlayer-users mailing list
https://lists.mplayerhq.hu/mailman/listinfo/mplayer-users
The Wanderer
2018-10-19 20:17:27 UTC
Permalink
Post by Philipp Stanner
Ok, great to know :)
But some codecs are supported natively without linking to other
libraries? Thinking about it this way I wonder why anyone would
support codecs natively in any case, as you can just link to the
responsible libs.
Short answer: historical reasons.

IIRC, this was partly because in some cases there *weren't* originally
any libraries available (for the relevant platforms) which supported the
codecs in question, and in others someone thought the available library
didn't do the job well enough and thought they could do better.

Of course, if you're going to try to implement codec (etc.) support
better, it would make more sense to do it in a library than in MPlayer
itself, so that it can be used by other software - and, if I'm not
mistaken, that's exactly why so many codecs (etc.) got implemented in
FFmpeg rather than natively within MPlayer.


If all you want is to have MPlayer support the codec, it's very probably
faster and easier to implement the codec within MPlayer than to write a
separate library and then implement MPlayer support for that library.

But it's probably even faster and easier than *that* to implement the
codec within FFmpeg (which MPlayer already supports) and then let
MPlayer pick it up automagically - and doing that means other software,
beyond just MPlayer, can get the new codec automagically as well.

About the only reason to do it as an independent library nowadays, that
I can think of offhand, is if you don't want to deal with getting it
accepted into FFmpeg (and/or don't want to live within the constraints
of the FFmpeg structure).
--
The Wanderer

The reasonable man adapts himself to the world; the unreasonable one
persists in trying to adapt the world to himself. Therefore all
progress depends on the unreasonable man. -- George Bernard Shaw
stan
2018-10-19 20:35:37 UTC
Permalink
On Fri, 19 Oct 2018 21:20:43 +0200
Post by Philipp Stanner
Ok, great to know :)
But some codecs are supported natively without linking to other
libraries? Thinking about it this way I wonder why anyone would
support codecs natively in any case, as you can just link to the
responsible libs.
No, all codecs are supported by linking to libraries. Other people have
thought the same way you have. :-) The difference here is that the
code doing the linking is from another project, ffmpeg, and not from
the mplayer code. If you compile the mplayer source, you will see that
ffmpeg is embedded as part of the build process. If the switch is set
correctly, it even goes and grabs the latest code from the ffmpeg git
repository.

Loading...