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

Side by Side Diff: content/common/cc_messages_unittest.cc

Issue 271073002: Use factory methods for Skia effects in unit tests. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 7 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 | Annotate | Revision Log
« no previous file with comments | « cc/trees/layer_tree_host_pixeltest_filters.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 (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 #include "content/common/cc_messages.h" 5 #include "content/common/cc_messages.h"
6 6
7 #include <string.h> 7 #include <string.h>
8 8
9 #include <algorithm> 9 #include <algorithm>
10 10
(...skipping 249 matching lines...) Expand 10 before | Expand all | Expand 10 after
260 ResourceProvider::ResourceId arbitrary_resourceid3 = 23; 260 ResourceProvider::ResourceId arbitrary_resourceid3 = 23;
261 ResourceProvider::ResourceId arbitrary_resourceid4 = 16; 261 ResourceProvider::ResourceId arbitrary_resourceid4 = 16;
262 SkScalar arbitrary_sigma = SkFloatToScalar(2.0f); 262 SkScalar arbitrary_sigma = SkFloatToScalar(2.0f);
263 YUVVideoDrawQuad::ColorSpace arbitrary_color_space = 263 YUVVideoDrawQuad::ColorSpace arbitrary_color_space =
264 YUVVideoDrawQuad::REC_601; 264 YUVVideoDrawQuad::REC_601;
265 265
266 FilterOperations arbitrary_filters1; 266 FilterOperations arbitrary_filters1;
267 arbitrary_filters1.Append(FilterOperation::CreateGrayscaleFilter( 267 arbitrary_filters1.Append(FilterOperation::CreateGrayscaleFilter(
268 arbitrary_float1)); 268 arbitrary_float1));
269 skia::RefPtr<SkImageFilter> arbitrary_filter = skia::AdoptRef( 269 skia::RefPtr<SkImageFilter> arbitrary_filter = skia::AdoptRef(
270 new SkBlurImageFilter(arbitrary_sigma, arbitrary_sigma)); 270 SkBlurImageFilter::Create(arbitrary_sigma, arbitrary_sigma));
271 arbitrary_filters1.Append( 271 arbitrary_filters1.Append(
272 cc::FilterOperation::CreateReferenceFilter(arbitrary_filter)); 272 cc::FilterOperation::CreateReferenceFilter(arbitrary_filter));
273 273
274 FilterOperations arbitrary_filters2; 274 FilterOperations arbitrary_filters2;
275 arbitrary_filters2.Append(FilterOperation::CreateBrightnessFilter( 275 arbitrary_filters2.Append(FilterOperation::CreateBrightnessFilter(
276 arbitrary_float2)); 276 arbitrary_float2));
277 277
278 scoped_ptr<RenderPass> pass_in = RenderPass::Create(); 278 scoped_ptr<RenderPass> pass_in = RenderPass::Create();
279 pass_in->SetAll(arbitrary_id, 279 pass_in->SetAll(arbitrary_id,
280 arbitrary_rect1, 280 arbitrary_rect1,
(...skipping 527 matching lines...) Expand 10 before | Expand all | Expand 10 after
808 SoftwareFrameData frame_out; 808 SoftwareFrameData frame_out;
809 PickleIterator iter(msg); 809 PickleIterator iter(msg);
810 EXPECT_EQ( 810 EXPECT_EQ(
811 expect_read, 811 expect_read,
812 IPC::ParamTraits<SoftwareFrameData>::Read(&msg, &iter, &frame_out)); 812 IPC::ParamTraits<SoftwareFrameData>::Read(&msg, &iter, &frame_out));
813 } 813 }
814 } 814 }
815 815
816 } // namespace 816 } // namespace
817 } // namespace content 817 } // namespace content
OLDNEW
« no previous file with comments | « cc/trees/layer_tree_host_pixeltest_filters.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698