| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 #include "cc/test/pixel_test.h" | 5 #include "cc/test/pixel_test.h" |
| 6 | 6 |
| 7 #include "base/path_service.h" | 7 #include "base/path_service.h" |
| 8 #include "base/run_loop.h" | 8 #include "base/run_loop.h" |
| 9 #include "cc/output/compositor_frame_metadata.h" | 9 #include "cc/output/compositor_frame_metadata.h" |
| 10 #include "cc/output/copy_output_request.h" | 10 #include "cc/output/copy_output_request.h" |
| (...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 54 virtual bool AllowPartialSwap() const OVERRIDE { | 54 virtual bool AllowPartialSwap() const OVERRIDE { |
| 55 return true; | 55 return true; |
| 56 } | 56 } |
| 57 | 57 |
| 58 // OutputSurfaceClient implementation. | 58 // OutputSurfaceClient implementation. |
| 59 virtual bool DeferredInitialize( | 59 virtual bool DeferredInitialize( |
| 60 scoped_refptr<ContextProvider> offscreen_context_provider) OVERRIDE { | 60 scoped_refptr<ContextProvider> offscreen_context_provider) OVERRIDE { |
| 61 return false; | 61 return false; |
| 62 } | 62 } |
| 63 virtual void SetNeedsRedrawRect(gfx::Rect damage_rect) OVERRIDE {} | 63 virtual void SetNeedsRedrawRect(gfx::Rect damage_rect) OVERRIDE {} |
| 64 virtual void BeginFrame(base::TimeTicks frame_time) OVERRIDE {} | 64 virtual void BeginFrame(const BeginFrameArgs& args) OVERRIDE {} |
| 65 virtual void OnSwapBuffersComplete(const CompositorFrameAck* ack) OVERRIDE {} | 65 virtual void OnSwapBuffersComplete(const CompositorFrameAck* ack) OVERRIDE {} |
| 66 virtual void DidLoseOutputSurface() OVERRIDE {} | 66 virtual void DidLoseOutputSurface() OVERRIDE {} |
| 67 virtual void SetExternalDrawConstraints(const gfx::Transform& transform, | 67 virtual void SetExternalDrawConstraints(const gfx::Transform& transform, |
| 68 gfx::Rect viewport) OVERRIDE { | 68 gfx::Rect viewport) OVERRIDE { |
| 69 device_viewport_ = viewport; | 69 device_viewport_ = viewport; |
| 70 } | 70 } |
| 71 | 71 |
| 72 private: | 72 private: |
| 73 gfx::Rect device_viewport_; | 73 gfx::Rect device_viewport_; |
| 74 LayerTreeSettings settings_; | 74 LayerTreeSettings settings_; |
| (...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 182 output_surface_.reset(new PixelTestOutputSurface(device.Pass())); | 182 output_surface_.reset(new PixelTestOutputSurface(device.Pass())); |
| 183 output_surface_->BindToClient(fake_client_.get()); | 183 output_surface_->BindToClient(fake_client_.get()); |
| 184 resource_provider_ = ResourceProvider::Create(output_surface_.get(), 0); | 184 resource_provider_ = ResourceProvider::Create(output_surface_.get(), 0); |
| 185 renderer_ = SoftwareRenderer::Create( | 185 renderer_ = SoftwareRenderer::Create( |
| 186 fake_client_.get(), | 186 fake_client_.get(), |
| 187 output_surface_.get(), | 187 output_surface_.get(), |
| 188 resource_provider_.get()).PassAs<DirectRenderer>(); | 188 resource_provider_.get()).PassAs<DirectRenderer>(); |
| 189 } | 189 } |
| 190 | 190 |
| 191 } // namespace cc | 191 } // namespace cc |
| OLD | NEW |