John Stebbins [Sun, 24 Feb 2019 20:53:56 +0000 (13:53 -0700)]
flatpak: add Intel MediaSDK plugin
Defines a flatpak manifest that is used to download and build all the
dependencies for MediaSDK 19.1.pre2. These are built into a flatpak
plugin that can be installed independently from the main HandBrake flatpak.
When the plugin is installed, HandBrake gains the ability to do QSV
encoding with the latest MediaSDK and VA drivers.
When HandBrake is configured with '--flatpak --enable-qsv' and
'make pkg.create.flatpak' is run, both the HandBrake flatpak and the
MediaSDK plugin will be built.
The name of the MediaSDK plugin file is:
fr.handbrake.plugin.IntelMediaSDK-$(HB.version)-$(HB.machine).flatpak
I've also changed the the name of the HandBrake flatpak file to conform
better with flatpak naming:
fr.handbrake.ghb-$(HB.version)-$(HB.machine).flatpak
fr.handbrake.HandBrakeCLI-$(HB.version)-$(HB.machine).flatpak
John Stebbins [Fri, 22 Feb 2019 22:07:04 +0000 (15:07 -0700)]
LinGui: make QSV encoding actually work
Assuming you built HandBrake with 'configure --enable-qsv' and you have
built and installed Intel MediaSDK in a directory that is in your LD search
path, the QSV encoders now work. HW decode is not supported.
Frederick Ding [Wed, 27 Feb 2019 22:09:24 +0000 (22:09 +0000)]
Fix Py3 compat and logic/syntax in handling version.txt
The first fix addresses the problem that readlines() gives back a
list of strings, which do not have the `.decode()` method that bytes do.
But `_parseSession()` is used both for the bytes output by running
`repo-info.sh` and for the strings output by ingesting `version.txt`.
So we still need to handle the bytes case.
The second fix addresses syntax and logic problems. If a string is
not empty, `if self.hash` will check that it's non-empty (I don't think
`is not empty` actually works -- it has given me a NameError). And the
string comparison should be done by value equality, not reference
equality.
John Stebbins [Wed, 13 Feb 2019 17:00:12 +0000 (10:00 -0700)]
CLI: interpret --all-audio as implicit list of all tracks
--all-audio was setting up the preset to apply each audio encoder in the
preset to each source track. And it was adding new entries in the presets
audio encoder list for any audio command line overrides. This results in very
unintuitive behavior.
Nomis101 [Mon, 11 Feb 2019 16:22:04 +0000 (17:22 +0100)]
MacGui: update German localization (housekeeping #1)
This is the housekeeping #1 2019 set of german localization changes from Transifex. It does not include new strings from recent macos patches, just fixes and corrections.
John Stebbins [Sun, 10 Feb 2019 20:04:21 +0000 (13:04 -0700)]
decavcodec: fix error when ffmpeg parser changes the codec_id
The ffmpeg mpeg2 parser changes AVCodecContext.codec_id on the fly based
on what it parses. Normally this results in correct switching of decoders
internally in ffmpeg. Due to some unfortunate ordering of how we initialize
things when HandBrake is using our own demuxers, avcodec_open gets called
with the original AVCodec and the AVCodecContext.codec_id that was changed
by the parser resulting in an error.
Further explanation... When using our own demuxers, there are some codecs that
we have to parse out the extradata for _prior_ to calling avcodec_open.
avcodec_open fails if extradata isn't initialized for these codecs prior to
the call. To initialize the extradata, we use parser->parser->split. I.e. the
parser must be initialized and used prior to calling avcodec_open. When
avcodec_open is called, it is using the original AVCodec that was used with
avcodec_alloc_context3 (it will fail if AVCodec is not the same between
avcodec_alloc_context3 and avccodec_open). The call to avcodec_open fails with
"Codec type or id mismatches" since AVCodecContext.codec_id no longer matches
AVCodec.id due to the parser changing the codec_id.
The solution is to reset AVCodec and reallocate the context when we
detect that the parser has changed codec_id on us.
sr55 [Mon, 11 Feb 2019 14:25:46 +0000 (14:25 +0000)]
WinGui: Utilise new hb_global_init_no_hardware when hb_global_init fails. The preferences Video tab now notes that hardware encoding options are disabled.