d3 / d3-interpolate

Interpolate numbers, colors, strings, arrays, objects, whatever!

Home Page:https://d3js.org/d3-interpolate

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

interpolateTransform* can't interpolate rotation from 0 to 360 deg

iseeyou911 opened this issue · comments

Hello
interpolateTransform* interpolate rotation with shortest path. So, looks like it's imposible to make interpolation from 0 to 360 deg. I think this is an issue.

if (a - b > 180) b += 360; else if (b - a > 180) a += 360; // shortest path

@iseeyou911 this behavior matches the CSS spec

Duplicate of #44.