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

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

Issue 2235623003: cc: Add gfx::ColorSpace to cc::ResourceProvider resource creation (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 4 years, 4 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_impl.cc ('k') | cc/trees/layer_tree_host_unittest_context.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2011 The Chromium Authors. All rights reserved. 1 // Copyright 2011 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/trees/layer_tree_host_impl.h" 5 #include "cc/trees/layer_tree_host_impl.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <algorithm> 9 #include <algorithm>
10 #include <cmath> 10 #include <cmath>
(...skipping 6472 matching lines...) Expand 10 before | Expand all | Expand 10 after
6483 ResourceProvider* resource_provider) 6483 ResourceProvider* resource_provider)
6484 : LayerImpl(tree_impl, id), 6484 : LayerImpl(tree_impl, id),
6485 blend_(false), 6485 blend_(false),
6486 has_render_surface_(false), 6486 has_render_surface_(false),
6487 quads_appended_(false), 6487 quads_appended_(false),
6488 quad_rect_(5, 5, 5, 5), 6488 quad_rect_(5, 5, 5, 5),
6489 quad_visible_rect_(5, 5, 5, 5), 6489 quad_visible_rect_(5, 5, 5, 5),
6490 resource_id_(resource_provider->CreateResource( 6490 resource_id_(resource_provider->CreateResource(
6491 gfx::Size(1, 1), 6491 gfx::Size(1, 1),
6492 ResourceProvider::TEXTURE_HINT_IMMUTABLE, 6492 ResourceProvider::TEXTURE_HINT_IMMUTABLE,
6493 RGBA_8888)) { 6493 RGBA_8888,
6494 gfx::ColorSpace())) {
6494 resource_provider->AllocateForTesting(resource_id_); 6495 resource_provider->AllocateForTesting(resource_id_);
6495 SetBounds(gfx::Size(10, 10)); 6496 SetBounds(gfx::Size(10, 10));
6496 SetDrawsContent(true); 6497 SetDrawsContent(true);
6497 } 6498 }
6498 6499
6499 bool blend_; 6500 bool blend_;
6500 bool has_render_surface_; 6501 bool has_render_surface_;
6501 bool quads_appended_; 6502 bool quads_appended_;
6502 gfx::Rect quad_rect_; 6503 gfx::Rect quad_rect_;
6503 gfx::Rect opaque_content_rect_; 6504 gfx::Rect opaque_content_rect_;
(...skipping 4389 matching lines...) Expand 10 before | Expand all | Expand 10 after
10893 EXPECT_TRUE(host_impl_->use_gpu_rasterization()); 10894 EXPECT_TRUE(host_impl_->use_gpu_rasterization());
10894 10895
10895 // Re-initialize with a software output surface. 10896 // Re-initialize with a software output surface.
10896 output_surface_ = FakeOutputSurface::CreateDelegatingSoftware(); 10897 output_surface_ = FakeOutputSurface::CreateDelegatingSoftware();
10897 host_impl_->InitializeRenderer(output_surface_.get()); 10898 host_impl_->InitializeRenderer(output_surface_.get());
10898 EXPECT_FALSE(host_impl_->use_gpu_rasterization()); 10899 EXPECT_FALSE(host_impl_->use_gpu_rasterization());
10899 } 10900 }
10900 10901
10901 } // namespace 10902 } // namespace
10902 } // namespace cc 10903 } // namespace cc
OLDNEW
« no previous file with comments | « cc/trees/layer_tree_host_impl.cc ('k') | cc/trees/layer_tree_host_unittest_context.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698