OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2013 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2013 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 #ifndef WEBRTC_VIDEO_ENGINE_TEST_COMMON_FRAME_GENERATOR_CAPTURER_H_ | 10 #ifndef WEBRTC_VIDEO_ENGINE_TEST_COMMON_FRAME_GENERATOR_CAPTURER_H_ |
11 #define WEBRTC_VIDEO_ENGINE_TEST_COMMON_FRAME_GENERATOR_CAPTURER_H_ | 11 #define WEBRTC_VIDEO_ENGINE_TEST_COMMON_FRAME_GENERATOR_CAPTURER_H_ |
12 | 12 |
13 #include <string> | 13 #include <string> |
14 | 14 |
15 #include "webrtc/base/criticalsection.h" | 15 #include "webrtc/base/criticalsection.h" |
16 #include "webrtc/base/scoped_ptr.h" | 16 #include "webrtc/base/scoped_ptr.h" |
17 #include "webrtc/test/video_capturer.h" | 17 #include "webrtc/test/video_capturer.h" |
18 #include "webrtc/typedefs.h" | 18 #include "webrtc/typedefs.h" |
19 | 19 |
20 namespace webrtc { | 20 namespace webrtc { |
21 | 21 |
22 class CriticalSectionWrapper; | 22 class CriticalSectionWrapper; |
23 class EventTimerWrapper; | 23 class EventTimerWrapper; |
24 class ThreadWrapper; | 24 class PlatformThread; |
25 | 25 |
26 namespace test { | 26 namespace test { |
27 | 27 |
28 class FrameGenerator; | 28 class FrameGenerator; |
29 | 29 |
30 class FrameGeneratorCapturer : public VideoCapturer { | 30 class FrameGeneratorCapturer : public VideoCapturer { |
31 public: | 31 public: |
32 static FrameGeneratorCapturer* Create(VideoCaptureInput* input, | 32 static FrameGeneratorCapturer* Create(VideoCaptureInput* input, |
33 size_t width, | 33 size_t width, |
34 size_t height, | 34 size_t height, |
(...skipping 22 matching lines...) Expand all Loading... |
57 | 57 |
58 private: | 58 private: |
59 void InsertFrame(); | 59 void InsertFrame(); |
60 static bool Run(void* obj); | 60 static bool Run(void* obj); |
61 | 61 |
62 Clock* const clock_; | 62 Clock* const clock_; |
63 bool sending_; | 63 bool sending_; |
64 | 64 |
65 rtc::scoped_ptr<EventTimerWrapper> tick_; | 65 rtc::scoped_ptr<EventTimerWrapper> tick_; |
66 rtc::CriticalSection lock_; | 66 rtc::CriticalSection lock_; |
67 rtc::scoped_ptr<ThreadWrapper> thread_; | 67 rtc::scoped_ptr<PlatformThread> thread_; |
68 rtc::scoped_ptr<FrameGenerator> frame_generator_; | 68 rtc::scoped_ptr<FrameGenerator> frame_generator_; |
69 | 69 |
70 int target_fps_; | 70 int target_fps_; |
71 | 71 |
72 int64_t first_frame_capture_time_; | 72 int64_t first_frame_capture_time_; |
73 }; | 73 }; |
74 } // test | 74 } // test |
75 } // webrtc | 75 } // webrtc |
76 | 76 |
77 #endif // WEBRTC_VIDEO_ENGINE_TEST_COMMON_FRAME_GENERATOR_CAPTURER_H_ | 77 #endif // WEBRTC_VIDEO_ENGINE_TEST_COMMON_FRAME_GENERATOR_CAPTURER_H_ |
OLD | NEW |