summaryrefslogtreecommitdiffstats
path: root/dom/media/webcodecs/WebCodecsUtils.h
diff options
context:
space:
mode:
Diffstat (limited to 'dom/media/webcodecs/WebCodecsUtils.h')
-rw-r--r--dom/media/webcodecs/WebCodecsUtils.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/dom/media/webcodecs/WebCodecsUtils.h b/dom/media/webcodecs/WebCodecsUtils.h
index 7c0e6b6bbc..196c57421d 100644
--- a/dom/media/webcodecs/WebCodecsUtils.h
+++ b/dom/media/webcodecs/WebCodecsUtils.h
@@ -8,6 +8,7 @@
#define MOZILLA_DOM_WEBCODECS_WEBCODECSUTILS_H
#include "ErrorList.h"
+#include "MediaData.h"
#include "js/TypeDecls.h"
#include "mozilla/Maybe.h"
#include "mozilla/MozPromise.h"
@@ -86,7 +87,11 @@ Nullable<T> MaybeToNullable(const Maybe<T>& aOptional) {
Result<Ok, nsresult> CloneBuffer(
JSContext* aCx,
OwningMaybeSharedArrayBufferViewOrMaybeSharedArrayBuffer& aDest,
- const OwningMaybeSharedArrayBufferViewOrMaybeSharedArrayBuffer& aSrc);
+ const OwningMaybeSharedArrayBufferViewOrMaybeSharedArrayBuffer& aSrc,
+ ErrorResult& aRv);
+
+Result<RefPtr<MediaByteBuffer>, nsresult> GetExtraDataFromArrayBuffer(
+ const OwningMaybeSharedArrayBufferViewOrMaybeSharedArrayBuffer& aBuffer);
/*
* The following are utilities to convert between VideoColorSpace values to
@@ -232,6 +237,8 @@ Maybe<CodecType> CodecStringToCodecType(const nsAString& aCodecString);
nsString ConfigToString(const VideoDecoderConfig& aConfig);
+bool IsSupportedVideoCodec(const nsAString& aCodec);
+
} // namespace dom
} // namespace mozilla