Mythtranscode: Don't overwrite cutlist from the command line.

Adapted from a patch by John Finlay.  Refs #11939.
(cherry picked from commit 22409776f5d737dbf8a9b3d31d41498b20a59774)
Simplify MythCoreContext::GetMasterHostPrefix(). It's a waste of time to get the IP/port from the socket when we can be using the values from the settings instead, if we're not already connected to the master we will soon be connecting anyway to conduct the file transfer.
(cherry picked from commit 22b48f435a97b6b973a2e0dea9e89548350bc01e)

Refs #11937
Fix reversed logic in dfe5396.  Refs #11939.
Respect LiveTVOrder priority when switching sources.

This is the playback OSD menu Playback > Source > Switch Source.
Refs #10967.
(cherry picked from commit cb602368945cf42f9072d8187991cff0b025684a)
Handle system keypress events during playback.  Refs #11881.
(cherry picked from commit b83e60520062cd338f2b952a8b8bc7aeb0260b27)
Fix lossless transcode.

Following 6c3653cd378aacef10b7706d8b7f71beae41274c, lossless mythtranscode got broken.

This is just a quick workaround, the whole code needs to be revisited and properly use FFmpeg API

Fixes #11213

Signed-off-by: Jean-Yves Avenard <jyavenard@mythtv.org>
(cherry picked from commit 2a27e176275155a04498ecb8eac67dbd0164d080)
actually add the timecodeOffset when getting audio frames

We have to ask the AudioReencodeBuffer for audio to write with the
original timecode before applying the cut list.

Patch by Nicolas Pöhlmann
Reviewed by Paul Gardiner

Refs #11213
Refs #11639

(cherry picked from commit ea8c2b91e91e5cada8f8309f9fcb63f831f79aee)
Update mythpython script for new tmdb library.
(cherry picked from commit 5c5082a6109df3e3c4ddb99569fcf37af55b97d1)
H264Parser: Only enter the "state changed" state if we have seen a SPS.

Fixes #11882
May help or solve #11886

(cherry picked from commit 306f9fc004d52e87defca84f8c33616ef0e00485)
Don't timeout the signalmonitor until all hope is lost.

(cherry picked from commit 080ef223c56682bbe356be293a53f3d38f6ca5c2)
Re-enable display of tuning status in LiveTV after [9b22460f5]

(cherry picked from commit fc2ba41a253f115976bcc8794b13297ec41eb150)
Following [080ef223c] don't segfault if curRecording is NULL.

(cherry picked from commit fabca8bee90ed0765b9f0f902e92bdbed88f5123)
Make ffmpeg call 'streams_changed' again when a DVD PCM stream is changed from PCM_DVD to PCM_S16BE to ensure the correct codec is loaded.

Fixes #11941
(cherry picked from commit d8c710d204f5769ea4d0304a9a8618eb417f2837)
Fix compiler warnings spotted by Jonatan Lindblad.

Cherry-picked from most of c06c191712a7e0721a423528f37420c30d53cab7.
mythzmserver: fix the debug output telling us which mmap files we opened

(cherry picked from commit ce27ac589bf510e280fa1ebabe46b250b6452722)
MythZoneMinder: finish the support for ZoneMinder >= 0.26.0

All combinations of capture palette and target colour space should now be
supported. This also moves all the processing to mythzmserver and always
passes RGB24 to the plugin.

Note: bumps the protocol version so both mythzmserver and the plugin need to
be updated.

(cherry picked from commit 68c07c49499ca5be40751bf59908bf03b242f281)
mythburn.py: pass the starttime in utc format to mythtranscode

I can't easily test this but hopefully this will fix the problems reported on
the user mailing list and in #11758.

Refs #11758.

Signed-off-by: Paul Harrison <pharrison@mythtv.org>
(cherry picked from commit 45e62c8cb69c3abbbf883d926bd5c0e2137d7365)
MythZoneMinder: fix an invalid frame no. warning when playing back events

Sometimes while single stepping through the event frames the player would try
to grab frame 0 which will never exist.

(cherry picked from commit ee5de540587a55f8b749da5ece22a15b163619c8)
Limit scheduler sleeping when master backend shutdown is enabled.

The longer sleeps added in a2eb9312 could prevent the pending shutdown
events from being sent.

(cherry picked from commit 7fcc9ccc031eb6418b193b71970ca627c95e1d5c)