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

Unified Diff: samplecode/SampleEffects.cpp

Issue 23701006: Push sigma-based blur interface into our GMs/benches/tests/samplecode (Closed) Base URL: http://skia.googlecode.com/svn/trunk/
Patch Set: Cleaned up Created 7 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 side-by-side diff with in-line comments
Download patch
Index: samplecode/SampleEffects.cpp
===================================================================
--- samplecode/SampleEffects.cpp (revision 11004)
+++ samplecode/SampleEffects.cpp (working copy)
@@ -22,14 +22,18 @@
}
static void paint_proc1(SkPaint* paint) {
- paint->setMaskFilter(SkBlurMaskFilter::Create(2,
- SkBlurMaskFilter::kNormal_BlurStyle))->unref();
+ paint->setMaskFilter(SkBlurMaskFilter::Create(
+ SkBlurMaskFilter::kNormal_BlurStyle,
+ SkFloatToScalar(1.6547f)))->unref();
}
static void paint_proc2(SkPaint* paint) {
SkScalar dir[3] = { 1, 1, 1};
paint->setMaskFilter(
- SkBlurMaskFilter::CreateEmboss(dir, 0.1f, 0.05f, 1))->unref();
+ SkBlurMaskFilter::CreateEmboss(SkFloatToScalar(1.07735f),
+ dir,
+ SkFloatToScalar(0.1f),
+ SkFloatToScalar(0.05f)))->unref();
}
static void paint_proc3(SkPaint* paint) {

Powered by Google App Engine
This is Rietveld 408576698