summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJakov Smolic <jakov.smolic@sartura.hr>2020-08-14 22:06:50 +0200
committerSam James <sam@gentoo.org>2020-08-16 06:18:15 +0000
commit87a3129de24ace71bad061eab0830305db2b1f30 (patch)
treeb5a27a665dddc488597e16e6f09c9ed99903723e /media-libs/libheif/files/libheif-1.7.0-aom.patch
parentdev-ruby/histogram: avoid unneeded test dependency (diff)
downloadgentoo-87a3129de24ace71bad061eab0830305db2b1f30.tar.gz
gentoo-87a3129de24ace71bad061eab0830305db2b1f30.tar.bz2
gentoo-87a3129de24ace71bad061eab0830305db2b1f30.zip
media-libs/libheif: bump to 1.7.0
Closes: https://bugs.gentoo.org/720166 Package-Manager: Portage-2.3.99, Repoman-2.3.23 Signed-off-by: Jakov Smolic <jakov.smolic@sartura.hr> Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'media-libs/libheif/files/libheif-1.7.0-aom.patch')
-rw-r--r--media-libs/libheif/files/libheif-1.7.0-aom.patch46
1 files changed, 46 insertions, 0 deletions
diff --git a/media-libs/libheif/files/libheif-1.7.0-aom.patch b/media-libs/libheif/files/libheif-1.7.0-aom.patch
new file mode 100644
index 00000000000..9dce291f964
--- /dev/null
+++ b/media-libs/libheif/files/libheif-1.7.0-aom.patch
@@ -0,0 +1,46 @@
+From 331dff0ba58d5265ddcdadeaf5a45c1f0698a388 Mon Sep 17 00:00:00 2001
+From: Jakov Smolic <jakov.smolic@sartura.hr>
+Date: Fri, 14 Aug 2020 22:03:25 +0200
+Subject: [PATCH] Fix building against aom 1.0
+
+Taken from upstream commit:
+https://github.com/strukturag/libheif/commit/6768552c0a99bb2957906be0f369850326486a58
+
+Signed-off-by: Jakov Smolic <jakov.smolic@sartura.hr>
+---
+ libheif/heif_encoder_aom.cc | 11 ++++++++---
+ 1 file changed, 8 insertions(+), 3 deletions(-)
+
+diff --git a/libheif/heif_encoder_aom.cc b/libheif/heif_encoder_aom.cc
+index 9953e34..669a51a 100644
+--- a/libheif/heif_encoder_aom.cc
++++ b/libheif/heif_encoder_aom.cc
+@@ -502,9 +502,11 @@ struct heif_error aom_encode_image(void* encoder_raw, const struct heif_image* i
+
+
+ // --- configure codec
+-
+- unsigned int aomUsage = (encoder->realtime_mode ? AOM_USAGE_REALTIME : AOM_USAGE_GOOD_QUALITY);
+-
++ unsigned int aomUsage = 0;
++#if defined(AOM_USAGE_REALTIME)
++ // aom 2.0
++ aomUsage = (encoder->realtime_mode ? AOM_USAGE_REALTIME : AOM_USAGE_GOOD_QUALITY);
++#endif
+
+ aom_codec_enc_cfg_t cfg;
+ aom_codec_err_t res = aom_codec_enc_config_default(encoder->iface, &cfg, aomUsage);
+@@ -540,7 +542,10 @@ struct heif_error aom_encode_image(void* encoder_raw, const struct heif_image* i
+ aom_codec_control(&encoder->codec, AOME_SET_CPUUSED, encoder->cpu_used);
+
+ if (encoder->threads > 1) {
++#if defined(AV1E_SET_ROW_MT)
++ // aom 2.0
+ aom_codec_control(&encoder->codec, AV1E_SET_ROW_MT, 1);
++#endif
+ }
+
+ // --- encode frame
+--
+2.26.2
+