commit | 6789b824015373104bc3282c971e435a9f542f59 | [log] [tgz] |
---|---|---|
author | Jim Van Verth <jvanverth@google.com> | Thu Jul 15 11:37:09 2021 -0400 |
committer | Skia Commit-Bot <skia-commit-bot@chromium.org> | Thu Jul 15 17:22:05 2021 +0000 |
tree | db2001c00e899890069ef7e5bef54956b672a5f9 | |
parent | dfec4f98ef9181ea117faeac4556c95526313b6c [diff] |
Fix directional shadows. The xy offset calculation for drawShadow was not quite correct. Rather than normalizing the light vector and using the xy values of that as the base offset value, we should scale the light vector by 1/z. See https://github.com/flutter/engine/pull/27124#issuecomment-880182653 for more detail. Bug: skia:10781 Change-Id: Ib69a313cb96a532f8d89644e3d69f666a184e897 Reviewed-on: https://skia-review.googlesource.com/c/skia/+/428880 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Jim Van Verth <jvanverth@google.com>