forcegraph: partially revert framerate limiting
This commit is contained in:
parent
ef7f60179a
commit
9317346dfe
@ -236,18 +236,7 @@ define(["d3"], function (d3) {
|
|||||||
d.y + margin > screenRect.top && d.y - margin < screenRect.bottom
|
d.y + margin > screenRect.top && d.y - margin < screenRect.bottom
|
||||||
}
|
}
|
||||||
|
|
||||||
var oldTime = 0
|
function redraw() {
|
||||||
|
|
||||||
function redraw(time) {
|
|
||||||
var deltaTime = time - oldTime
|
|
||||||
|
|
||||||
if (deltaTime < 20) {
|
|
||||||
requestAnimationFrame(redraw)
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
oldTime = time
|
|
||||||
|
|
||||||
var translate = zoomBehavior.translate()
|
var translate = zoomBehavior.translate()
|
||||||
var scale = zoomBehavior.scale()
|
var scale = zoomBehavior.scale()
|
||||||
var links = intLinks.filter(visibleLinks)
|
var links = intLinks.filter(visibleLinks)
|
||||||
|
Loading…
Reference in New Issue
Block a user