summaryrefslogtreecommitdiffstats
path: root/dom/media/platforms/ffmpeg/ffvpx
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 01:13:27 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 01:13:27 +0000
commit40a355a42d4a9444dc753c04c6608dade2f06a23 (patch)
tree871fc667d2de662f171103ce5ec067014ef85e61 /dom/media/platforms/ffmpeg/ffvpx
parentAdding upstream version 124.0.1. (diff)
downloadfirefox-upstream/125.0.1.tar.xz
firefox-upstream/125.0.1.zip
Adding upstream version 125.0.1.upstream/125.0.1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'dom/media/platforms/ffmpeg/ffvpx')
-rw-r--r--dom/media/platforms/ffmpeg/ffvpx/FFVPXRuntimeLinker.cpp14
-rw-r--r--dom/media/platforms/ffmpeg/ffvpx/FFVPXRuntimeLinker.h8
2 files changed, 10 insertions, 12 deletions
diff --git a/dom/media/platforms/ffmpeg/ffvpx/FFVPXRuntimeLinker.cpp b/dom/media/platforms/ffmpeg/ffvpx/FFVPXRuntimeLinker.cpp
index ba9ca4834e..dfc8244f1d 100644
--- a/dom/media/platforms/ffmpeg/ffvpx/FFVPXRuntimeLinker.cpp
+++ b/dom/media/platforms/ffmpeg/ffvpx/FFVPXRuntimeLinker.cpp
@@ -145,19 +145,13 @@ already_AddRefed<PlatformEncoderModule> FFVPXRuntimeLinker::CreateEncoder() {
}
/* static */
-void FFVPXRuntimeLinker::GetRDFTFuncs(FFmpegRDFTFuncs* aOutFuncs) {
+void FFVPXRuntimeLinker::GetFFTFuncs(FFmpegFFTFuncs* aOutFuncs) {
[]() MOZ_NO_THREAD_SAFETY_ANALYSIS {
MOZ_ASSERT(sLinkStatus != LinkStatus_INIT);
}();
- if (sFFVPXLib.av_rdft_init && sFFVPXLib.av_rdft_calc &&
- sFFVPXLib.av_rdft_end) {
- aOutFuncs->init = sFFVPXLib.av_rdft_init;
- aOutFuncs->calc = sFFVPXLib.av_rdft_calc;
- aOutFuncs->end = sFFVPXLib.av_rdft_end;
- } else {
- NS_WARNING("RDFT functions expected but not found");
- *aOutFuncs = FFmpegRDFTFuncs(); // zero
- }
+ MOZ_ASSERT(sFFVPXLib.av_tx_init && sFFVPXLib.av_tx_uninit);
+ aOutFuncs->init = sFFVPXLib.av_tx_init;
+ aOutFuncs->uninit = sFFVPXLib.av_tx_uninit;
}
} // namespace mozilla
diff --git a/dom/media/platforms/ffmpeg/ffvpx/FFVPXRuntimeLinker.h b/dom/media/platforms/ffmpeg/ffvpx/FFVPXRuntimeLinker.h
index e52f108272..dccd37c7da 100644
--- a/dom/media/platforms/ffmpeg/ffvpx/FFVPXRuntimeLinker.h
+++ b/dom/media/platforms/ffmpeg/ffvpx/FFVPXRuntimeLinker.h
@@ -11,8 +11,12 @@
#include "PlatformEncoderModule.h"
#include "mozilla/StaticMutex.h"
#include "mozilla/ThreadSafety.h"
+#include "ffvpx/tx.h"
-struct FFmpegRDFTFuncs;
+struct FFmpegFFTFuncs {
+ decltype(av_tx_init)* init;
+ decltype(av_tx_uninit)* uninit;
+};
namespace mozilla {
@@ -23,7 +27,7 @@ class FFVPXRuntimeLinker {
static already_AddRefed<PlatformEncoderModule> CreateEncoder();
// Call (on any thread) after Init().
- static void GetRDFTFuncs(FFmpegRDFTFuncs* aOutFuncs);
+ static void GetFFTFuncs(FFmpegFFTFuncs* aOutFuncs);
private:
// Provide critical-section for Init() and sLinkStatus.