OLD | NEW |
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 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 #include "cc/layers/texture_layer.h" | 5 #include "cc/layers/texture_layer.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <algorithm> | 10 #include <algorithm> |
(...skipping 627 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
638 scoped_refptr<ContextProvider> compositor_context_provider, | 638 scoped_refptr<ContextProvider> compositor_context_provider, |
639 scoped_refptr<ContextProvider> worker_context_provider) override { | 639 scoped_refptr<ContextProvider> worker_context_provider) override { |
640 bool synchronous_composite = | 640 bool synchronous_composite = |
641 !HasImplThread() && | 641 !HasImplThread() && |
642 !layer_tree_host()->GetSettings().single_thread_proxy_scheduler; | 642 !layer_tree_host()->GetSettings().single_thread_proxy_scheduler; |
643 // Allow relaim resources for this test so that mailboxes in the display | 643 // Allow relaim resources for this test so that mailboxes in the display |
644 // will be returned inside the commit that replaces them. | 644 // will be returned inside the commit that replaces them. |
645 bool force_disable_reclaim_resources = false; | 645 bool force_disable_reclaim_resources = false; |
646 return base::MakeUnique<TestCompositorFrameSink>( | 646 return base::MakeUnique<TestCompositorFrameSink>( |
647 compositor_context_provider, std::move(worker_context_provider), | 647 compositor_context_provider, std::move(worker_context_provider), |
648 CreateDisplayOutputSurface(compositor_context_provider), | |
649 shared_bitmap_manager(), gpu_memory_buffer_manager(), | 648 shared_bitmap_manager(), gpu_memory_buffer_manager(), |
650 layer_tree_host()->GetSettings().renderer_settings, | 649 layer_tree_host()->GetSettings().renderer_settings, |
651 ImplThreadTaskRunner(), synchronous_composite, | 650 ImplThreadTaskRunner(), synchronous_composite, |
652 force_disable_reclaim_resources); | 651 force_disable_reclaim_resources); |
653 } | 652 } |
654 | 653 |
655 // Make sure callback is received on main and doesn't block the impl thread. | 654 // Make sure callback is received on main and doesn't block the impl thread. |
656 void ReleaseCallback(char mailbox_char, | 655 void ReleaseCallback(char mailbox_char, |
657 const gpu::SyncToken& sync_token, | 656 const gpu::SyncToken& sync_token, |
658 bool lost_resource) { | 657 bool lost_resource) { |
(...skipping 793 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1452 base::ThreadChecker main_thread_; | 1451 base::ThreadChecker main_thread_; |
1453 int callback_count_; | 1452 int callback_count_; |
1454 scoped_refptr<Layer> root_; | 1453 scoped_refptr<Layer> root_; |
1455 scoped_refptr<TextureLayer> layer_; | 1454 scoped_refptr<TextureLayer> layer_; |
1456 }; | 1455 }; |
1457 | 1456 |
1458 SINGLE_AND_MULTI_THREAD_TEST_F(TextureLayerWithMailboxImplThreadDeleted); | 1457 SINGLE_AND_MULTI_THREAD_TEST_F(TextureLayerWithMailboxImplThreadDeleted); |
1459 | 1458 |
1460 } // namespace | 1459 } // namespace |
1461 } // namespace cc | 1460 } // namespace cc |
OLD | NEW |