Skip to content

Commit

Permalink
🏜️
Browse files Browse the repository at this point in the history
  • Loading branch information
rreusser committed Dec 28, 2022
1 parent 628ee7f commit d9252a2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion cubic-roots/bundle.js

Large diffs are not rendered by default.

2 changes: 2 additions & 0 deletions src/src/cubic-roots/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -310,6 +310,8 @@ function run (regl) {
case 'tri':
const dy = y - yScale.invert(state.yOffset);
const dx = x - state.center;
const rad = Math.hypot(dx, dy);
state.radius = rad;
state.alpha = Math.atan2(dy, dx);
break;
case 'center':
Expand Down

0 comments on commit d9252a2

Please sign in to comment.