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

Side by Side Diff: content/browser/renderer_host/media/video_capture_manager_unittest.cc

Issue 2735083002: [Mojo Video Capture] Add test coverage for accelerated jpeg decoding (Closed)
Patch Set: Rebase to March 15th, Remove #include jpeg_parser 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // Unit test for VideoCaptureManager. 5 // Unit test for VideoCaptureManager.
6 6
7 #include "content/browser/renderer_host/media/video_capture_manager.h" 7 #include "content/browser/renderer_host/media/video_capture_manager.h"
8 8
9 #include <stdint.h> 9 #include <stdint.h>
10 10
(...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after
144 MOCK_METHOD2(Opened, void(MediaStreamType, int)); 144 MOCK_METHOD2(Opened, void(MediaStreamType, int));
145 MOCK_METHOD2(Closed, void(MediaStreamType, int)); 145 MOCK_METHOD2(Closed, void(MediaStreamType, int));
146 MOCK_METHOD2(Aborted, void(MediaStreamType, int)); 146 MOCK_METHOD2(Aborted, void(MediaStreamType, int));
147 }; // class MockMediaStreamProviderListener 147 }; // class MockMediaStreamProviderListener
148 148
149 // Needed as an input argument to StartCaptureForClient(). 149 // Needed as an input argument to StartCaptureForClient().
150 class MockFrameObserver : public VideoCaptureControllerEventHandler { 150 class MockFrameObserver : public VideoCaptureControllerEventHandler {
151 public: 151 public:
152 MOCK_METHOD1(OnError, void(VideoCaptureControllerID id)); 152 MOCK_METHOD1(OnError, void(VideoCaptureControllerID id));
153 MOCK_METHOD1(OnStarted, void(VideoCaptureControllerID id)); 153 MOCK_METHOD1(OnStarted, void(VideoCaptureControllerID id));
154 MOCK_METHOD1(OnStartedUsingGpuDecode, void(VideoCaptureControllerID id));
154 155
155 void OnBufferCreated(VideoCaptureControllerID id, 156 void OnBufferCreated(VideoCaptureControllerID id,
156 mojo::ScopedSharedBufferHandle handle, 157 mojo::ScopedSharedBufferHandle handle,
157 int length, int buffer_id) override {} 158 int length, int buffer_id) override {}
158 void OnBufferDestroyed(VideoCaptureControllerID id, int buffer_id) override {} 159 void OnBufferDestroyed(VideoCaptureControllerID id, int buffer_id) override {}
159 void OnBufferReady( 160 void OnBufferReady(
160 VideoCaptureControllerID id, 161 VideoCaptureControllerID id,
161 int buffer_id, 162 int buffer_id,
162 const media::mojom::VideoFrameInfoPtr& frame_info) override {} 163 const media::mojom::VideoFrameInfoPtr& frame_info) override {}
163 void OnEnded(VideoCaptureControllerID id) override {} 164 void OnEnded(VideoCaptureControllerID id) override {}
(...skipping 625 matching lines...) Expand 10 before | Expand all | Expand 10 after
789 // Wait to check callbacks before removing the listener. 790 // Wait to check callbacks before removing the listener.
790 base::RunLoop().RunUntilIdle(); 791 base::RunLoop().RunUntilIdle();
791 vcm_->UnregisterListener(listener_.get()); 792 vcm_->UnregisterListener(listener_.get());
792 } 793 }
793 #endif 794 #endif
794 795
795 // TODO(mcasas): Add a test to check consolidation of the supported formats 796 // TODO(mcasas): Add a test to check consolidation of the supported formats
796 // provided by the device when http://crbug.com/323913 is closed. 797 // provided by the device when http://crbug.com/323913 is closed.
797 798
798 } // namespace content 799 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698