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

Unified Diff: samplecode/SampleLighting.cpp

Issue 2237493002: Added PointLights to SkLights::Light (Closed) Base URL: https://skia.googlesource.com/skia@master
Patch Set: fixed serialization bug 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « include/core/SkLights.h ('k') | samplecode/SampleLitAtlas.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: samplecode/SampleLighting.cpp
diff --git a/samplecode/SampleLighting.cpp b/samplecode/SampleLighting.cpp
index 1c86c993624c0d566de2948598f5c01892fcda9f..bab2b5df92270172e75a0099fe6a4245835f8a4e 100755
--- a/samplecode/SampleLighting.cpp
+++ b/samplecode/SampleLighting.cpp
@@ -21,8 +21,8 @@ static sk_sp<SkLights> create_lights(SkScalar angle, SkScalar blue) {
SkLights::Builder builder;
- builder.add(SkLights::Light(SkColor3f::Make(1.0f, 1.0f, blue), dir));
- builder.add(SkLights::Light(SkColor3f::Make(0.1f, 0.1f, 0.1f)));
+ builder.add(SkLights::Light::MakeDirectional(SkColor3f::Make(1.0f, 1.0f, blue), dir));
+ builder.add(SkLights::Light::MakeAmbient(SkColor3f::Make(0.1f, 0.1f, 0.1f)));
return builder.finish();
}
« no previous file with comments | « include/core/SkLights.h ('k') | samplecode/SampleLitAtlas.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698