1
0
mirror of https://github.com/libretro/Lakka-LibreELEC.git synced 2024-11-24 07:56:21 +00:00
Lakka-LibreELEC/packages/multimedia/ffmpeg/patches/L4T/0030-nvv4l2-add-yuv420p10-support.patch
GavinDarkglider 66e50e96b9
Lakka v5.x switch 6 (#1926)
* L4T: Fix/Enable NVV4l2 decoder in libreelec builds.

* L4T: LibreELEC: Allow Kodi to run as root

* L4T: Small Tree Cleanup

* Bluez: Switch: LibreELEC: Fix fast connect on all switch builds, not just lakka.

* L4T: Finish ffmpeg 6.0 patchset

* L4T: Fix building newer libcec for switch

* L4T: switch-bsp: Update dock hotplug to check distro stuff, before integrating CEC and bump version.
2024-01-29 20:49:02 +02:00

42 lines
1.6 KiB
Diff

From 8014b28095f1b3d2559387b7b8aca93b034561cf Mon Sep 17 00:00:00 2001
From: CTCaer <ctcaer@gmail.com>
Date: Sun, 2 Jul 2023 03:23:34 +0000
Subject: [PATCH 30/39] nvv4l2: add yuv420p10 support NVENC supports yuv420p10
as p010.
---
libavcodec/nvv4l2_enc.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/libavcodec/nvv4l2_enc.c b/libavcodec/nvv4l2_enc.c
index 39a179b255..b979c93051 100644
--- a/libavcodec/nvv4l2_enc.c
+++ b/libavcodec/nvv4l2_enc.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2021-2022, CTCaer <ctcaer@gmail.com>
+ * Copyright (c) 2021-2023, CTCaer <ctcaer@gmail.com>
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
@@ -1130,6 +1130,8 @@ static int nvv4l2enc_init(AVCodecContext *avctx)
case AV_PIX_FMT_NV12:
pix_fmt = V4L2_PIX_FMT_NV12M;
break;
+ case AV_PIX_FMT_YUV420P10:
+ avctx->pix_fmt = AV_PIX_FMT_P010;
case AV_PIX_FMT_P010:
pix_fmt = V4L2_PIX_FMT_P010M;
break;
@@ -1473,6 +1475,7 @@ static const AVOption options_hevc[] = {
AV_PIX_FMT_YUV444P, \
AV_PIX_FMT_NV12, \
AV_PIX_FMT_P010, \
+ AV_PIX_FMT_YUV420P10, \
AV_PIX_FMT_NONE }, \
};
--
2.25.1