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

Unified Diff: media/formats/mp4/bitstream_converter.h

Issue 1289923003: Refactor AnnexB bitstream conversion for AVC/H.264 (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@annexb-avc-fix
Patch Set: BitstreamConverter doesn't need to have MEDIA_EXPORT Created 5 years, 4 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: media/formats/mp4/bitstream_converter.h
diff --git a/media/formats/mp4/bitstream_converter.h b/media/formats/mp4/bitstream_converter.h
new file mode 100644
index 0000000000000000000000000000000000000000..64ccd087d3b27957c97599b0d8fda745c5a172fa
--- /dev/null
+++ b/media/formats/mp4/bitstream_converter.h
@@ -0,0 +1,33 @@
+// Copyright 2015 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef MEDIA_FORMATS_MP4_BITSTREAM_CONVERTER_H_
+#define MEDIA_FORMATS_MP4_BITSTREAM_CONVERTER_H_
+
+#include <vector>
+
+#include "base/basictypes.h"
+#include "base/memory/ref_counted.h"
+
+namespace media {
+
+struct SubsampleEntry;
+
+namespace mp4 {
+
+class BitstreamConverter
+ : public base::RefCountedThreadSafe<BitstreamConverter> {
+ public:
+ virtual bool ConvertFrame(std::vector<uint8>* frame_buf,
sandersd (OOO until July 31) 2015/08/17 18:24:07 Comment what these parameters are. (In particular,
servolk 2015/08/17 22:06:24 Done.
+ bool is_keyframe,
+ std::vector<SubsampleEntry>* subsamples) const = 0;
+ protected:
+ friend class base::RefCountedThreadSafe<BitstreamConverter>;
+ virtual ~BitstreamConverter();
+};
+
+} // namespace mp4
+} // namespace media
+
+#endif // MEDIA_FORMATS_MP4_AVC_H_

Powered by Google App Engine
This is Rietveld 408576698