Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(65)

Unified Diff: services/media/framework_ffmpeg/av_codec_context.cc

Issue 1814583002: Motown: New wrapper classes for ffmpeg format context and io context (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: services/media/framework_ffmpeg/av_codec_context.cc
diff --git a/services/media/framework_ffmpeg/ffmpeg_type_converters.cc b/services/media/framework_ffmpeg/av_codec_context.cc
similarity index 98%
rename from services/media/framework_ffmpeg/ffmpeg_type_converters.cc
rename to services/media/framework_ffmpeg/av_codec_context.cc
index 9b421ecd97216fd498e96540c7f6e9594534e437..e6a3a14ee2623e7274a8560c4f42fcc10a78c54e 100644
--- a/services/media/framework_ffmpeg/ffmpeg_type_converters.cc
+++ b/services/media/framework_ffmpeg/av_codec_context.cc
@@ -3,7 +3,7 @@
// found in the LICENSE file.
#include "base/logging.h"
-#include "services/media/framework_ffmpeg/ffmpeg_type_converters.h"
+#include "services/media/framework_ffmpeg/av_codec_context.h"
extern "C" {
#include "third_party/ffmpeg/libavformat/avformat.h"
}
@@ -334,7 +334,8 @@ AvCodecContextPtr AVCodecContextFromVideoStreamType(
} // namespace
-std::unique_ptr<StreamType> StreamTypeFromAVCodecContext(
+// static
+std::unique_ptr<StreamType> AvCodecContext::GetStreamType(
const AVCodecContext& from) {
switch (from.codec_type) {
case AVMEDIA_TYPE_AUDIO:
@@ -367,7 +368,8 @@ std::unique_ptr<StreamType> StreamTypeFromAVCodecContext(
}
}
-AvCodecContextPtr AVCodecContextFromStreamType(const StreamType& stream_type) {
+// static
+AvCodecContextPtr AvCodecContext::Create(const StreamType& stream_type) {
switch (stream_type.scheme()) {
case StreamType::Scheme::kLpcm:
return CodecContextFromLpcmDetails(*stream_type.lpcm());

Powered by Google App Engine
This is Rietveld 408576698