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

Side by Side Diff: cc/trees/layer_tree_host_unittest_context.cc

Issue 1869983002: Remove IOSurfaceLayer (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 8 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
« no previous file with comments | « cc/trees/layer_tree_host_unittest.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 <stddef.h> 5 #include <stddef.h>
6 #include <stdint.h> 6 #include <stdint.h>
7 7
8 #include "base/memory/ptr_util.h" 8 #include "base/memory/ptr_util.h"
9 #include "cc/layers/heads_up_display_layer.h" 9 #include "cc/layers/heads_up_display_layer.h"
10 #include "cc/layers/io_surface_layer.h"
11 #include "cc/layers/layer_impl.h" 10 #include "cc/layers/layer_impl.h"
12 #include "cc/layers/painted_scrollbar_layer.h" 11 #include "cc/layers/painted_scrollbar_layer.h"
13 #include "cc/layers/picture_layer.h" 12 #include "cc/layers/picture_layer.h"
14 #include "cc/layers/texture_layer.h" 13 #include "cc/layers/texture_layer.h"
15 #include "cc/layers/texture_layer_impl.h" 14 #include "cc/layers/texture_layer_impl.h"
16 #include "cc/layers/video_layer.h" 15 #include "cc/layers/video_layer.h"
17 #include "cc/layers/video_layer_impl.h" 16 #include "cc/layers/video_layer_impl.h"
18 #include "cc/output/filter_operations.h" 17 #include "cc/output/filter_operations.h"
19 #include "cc/resources/single_release_callback.h" 18 #include "cc/resources/single_release_callback.h"
20 #include "cc/test/failure_output_surface.h" 19 #include "cc/test/failure_output_surface.h"
(...skipping 994 matching lines...) Expand 10 before | Expand all | Expand 10 after
1015 media::PIXEL_FORMAT_ARGB, 1014 media::PIXEL_FORMAT_ARGB,
1016 gpu::MailboxHolder(mailbox, sync_token, GL_TEXTURE_2D), 1015 gpu::MailboxHolder(mailbox, sync_token, GL_TEXTURE_2D),
1017 media::VideoFrame::ReleaseMailboxCB(), gfx::Size(4, 4), 1016 media::VideoFrame::ReleaseMailboxCB(), gfx::Size(4, 4),
1018 gfx::Rect(0, 0, 3, 2), gfx::Size(4, 4), base::TimeDelta()); 1017 gfx::Rect(0, 0, 3, 2), gfx::Size(4, 4), base::TimeDelta());
1019 ASSERT_TRUE(scaled_hw_video_frame_); 1018 ASSERT_TRUE(scaled_hw_video_frame_);
1020 1019
1021 color_frame_provider_.set_frame(color_video_frame_); 1020 color_frame_provider_.set_frame(color_video_frame_);
1022 hw_frame_provider_.set_frame(hw_video_frame_); 1021 hw_frame_provider_.set_frame(hw_video_frame_);
1023 scaled_hw_frame_provider_.set_frame(scaled_hw_video_frame_); 1022 scaled_hw_frame_provider_.set_frame(scaled_hw_video_frame_);
1024 1023
1025 scoped_refptr<IOSurfaceLayer> io_surface = IOSurfaceLayer::Create();
1026 io_surface->SetBounds(gfx::Size(10, 10));
1027 io_surface->SetIsDrawable(true);
1028 io_surface->SetIOSurfaceProperties(1, gfx::Size(10, 10));
1029 root->AddChild(io_surface);
1030
1031 // Enable the hud. 1024 // Enable the hud.
1032 LayerTreeDebugState debug_state; 1025 LayerTreeDebugState debug_state;
1033 debug_state.show_property_changed_rects = true; 1026 debug_state.show_property_changed_rects = true;
1034 layer_tree_host()->SetDebugState(debug_state); 1027 layer_tree_host()->SetDebugState(debug_state);
1035 1028
1036 scoped_refptr<PaintedScrollbarLayer> scrollbar = 1029 scoped_refptr<PaintedScrollbarLayer> scrollbar =
1037 PaintedScrollbarLayer::Create( 1030 PaintedScrollbarLayer::Create(
1038 std::unique_ptr<Scrollbar>(new FakeScrollbar), layer->id()); 1031 std::unique_ptr<Scrollbar>(new FakeScrollbar), layer->id());
1039 scrollbar->SetBounds(gfx::Size(10, 10)); 1032 scrollbar->SetBounds(gfx::Size(10, 10));
1040 scrollbar->SetIsDrawable(true); 1033 scrollbar->SetIsDrawable(true);
(...skipping 569 matching lines...) Expand 10 before | Expand all | Expand 10 after
1610 void AfterTest() override {} 1603 void AfterTest() override {}
1611 1604
1612 bool deferred_; 1605 bool deferred_;
1613 }; 1606 };
1614 1607
1615 SINGLE_AND_MULTI_THREAD_TEST_F( 1608 SINGLE_AND_MULTI_THREAD_TEST_F(
1616 LayerTreeHostContextTestLoseAfterSendingBeginMainFrame); 1609 LayerTreeHostContextTestLoseAfterSendingBeginMainFrame);
1617 1610
1618 } // namespace 1611 } // namespace
1619 } // namespace cc 1612 } // namespace cc
OLDNEW
« no previous file with comments | « cc/trees/layer_tree_host_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698