From ff8368c6066faf3962e2f77af7da4954e2ff6a43 Mon Sep 17 00:00:00 2001 From: lizzie Date: Sat, 12 Sep 2026 09:59:33 +0200 Subject: [audio] Replace libopus with FFmpeg (#4169) FFmpeg offers two opus decoders: - libopus, this one is fed the same data (that affects output) as the previous libopus decoder had as well - native opus decoder: this only takes Float32 samples, we then need to invoke swrescale to translate between s16 (what switch sends) and float32 (what FFmpeg expects), the process is computationally more expensive, but trades off neatly as the native opus decoder is very optimised It also relegates the handling to FFmpeg, which simplifies existing code (more concretely, by using the "fill/drain" scheme for packets/frames) Closes #2897 Signed-off-by: lizzie Co-authored-by: crueter Reviewed-on: https://git.eden-emu.dev/eden-emu/eden/pulls/4169 Reviewed-by: CamilleLaVey Reviewed-by: Maufeat --- CMakeModules/find/FindOpus.cmake | 22 ---------------------- 1 file changed, 22 deletions(-) delete mode 100644 CMakeModules/find/FindOpus.cmake (limited to 'CMakeModules') diff --git a/CMakeModules/find/FindOpus.cmake b/CMakeModules/find/FindOpus.cmake deleted file mode 100644 index 257642682e..0000000000 --- a/CMakeModules/find/FindOpus.cmake +++ /dev/null @@ -1,22 +0,0 @@ -# SPDX-FileCopyrightText: Copyright 2026 Eden Emulator Project -# SPDX-License-Identifier: GPL-3.0-or-later - -# SPDX-FileCopyrightText: 2022 yuzu Emulator Project -# SPDX-License-Identifier: GPL-2.0-or-later - -find_package(PkgConfig QUIET) -pkg_search_module(OPUS QUIET IMPORTED_TARGET opus) - -include(FindPackageHandleStandardArgs) -find_package_handle_standard_args(Opus - REQUIRED_VARS OPUS_LINK_LIBRARIES - VERSION_VAR OPUS_VERSION -) - -if (MSYS2) - FixMsysPath(PkgConfig::OPUS) -endif() - -if (Opus_FOUND AND NOT TARGET Opus::opus) - add_library(Opus::opus ALIAS PkgConfig::OPUS) -endif() -- cgit v1.2.3