Index: webrtc/test/frame_generator_capturer.cc |
diff --git a/webrtc/test/frame_generator_capturer.cc b/webrtc/test/frame_generator_capturer.cc |
index 9e74e40d18bf072b85ab23c2283ded7a2660bc6c..505f5c9c051d3fb2670b69ad543816829e870507 100644 |
--- a/webrtc/test/frame_generator_capturer.cc |
+++ b/webrtc/test/frame_generator_capturer.cc |
@@ -126,6 +126,11 @@ void FrameGeneratorCapturer::SetFakeRotation(VideoRotation rotation) { |
fake_rotation_ = rotation; |
} |
+void FrameGeneratorCapturer::SetFakeContentType(VideoContentType content_type) { |
+ rtc::CritScope cs(&lock_); |
+ fake_video_content_type_ = content_type; |
+} |
+ |
bool FrameGeneratorCapturer::Init() { |
// This check is added because frame_generator_ might be file based and should |
// not crash because a file moved. |
@@ -147,6 +152,7 @@ void FrameGeneratorCapturer::InsertFrame() { |
VideoFrame* frame = frame_generator_->NextFrame(); |
frame->set_ntp_time_ms(clock_->CurrentNtpInMilliseconds()); |
frame->set_rotation(fake_rotation_); |
+ frame->set_content_type(fake_video_content_type_); |
if (first_frame_capture_time_ == -1) { |
first_frame_capture_time_ = frame->ntp_time_ms(); |
} |