diff options
author | V3n3RiX <venerix@koprulu.sector> | 2022-08-24 14:48:07 +0100 |
---|---|---|
committer | V3n3RiX <venerix@koprulu.sector> | 2022-08-24 14:48:07 +0100 |
commit | be21a4c281fc76681a84dd2f103e850866ce4946 (patch) | |
tree | 20d33088fd6665896367d97ee3c48a227cfe97d6 /sci-libs/ignition-common | |
parent | 7405d8a728a9553d7b8eccb67737c5193c9f13ba (diff) |
gentoo auto-resync : 24:08:2022 - 14:48:06
Diffstat (limited to 'sci-libs/ignition-common')
-rw-r--r-- | sci-libs/ignition-common/Manifest | 6 | ||||
-rw-r--r-- | sci-libs/ignition-common/files/ffmpeg5.patch | 113 | ||||
-rw-r--r-- | sci-libs/ignition-common/ignition-common-3.14.2.ebuild (renamed from sci-libs/ignition-common/ignition-common-3.14.0.ebuild) | 2 |
3 files changed, 28 insertions, 93 deletions
diff --git a/sci-libs/ignition-common/Manifest b/sci-libs/ignition-common/Manifest index d4cd12b55371..798e53169246 100644 --- a/sci-libs/ignition-common/Manifest +++ b/sci-libs/ignition-common/Manifest @@ -1,4 +1,4 @@ -AUX ffmpeg5.patch 4216 BLAKE2B 4f7c4067b09a609f77c919e4d5d1cbe6b0545d0be208157509d2165d4c8d8f202863fcc53b490fd9494255185e43d262a0a3013429df07c518c5bdedaadaafad SHA512 a558ce55b2ee200e23aba45e0994730b7da50fb419dfdea8348c156cef5f7840043a9905580233c7ee8e5dea665ff486d4f034b333feef140dcf8c53853071d7 -DIST ignition-common3_3.14.0.tar.gz 7171404 BLAKE2B be77615c2b44d446625a2e90302e127dae579137cd150dd66e6e93434f7c345f72b76a6be180303f336ff8b30a45880b64bc8dd148001184b57af1a538531d7a SHA512 53e001751074f69bbe481b27f18da7e8ce9110e4682e9947b88201ca8f0511b20744b6629e2da9914d16144916599ab5b20e56da16115e742739220c9732306b -EBUILD ignition-common-3.14.0.ebuild 965 BLAKE2B 981699831597a4536ff586f43ab3a7d6aee9e12de7a8b3c6f70d64e54e6faaf3c763873b0c7305507bdc04d448981ba2da04dccda0d17dc3c78071bcb1aad5a2 SHA512 7e1b18189c0974a789b65def6818b1c6d96757ffb3e83c5b8967c16e9ae31a30fdf5fc112d5152fe4fbac7c70ce9b725cb2354e5ddaf15744b3c4369b7e55a2a +AUX ffmpeg5.patch 1178 BLAKE2B e02bdb7bd615dcfeb679b39b83fdb31cf7bfe7badeacc87fbb2c5da8ec11a2422075dd0f9346b9cf6720abaf499ecafdb11d5c0c728a5c1a3ed3c883e939c5ef SHA512 601cded6c9f7e4b2928b8d9e50122072cf792fc6a98750b09e71d6eedff96b7c9ef62e3ad786c67704c7b3be41021777bd7a86cccf40e1a086cba6d008eb2bc0 +DIST ignition-common3_3.14.2.tar.gz 7174986 BLAKE2B 38e42f139321aba5ab42c71d874b516bdf7a32edf3d1b0649991e27957d85e1b416d0206cadbeeea12957f7563920952982e4efb813ce8f33520c06e651553cc SHA512 fdc9dfdc8f69ff72e4381af61b3a6e120f361ab21417792db17f85e0ba2d60c4e32df0b72a45101ed72f65ea16a82c95d29e410962e9ecb40c2427a88593bc15 +EBUILD ignition-common-3.14.2.ebuild 974 BLAKE2B b755c0be052b5b5438a6b2306eb3673bd9cc6361980b55a4e371ca6371025c25d6e0a934256921c65a167255dfa0f8101379607887f977fe2e57291d246f6f88 SHA512 65f0492d27f221f2c477001feb8fb0d92322feeb4629c5b6367d8fb00087261b60047f135762718e73621a0dda0cedd5b4fd0576a20207daaf6059a3baff4953 MISC metadata.xml 342 BLAKE2B d5a6fb81442fbf553f05a28de85f698d01e61f34c784ab4cf30c9dce02715a976fa39376c47155d98f144fa4031613c9749605b2eae0af7f03690fed35981398 SHA512 c9394c6ade1913a0785c8018bd6076a403042bc9430c1ba6b6407d701a9a55bd155be17a09c0b1bfdd6b112250818a823e670ef482776a0090e67f49b05166e8 diff --git a/sci-libs/ignition-common/files/ffmpeg5.patch b/sci-libs/ignition-common/files/ffmpeg5.patch index 668b2befeb74..dc0f763072eb 100644 --- a/sci-libs/ignition-common/files/ffmpeg5.patch +++ b/sci-libs/ignition-common/files/ffmpeg5.patch @@ -1,93 +1,28 @@ -Index: ign-common-ignition-common3_3.14.0/av/src/AudioDecoder.cc +Index: gz-common-ignition-common3_3.14.2/graphics/src/Image.cc =================================================================== ---- ign-common-ignition-common3_3.14.0.orig/av/src/AudioDecoder.cc -+++ ign-common-ignition-common3_3.14.0/av/src/AudioDecoder.cc -@@ -35,7 +35,7 @@ class ignition::common::AudioDecoderPriv - public: AVCodecContext *codecCtx; +--- gz-common-ignition-common3_3.14.2.orig/graphics/src/Image.cc ++++ gz-common-ignition-common3_3.14.2/graphics/src/Image.cc +@@ -20,6 +20,7 @@ + #include <FreeImage.h> - /// \brief libavcodec audio codec. -- public: AVCodec *codec; -+ public: const AVCodec *codec; + #include <string> ++#include <cstring> - /// \brief Index of the audio stream. - public: int audioStream; -@@ -132,8 +132,12 @@ bool AudioDecoder::Decode(uint8_t **_out - # pragma GCC diagnostic push - # pragma GCC diagnostic ignored "-Wdeprecated-declarations" - #endif -- bytesDecoded = avcodec_decode_audio4(this->data->codecCtx, decodedFrame, -- &gotFrame, &packet1); -+ bytesDecoded = avcodec_send_packet(this->data->codecCtx, &packet1); -+ if (bytesDecoded >= 0 || bytesDecoded == AVERROR_EOF) { -+ bytesDecoded = avcodec_receive_frame(this->data->codecCtx, decodedFrame); -+ gotFrame = bytesDecoded >= 0; -+ if (bytesDecoded == AVERROR(EAGAIN) || bytesDecoded == AVERROR_EOF) bytesDecoded = 0; -+ } - #ifndef _WIN32 - # pragma GCC diagnostic pop - #endif -@@ -224,7 +228,7 @@ bool AudioDecoder::SetFile(const std::st - # pragma GCC diagnostic push - # pragma GCC diagnostic ignored "-Wdeprecated-declarations" - #endif -- if (this->data->formatCtx->streams[i]->codec->codec_type == // NOLINT(*) -+ if (this->data->formatCtx->streams[i]->codecpar->codec_type == // NOLINT(*) - AVMEDIA_TYPE_AUDIO) - #ifndef _WIN32 - # pragma GCC diagnostic pop -@@ -249,8 +253,9 @@ bool AudioDecoder::SetFile(const std::st - # pragma GCC diagnostic push - # pragma GCC diagnostic ignored "-Wdeprecated-declarations" - #endif -- this->data->codecCtx = this->data->formatCtx->streams[ -- this->data->audioStream]->codec; -+ this->data->codecCtx = avcodec_alloc_context3(nullptr); -+ avcodec_parameters_to_context(this->data->codecCtx, this->data->formatCtx->streams[ -+ this->data->audioStream]->codecpar); - #ifndef _WIN32 - # pragma GCC diagnostic pop - #endif -Index: ign-common-ignition-common3_3.14.0/av/src/Video.cc + #include <ignition/common/Console.hh> + #include <ignition/common/Util.hh> +Index: gz-common-ignition-common3_3.14.2/av/src/AudioDecoder.cc =================================================================== ---- ign-common-ignition-common3_3.14.0.orig/av/src/Video.cc -+++ ign-common-ignition-common3_3.14.0/av/src/Video.cc -@@ -91,7 +91,7 @@ void Video::Cleanup() - ///////////////////////////////////////////////// - bool Video::Load(const std::string &_filename) - { -- AVCodec *codec = nullptr; -+ const AVCodec *codec = nullptr; - this->dataPtr->videoStream = -1; - - if (this->dataPtr->formatCtx || this->dataPtr->avFrame || -Index: ign-common-ignition-common3_3.14.0/av/src/VideoEncoder.cc -=================================================================== ---- ign-common-ignition-common3_3.14.0.orig/av/src/VideoEncoder.cc -+++ ign-common-ignition-common3_3.14.0/av/src/VideoEncoder.cc -@@ -106,7 +106,7 @@ class IGNITION_COMMON_AV_HIDDEN ignition - /// Find a suitable encoder for the given codec ID. - /// \param[in] _codecId ID of the codec we seek the encoder for. - /// \return The matched encoder (or nullptr on failure). -- public: AVCodec* FindEncoder(AVCodecID _codecId); -+ public: const AVCodec* FindEncoder(AVCodecID _codecId); - - /// \brief Get a pointer to the frame that contains the encoder input. This - /// mainly serves for uploading the frame to GPU buffer if HW acceleration is -@@ -123,7 +123,7 @@ class IGNITION_COMMON_AV_HIDDEN ignition - }; - - ///////////////////////////////////////////////// --AVCodec* VideoEncoderPrivate::FindEncoder(AVCodecID _codecId) -+const AVCodec* VideoEncoderPrivate::FindEncoder(AVCodecID _codecId) - { - #ifdef IGN_COMMON_BUILD_HW_VIDEO - if (this->hwEncoder) -@@ -367,7 +367,7 @@ bool VideoEncoder::Start( - } - else - { -- AVOutputFormat *outputFormat = av_guess_format(nullptr, -+ const AVOutputFormat *outputFormat = av_guess_format(nullptr, - this->dataPtr->filename.c_str(), nullptr); - - if (!outputFormat) +--- gz-common-ignition-common3_3.14.2.orig/av/src/AudioDecoder.cc ++++ gz-common-ignition-common3_3.14.2/av/src/AudioDecoder.cc +@@ -157,7 +157,11 @@ bool AudioDecoder::Decode(uint8_t **_out + // decodedFrame->linesize[0]. + int size = decodedFrame->nb_samples * + av_get_bytes_per_sample(this->data->codecCtx->sample_fmt) * ++#if LIBAVCODEC_VERSION_INT >= AV_VERSION_INT(59,24,100) + this->data->codecCtx->ch_layout.nb_channels; ++#else ++ this->data->codecCtx->channels; ++#endif + // Resize the audio buffer as necessary + if (*_outBufferSize + size > maxBufferSize) + { diff --git a/sci-libs/ignition-common/ignition-common-3.14.0.ebuild b/sci-libs/ignition-common/ignition-common-3.14.2.ebuild index 0d31e9ce6c0c..b1328bf00fb2 100644 --- a/sci-libs/ignition-common/ignition-common-3.14.0.ebuild +++ b/sci-libs/ignition-common/ignition-common-3.14.2.ebuild @@ -33,7 +33,7 @@ DEPEND="${RDEPEND} BDEPEND=" dev-util/ignition-cmake:2" -S="${WORKDIR}/ign-common-${PN}${IGN_MAJOR}_${PV}" +S="${WORKDIR}/gz-common-ignition-common${IGN_MAJOR}_${PV}" PATCHES=( "${FILESDIR}/ffmpeg5.patch" ) src_configure() { |