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

Unified Diff: bench/ColorFilterBench.cpp

Issue 175293002: Factory methods for heap-allocated SkColorFilter objects. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 6 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | gm/colorfilterimagefilter.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: bench/ColorFilterBench.cpp
diff --git a/bench/ColorFilterBench.cpp b/bench/ColorFilterBench.cpp
index 9fec587b5c0a56bce6677592d97b32e2e7dcdb23..3d9515477c7e52b222db7c2785028d766f35f2ad 100644
--- a/bench/ColorFilterBench.cpp
+++ b/bench/ColorFilterBench.cpp
@@ -33,7 +33,7 @@ protected:
0, 1, 0, 0, amount255,
0, 0, 1, 0, amount255,
0, 0, 0, 1, 0 };
- SkAutoTUnref<SkColorFilter> filter(new SkColorMatrixFilter(matrix));
+ SkAutoTUnref<SkColorFilter> filter(SkColorMatrixFilter::Create(matrix));
return SkColorFilterImageFilter::Create(filter, input);
}
@@ -44,7 +44,7 @@ protected:
matrix[1] = matrix[6] = matrix[11] = 0.7152f;
matrix[2] = matrix[7] = matrix[12] = 0.0722f;
matrix[18] = 1.0f;
- SkAutoTUnref<SkColorFilter> filter(new SkColorMatrixFilter(matrix));
+ SkAutoTUnref<SkColorFilter> filter(SkColorMatrixFilter::Create(matrix));
return SkColorFilterImageFilter::Create(filter, input);
}
« no previous file with comments | « no previous file | gm/colorfilterimagefilter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698