animateMotion fill=“freeze” not work in chrome
Reported by
19420370...@gmail.com,
May 22 2018
|
||||
Issue descriptionUserAgent: Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/65.0.3325.146 Safari/537.36 Steps to reproduce the problem: 1. open the file in chrome 2. open the file in firefox What is the expected behavior? the svg element stop at the end of path What went wrong? animateMotion fill=“freeze” not work in chrome but work in firefox(60.0.1) Did this work before? N/A Does this work in other browsers? Yes Chrome version: 65.0.3325.146 Channel: n/a OS Version: 10.0 Flash Version: there has a codepen demo: https://codepen.io/miaolegemie/pen/BxMjKM
,
May 22 2018
Able to reproduce the issue on windows 10,Mac 10.13.3 & debian using chrome stable-66.0.3359.181 & latest Canary-68.0.3436.0 as per above svg.html. Same issue observed from M60. As it is non regression issue,marking it as Untriaged to get it addressed from dev team. Please find the attached screencast of chrome & mozilla for reference. Thanks..!
,
May 22 2018
hi,I change the path of the <animateMotion> element like the attachment, and it works as expected in chrome. Is there has any rule to avoid this bug?
,
May 22 2018
That's odd... but based on the two examples, it would seem best to avoid degeneracies (the first control point of the bezier being the same as the initial point in svg.html.) Not entirely sure that's cause of the issue of course. Needs more investigation.
,
May 22 2018
I make another 2 demos to test your guess(the first control point of the bezier being the same as the initial point in svg.html.).But unfortunately, your guess seems wrong.the svg-3 file has diffrent first control point and the initial point, but it works wrong in chrome. And the svg-4 file has same first control point and the initial point, but it works as expecte.
,
May 22 2018
What't more,I deleted the number after the decimal point in svg-3 and svg-4 files,and it works as your guess。If the first control point of the bezier being the same as the initial point, it works wrong.
,
May 22 2018
At closer inspection, it looks like it's caused by a numerical issue, so probably not easy to make a general workaround for I'm afraid.
,
May 22 2018
I will use integers and keep the first control point of the bezier being the diffrent as the initial point in my project, and continue to observe this issue.
,
May 23 2018
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/608088846ca78725c5817443a1eaf917c72d0b5a commit 608088846ca78725c5817443a1eaf917c72d0b5a Author: Fredrik Söderquist <fs@opera.com> Date: Wed May 23 11:04:10 2018 Use consistently computed lengths when finding relevant contour In CalculatePointAndNormalOnPath, compute the accumulated length of the contours and compare against the passed in (now unmodified) |length|, to increase the chances of comparing similarly computed length with each other. |length| is often, directly or indirectly, derived from the computed length of the Path (i.e using Path::length().) Bug: 845375 Cq-Include-Trybots: master.tryserver.blink:linux_trusty_blink_rel;master.tryserver.chromium.linux:linux_layout_tests_slimming_paint_v2 Change-Id: Ibda61dd29921f41e0b294edde31ddb21ebbefd08 Reviewed-on: https://chromium-review.googlesource.com/1069071 Commit-Queue: Fredrik Söderquist <fs@opera.com> Reviewed-by: Stephen Chenney <schenney@chromium.org> Reviewed-by: Florin Malita <fmalita@chromium.org> Cr-Commit-Position: refs/heads/master@{#561032} [modify] https://crrev.com/608088846ca78725c5817443a1eaf917c72d0b5a/third_party/blink/renderer/platform/BUILD.gn [modify] https://crrev.com/608088846ca78725c5817443a1eaf917c72d0b5a/third_party/blink/renderer/platform/graphics/path.cc [add] https://crrev.com/608088846ca78725c5817443a1eaf917c72d0b5a/third_party/blink/renderer/platform/graphics/path_test.cc
,
May 23 2018
|
||||
►
Sign in to add a comment |
||||
Comment 1 by ajha@chromium.org
, May 22 2018