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

Unified Diff: webrtc/api/video/video_frame.h

Issue 2772033002: Add content type information to encoded images and corresponding rtp extension header (Closed)
Patch Set: Set EncodedImage content_type from vie_encoder Created 3 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: webrtc/api/video/video_frame.h
diff --git a/webrtc/api/video/video_frame.h b/webrtc/api/video/video_frame.h
index 8840782cad03ba70e69657b227e8ddf7aabfbcb3..c6eb91e9e0547225516662742ad0d6e25016799c 100644
--- a/webrtc/api/video/video_frame.h
+++ b/webrtc/api/video/video_frame.h
@@ -14,6 +14,7 @@
#include <stdint.h>
#include "webrtc/api/video/video_rotation.h"
+#include "webrtc/api/video/video_content_type.h"
#include "webrtc/api/video/video_frame_buffer.h"
// TODO(nisse): Transition hack, some downstream applications expect
@@ -30,13 +31,15 @@ class VideoFrame {
// want to stick to this style and deprecate the other constructor.
VideoFrame(const rtc::scoped_refptr<VideoFrameBuffer>& buffer,
webrtc::VideoRotation rotation,
+ VideoContentTypeId content_type,
int64_t timestamp_us);
// Preferred constructor.
VideoFrame(const rtc::scoped_refptr<VideoFrameBuffer>& buffer,
uint32_t timestamp,
int64_t render_time_ms,
- VideoRotation rotation);
+ VideoRotation rotation,
+ VideoContentTypeId content_type);
~VideoFrame();
@@ -92,6 +95,11 @@ class VideoFrame {
VideoRotation rotation() const { return rotation_; }
void set_rotation(VideoRotation rotation) { rotation_ = rotation; }
+ VideoContentTypeId content_type() const { return content_type_; }
+ void set_content_type(VideoContentTypeId content_type) {
+ content_type_ = content_type;
+ }
+
// Get render time in milliseconds.
// TODO(nisse): Deprecated. Migrate all users to timestamp_us().
int64_t render_time_ms() const;
@@ -113,6 +121,7 @@ class VideoFrame {
int64_t ntp_time_ms_;
int64_t timestamp_us_;
VideoRotation rotation_;
+ VideoContentTypeId content_type_;
};
} // namespace webrtc

Powered by Google App Engine
This is Rietveld 408576698