diff options
author | dvonbeck <dvonbeck@google.com> | 2016-07-28 08:58:19 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-07-28 08:58:19 -0700 |
commit | bba4cfebcabba3aca5c2452d7df1853258bd701c (patch) | |
tree | f3675119f7a7437c9fdfb5089f9f31f018095b08 /tests/SerializationTest.cpp | |
parent | 1c58696112a5d7bf1acbcc337099b0bf5eb80650 (diff) |
Added API for Bevel NormalSource.
This CL adds an API for Bevel normal source and a dummy implementation that returns a normal (0, 0, 1) every time.
This CL's base is the CL for accepting nullptrs: https://codereview.chromium.org/2132113002
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2080993002
Review-Url: https://codereview.chromium.org/2080993002
Diffstat (limited to 'tests/SerializationTest.cpp')
-rw-r--r-- | tests/SerializationTest.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/SerializationTest.cpp b/tests/SerializationTest.cpp index f806c4a5cc..a6be1889a5 100644 --- a/tests/SerializationTest.cpp +++ b/tests/SerializationTest.cpp @@ -608,6 +608,17 @@ DEF_TEST(Serialization, reporter) { fLights); SkAutoTUnref<SkShader>(TestFlattenableSerialization(lightingShader.get(), true, reporter)); } + + // Test NormalBevelSource serialization + { + sk_sp<SkNormalSource> bevelSource = SkNormalSource::MakeBevel( + SkNormalSource::BevelType::kLinear, 2.0f, 5.0f); + + SkAutoTUnref<SkNormalSource>(TestFlattenableSerialization(bevelSource.get(), true, + reporter)); + // TODO test equality? + + } } /////////////////////////////////////////////////////////////////////////////////////////////////// |