Very unsure about this. One problem is that it interferes with some
useful settings (like setting panscan to anything between 0 and 1). The
"custom" mode stops PMP itself from overwriting these mpv settings, but
it can't restore them at runtime. (Read: if users want to do custom
stuff with mpv.conf, they need to set aspect to "custom", and then
restart PMP.)
"componentPostInitalize" is misspelled, thus not overriding
componentPostInitialize. Instead, toggling fullscreen got reimplemented
in KonvergoWindow.cpp instead.
Indicates how fast the media data is downloaded.
Caveat: if the speed is high enough, download will often stop, which
resets the value to "0". Related to this, TCP buffering behavior can
lead to ridiculous values alternating with 0 to be shown.
This changes the "hardware_decoding" setting from bool to a selection.
This breaks/discards the old setting. (I had an idea to keep it
compatible, but it seems web-client or maybe something else doesn't
like it at all if a setting in the user's config has the wrong
type, and the UI will basically become unfunctional.)
If users had a "videotoolbox-format" option set in their mpv.conf file,
it will be overwritten. (Which might be annoying for users who needed
this - they will have to explicitly select the mode in the UI after
updating.)
Actually applying the format requires a restart for silly technical
reasons. This can probably be improved later on.
startCodecsLoading() is now called twice:
1. Before the stream is even opened. getPlaybackInfo() is made to use
the PMS metadata in this case.
2. After the stream has been opened and before a dedoder starts.
getPlaybackInfo() will use the player-analyzed metadata.
I'm hoping this makes all combinations of possible fuckups work. One
case this should certainly fix is playing raw DTS. If no DTS codec was
present yet, opening would fail in libavformat. Downloading the codec
before opening the file should take care of it.
This is chained with display mode switching. Not bothering with making
it run in parallel with mode switching, because I'm not even sure the
simpler current implementation is always correct.
While they mostly work automagically, we still have to make sure they
interact with codec downloading well. In particular, it could happen
that we prefer a downloadable codec over a system one, depending on
the media. We also only allow using system codecs which are known
working.
PMP will now download codec binaries from nightlies on playback start if
built with -DENABLE_CODECS=on. With "off" (the default), most codecs on
demand code will be built, but the list of downloadable codecs will be
empty.
This uses a hardcoded CODECS_BUILD_NUMBER. This is sort of ok, as long
as the list of codecs/names on nightlies doesn't change. If there's a
change, it should be updated manually. (Same if new platforms are added
etc.) Note that even if this is not changed, the code will download the
correct codecs by looking at the FFmpeg version number libmpv is linked
against.
This following code emulates the harmony remotes input to PHT. The Apple API is actually
limited to just the number of keys that are on Apple specific remotes so we had to work
around that with the following hack: deviceID was used as a prefix for what the keys meant
so for example if we send deviceID 150 and keycode UP it means up, but instead deviceID 151
and UP it can be mapped to a different key.
The harmony profile for this is using deviceID's 150-160 to prefix the keycode, so we will
treat them differently here than the other keycodes. We append the deviceID to the keycode
when the deviceID falls inside the 150-160 range, otherwise we assume the keycode is coming
from a "normal" remote and only forward the keycode.
Since it's unknown if this will cause problems with any remotes I have added a setting:
appleremote.emulatepht to turn this off if needed, but for now we'll keep it defaulted to on
Instead of maintaining lists per compiler of flags that should
be enabled / disabled we now test for them instead. If they are
able to be used we append them.
Same with linker flags we test for them before assuming they work.
This will make sure that the qt.conf file is only written if no QTROOT variable is passed to cmake. It will allow building on Linux with non-root accounts when the QTROOT points to a priviliged folder on the system.
This has been discussed in issue #276.
Plex-CLA-1.0-signed-off-by: Niclas Berglind <nb@kjam.se>