OLD | NEW |
1 /* | 1 /* |
2 * libjingle | 2 * libjingle |
3 * Copyright 2012 Google Inc. | 3 * Copyright 2012 Google Inc. |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions are met: | 6 * modification, are permitted provided that the following conditions are met: |
7 * | 7 * |
8 * 1. Redistributions of source code must retain the above copyright notice, | 8 * 1. Redistributions of source code must retain the above copyright notice, |
9 * this list of conditions and the following disclaimer. | 9 * this list of conditions and the following disclaimer. |
10 * 2. Redistributions in binary form must reproduce the above copyright notice, | 10 * 2. Redistributions in binary form must reproduce the above copyright notice, |
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
50 0)) { | 50 0)) { |
51 return; | 51 return; |
52 } | 52 } |
53 | 53 |
54 fake_renderer_.RenderFrame(video_frame); | 54 fake_renderer_.RenderFrame(video_frame); |
55 } | 55 } |
56 | 56 |
57 int errors() const { return fake_renderer_.errors(); } | 57 int errors() const { return fake_renderer_.errors(); } |
58 int width() const { return fake_renderer_.width(); } | 58 int width() const { return fake_renderer_.width(); } |
59 int height() const { return fake_renderer_.height(); } | 59 int height() const { return fake_renderer_.height(); } |
| 60 bool black_frame() const { return fake_renderer_.black_frame(); } |
| 61 |
60 int num_rendered_frames() const { | 62 int num_rendered_frames() const { |
61 return fake_renderer_.num_rendered_frames(); | 63 return fake_renderer_.num_rendered_frames(); |
62 } | 64 } |
63 const cricket::VideoFrame* last_frame() const { return last_frame_; } | 65 const cricket::VideoFrame* last_frame() const { return last_frame_; } |
64 | 66 |
65 private: | 67 private: |
66 cricket::FakeVideoRenderer fake_renderer_; | 68 cricket::FakeVideoRenderer fake_renderer_; |
67 rtc::scoped_refptr<VideoTrackInterface> video_track_; | 69 rtc::scoped_refptr<VideoTrackInterface> video_track_; |
68 | 70 |
69 // Weak reference for frame pointer comparison only. | 71 // Weak reference for frame pointer comparison only. |
70 cricket::VideoFrame* last_frame_; | 72 cricket::VideoFrame* last_frame_; |
71 }; | 73 }; |
72 | 74 |
73 } // namespace webrtc | 75 } // namespace webrtc |
74 | 76 |
75 #endif // TALK_APP_WEBRTC_TEST_FAKEVIDEOTRACKRENDERER_H_ | 77 #endif // TALK_APP_WEBRTC_TEST_FAKEVIDEOTRACKRENDERER_H_ |
OLD | NEW |