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

Side by Side Diff: webrtc/media/engine/fakewebrtcvideocapturemodule.h

Issue 2772033002: Add content type information to encoded images and corresponding rtp extension header (Closed)
Patch Set: Fix Mac CE Created 3 years, 8 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2004 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2004 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
65 void SendFrame(int w, int h) { 65 void SendFrame(int w, int h) {
66 if (!running_) return; 66 if (!running_) return;
67 67
68 rtc::scoped_refptr<webrtc::I420Buffer> buffer = 68 rtc::scoped_refptr<webrtc::I420Buffer> buffer =
69 webrtc::I420Buffer::Create(w, h); 69 webrtc::I420Buffer::Create(w, h);
70 // Initialize memory to satisfy DrMemory tests. See 70 // Initialize memory to satisfy DrMemory tests. See
71 // https://bugs.chromium.org/p/libyuv/issues/detail?id=377 71 // https://bugs.chromium.org/p/libyuv/issues/detail?id=377
72 buffer->InitializeData(); 72 buffer->InitializeData();
73 if (callback_) { 73 if (callback_) {
74 callback_->OnFrame( 74 callback_->OnFrame(
75 webrtc::VideoFrame(buffer, 0, 0, webrtc::kVideoRotation_0)); 75 webrtc::VideoFrame(buffer, 0, 0, webrtc::kVideoRotation_0,
76 webrtc::VideoContentType::kDefault));
76 } 77 }
77 } 78 }
78 79
79 const webrtc::VideoCaptureCapability& cap() const { 80 const webrtc::VideoCaptureCapability& cap() const {
80 return cap_; 81 return cap_;
81 } 82 }
82 83
83 private: 84 private:
84 FakeWebRtcVcmFactory* factory_; 85 FakeWebRtcVcmFactory* factory_;
85 rtc::VideoSinkInterface<webrtc::VideoFrame>* callback_; 86 rtc::VideoSinkInterface<webrtc::VideoFrame>* callback_;
86 bool running_; 87 bool running_;
87 webrtc::VideoCaptureCapability cap_; 88 webrtc::VideoCaptureCapability cap_;
88 }; 89 };
89 90
90 #endif // WEBRTC_MEDIA_ENGINE_FAKEWEBRTCVIDEOCAPTUREMODULE_H_ 91 #endif // WEBRTC_MEDIA_ENGINE_FAKEWEBRTCVIDEOCAPTUREMODULE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698