0
0
mirror of https://github.com/libretro/Lakka-LibreELEC.git synced 2025-01-09 13:45:21 +00:00
Lakka-LibreELEC/packages/multimedia/ffmpeg/patches/L4T/0022-codecs-nvv4l2-rename-AVCodec-to-fit-API-renames.patch
GavinDarkglider 600e246a94 L4T/Ayn: upstream changes from 5.x
Lakka 5.x Switch changes (#1853)
Lakka v5.x switchroot 5.1.2 (#1871)
Fix Switch Issue's in upstream 5.x (#1888)
Minor Switch Changes (#1893)
Lakka v5.x switch 3 (#1895)
Lakka v5.x switch 4 (#1898)
L4T: Xorg-server: Fix build issue (#1924)
Switch: remove ra patch
Lakka v5.x switch 6 (#1926)
Cleanups, More LibreELEC Stuff, more permission fixes, Misc switch stuff. (#1930)
Switch: U-Boot: bump version to 2024-NX02 (#1946)

L4T/Ayn post-upstreaming fixes
- retroarch_joypad_autoconfig: remove spaces from file names
- retroarch: remove Switch specific patch merged upstream
- libXv: move to L4T packages folder (package removed in upstream)
- bring some packages from v5.x to L4T packages
- ffmpeg: remove vulkan
- remove stella core from Switch build (missing C++ headers)
- Ayn/Odin: use proper kernel arg to not hide kernel messages in console
- connman: add wpa_supplicant support back
2024-05-21 15:41:36 +02:00

102 lines
6.2 KiB
Diff

From b2a7cfdcf77cfd5c3ca864670aa949ddef17cd9a Mon Sep 17 00:00:00 2001
From: Azkali Manad <a.ffcc7@gmail.com>
Date: Wed, 25 Jan 2023 02:02:57 +0100
Subject: [PATCH 22/39] codecs: nvv4l2: rename AVCodec to fit API renames
---
libavcodec/nvv4l2_dec.c | 20 ++++++++++----------
libavcodec/nvv4l2_enc.c | 20 ++++++++++----------
2 files changed, 20 insertions(+), 20 deletions(-)
diff --git a/libavcodec/nvv4l2_dec.c b/libavcodec/nvv4l2_dec.c
index 35784e0704..b56d35cf82 100644
--- a/libavcodec/nvv4l2_dec.c
+++ b/libavcodec/nvv4l2_dec.c
@@ -29,7 +29,7 @@
#include <string.h>
#include <fcntl.h>
#include <errno.h>
-#include "internal.h"
+#include "codec_internal.h"
#include "libavutil/log.h"
#include "nvv4l2.h"
@@ -1203,22 +1203,22 @@ nvv4l2dec_decode(AVCodecContext *avctx, void *data, int *got_frame,
#define NVV4L2_DEC(NAME, ID, BSFS) \
NVV4L2_DEC_CLASS(NAME) \
- AVCodec ff_##NAME##_nvv4l2_decoder = { \
- .name = #NAME "_nvv4l2", \
- .long_name = NULL_IF_CONFIG_SMALL(#NAME " NVV4L2 HW decoder for Tegra"), \
- .type = AVMEDIA_TYPE_VIDEO, \
- .id = ID, \
+ const FFCodec ff_##NAME##_nvv4l2_decoder = { \
+ .p.name = #NAME "_nvv4l2", \
+ .p.long_name = NULL_IF_CONFIG_SMALL(#NAME " NVV4L2 HW decoder for Tegra"), \
+ .p.type = AVMEDIA_TYPE_VIDEO, \
+ .p.id = ID, \
.priv_data_size = sizeof(nvv4l2DecodeContext), \
.init = nvv4l2dec_init, \
.close = nvv4l2dec_close, \
.decode = nvv4l2dec_decode, \
.flush = nvv4l2dec_flush, \
- .priv_class = &nvv4l2_##NAME##_dec_class, \
- .capabilities = AV_CODEC_CAP_DELAY | AV_CODEC_CAP_HARDWARE | \
+ .p.priv_class = &nvv4l2_##NAME##_dec_class, \
+ .p.capabilities = AV_CODEC_CAP_DELAY | AV_CODEC_CAP_HARDWARE | \
AV_CODEC_CAP_AVOID_PROBING, \
.bsfs = BSFS, \
- .wrapper_name = "nvv4l2", \
- .pix_fmts =(const enum AVPixelFormat[]){ AV_PIX_FMT_YUV420P, \
+ .p.wrapper_name = "nvv4l2", \
+ .p.pix_fmts =(const enum AVPixelFormat[]){ AV_PIX_FMT_YUV420P, \
AV_PIX_FMT_NV12, \
AV_PIX_FMT_NONE }, \
};
diff --git a/libavcodec/nvv4l2_enc.c b/libavcodec/nvv4l2_enc.c
index dc09236e0a..fad54868e3 100644
--- a/libavcodec/nvv4l2_enc.c
+++ b/libavcodec/nvv4l2_enc.c
@@ -28,7 +28,7 @@
#include <string.h>
#include <fcntl.h>
#include <errno.h>
-#include "internal.h"
+#include "codec_internal.h"
#include "libavutil/imgutils.h"
#include "libavutil/log.h"
#include "libavutil/opt.h"
@@ -1455,20 +1455,20 @@ static const AVOption options_hevc[] = {
#define NVV4L2_ENC(NAME, ID) \
NVV4L2_ENC_CLASS(NAME) \
- AVCodec ff_##NAME##_nvv4l2_encoder = { \
- .name = #NAME "_nvv4l2" , \
- .long_name = NULL_IF_CONFIG_SMALL(#NAME " NVV4L2 HW encoder for Tegra"), \
- .type = AVMEDIA_TYPE_VIDEO, \
- .id = ID, \
+ const FFCodec ff_##NAME##_nvv4l2_encoder = { \
+ .p.name = #NAME "_nvv4l2" , \
+ .p.long_name = NULL_IF_CONFIG_SMALL(#NAME " NVV4L2 HW encoder for Tegra"), \
+ .p.type = AVMEDIA_TYPE_VIDEO, \
+ .p.id = ID, \
.priv_data_size = sizeof(nvv4l2EncodeContext), \
.init = nvv4l2enc_init, \
.close = nvv4l2enc_close, \
.encode2 = nvv4l2enc_encode, \
- .priv_class = &nvv4l2_##NAME##_enc_class, \
- .capabilities = AV_CODEC_CAP_DELAY | AV_CODEC_CAP_HARDWARE, \
+ .p.priv_class = &nvv4l2_##NAME##_enc_class, \
+ .p.capabilities = AV_CODEC_CAP_DELAY | AV_CODEC_CAP_HARDWARE, \
.defaults = defaults, \
- .wrapper_name = "nvv4l2", \
- .pix_fmts = (const enum AVPixelFormat[]) { AV_PIX_FMT_YUV420P, \
+ .p.wrapper_name = "nvv4l2", \
+ .p.pix_fmts = (const enum AVPixelFormat[]) { AV_PIX_FMT_YUV420P, \
AV_PIX_FMT_YUV444P, \
AV_PIX_FMT_NV12, \
AV_PIX_FMT_P010, \
--
2.25.1