Commit Graph

246 Commits

Author SHA1 Message Date
Mike Bostock
a6dcf0c876 Improve stability of collision detection. 2016-04-23 14:24:37 -07:00
Mike Bostock
53fb14fcbd Add d3.forceContain. 2016-04-23 10:24:15 -07:00
Mike Bostock
ffa61d6e49 0.0.4 2016-04-23 09:48:58 -07:00
Mike Bostock
6ad4bc2663 More stable collision detection. 2016-04-23 09:48:31 -07:00
Mike Bostock
d1aff9acf0 Don’t require nodes on creation. 2016-04-23 09:38:08 -07:00
Mike Bostock
b4896d57ef Fix the many-body force.
Mutating the tree deletes the accumulated charges!
2016-04-23 09:37:09 -07:00
Mike Bostock
0f68d7259e Reset link force when links change. 2016-04-23 08:43:59 -07:00
Mike Bostock
15728e3cf9 0.0.3 2016-04-22 16:08:25 -07:00
Mike Bostock
95cd502143 Fix typo. 2016-04-22 16:08:22 -07:00
Mike Bostock
7830f5415d 0.0.2 2016-04-22 15:56:00 -07:00
Mike Bostock
0744d26f06 Fix #12 - make position configurable. 2016-04-22 15:35:56 -07:00
Mike Bostock
74bfd620a3 Better collision detection.
By looking into the future, we can better avoid collisions.

Also remove duplicate initialization of node positions.
2016-04-22 13:04:57 -07:00
Mike Bostock
9944ad19ed Fix for zero alphaDecay. 2016-04-22 10:04:24 -07:00
Mike Bostock
8c2113f53c Fix manyBody force. 2016-04-22 09:55:12 -07:00
Mike Bostock
d6f45ffc53 Update to d3-quadtree 0.7. 2016-04-22 09:45:03 -07:00
Mike Bostock
dfe79d5c7d Add collision force. 2016-04-21 17:49:52 -07:00
Mike Bostock
b5ad5d589d Air it out a bit. 2016-04-21 15:52:14 -07:00
Mike Bostock
19324ef21e Don’t rely on this. 2016-04-21 13:44:52 -07:00
Mike Bostock
f628880885 Allow forces to share the quadtree. 2016-04-21 13:27:10 -07:00
Mike Bostock
377713e73d Increase default theta. 2016-04-20 17:52:10 -07:00
Mike Bostock
5b46023e88 Rename charge to strength. 2016-04-20 15:31:37 -07:00
Mike Bostock
c30fc9513e Modify position, not velocity.
We don’t want re-centering to apply momentum.
2016-04-20 15:26:53 -07:00
Mike Bostock
321784c573 Fix #13 - initialize positions and velocities. 2016-04-20 15:24:49 -07:00
Mike Bostock
32724da3e5 Add d3.forceCenter. 2016-04-20 15:12:04 -07:00
Mike Bostock
900d9e1b24 Fix #1 - allow linking by string identifier. 2016-04-20 13:37:41 -07:00
Mike Bostock
44aabfab2a Allow simulation.force(name, null). 2016-04-20 12:53:35 -07:00
Mike Bostock
166bda8cdd Initialize link.index, too. 2016-04-20 12:38:01 -07:00
Mike Bostock
541ef54098 Allow numeric source and target identifiers. 2016-04-20 12:33:10 -07:00
Mike Bostock
46eb5553a0 Per-link strength and distance. 2016-04-20 10:39:32 -07:00
Mike Bostock
71510f3725 Make force.nodes optional. 2016-04-20 09:53:56 -07:00
Mike Bostock
fd9b00383a Handle coincident nodes. 2016-04-20 09:52:14 -07:00
Mike Bostock
9392d4e1b7 Update d3-quadtree. 2016-04-19 17:18:35 -07:00
Mike Bostock
3d449cd12d Remove unused var. 2016-04-16 08:00:59 -07:00
Mike Bostock
5a3d213812 Handle coincident nodes. 2016-04-11 11:03:07 -07:00
Mike Bostock
7ae3bbc451 Fix #10 - non-recursive many-body force. 2016-04-11 10:36:35 -07:00
Mike Bostock
1fe10b4c18 Variable charge forces. 2016-04-08 15:07:00 -07:00
Mike Bostock
f08062fb16 Assign node.index in d3.forceSimulation.
Also get ready for d3-quadtree 0.3 and per-node forces.
2016-04-08 08:33:00 -07:00
Mike Bostock
13fd5ee8ce Remove dead code. 2016-04-07 13:13:16 -07:00
Mike Bostock
a72896d49f Preserve alpha when setting alphaDecay. 2016-04-07 11:55:45 -07:00
Mike Bostock
0c881ead02 Cleaner. 2016-04-07 11:42:17 -07:00
Mike Bostock
bbaa4d61e5 Improvements.
Fix #7 - forces are now mutable, so it’s easier to change their settings and
they behave more like other configurable objects in D3 (though less like curves,
easing functions and interpolators).

Fix #9 - forces now have a dedicated interface rather than just being beforetick
listeners. This allows forces to be re-initialized when the nodes change.

Fix #10 - d3.forcePosition now initializes node positions and velocities.
2016-04-07 11:32:34 -07:00
Mike Bostock
c7380c13b0 Compute link bias. 2016-04-06 13:51:59 -07:00
Mike Bostock
2bebbfb2e7 Checkpoint many-body forces. 2016-04-06 13:21:23 -07:00
Mike Bostock
17111cc1bf 0.0.1 2016-04-05 13:53:44 -07:00
Mike Bostock
45776e98c8 Prepare for patch version. 2016-04-05 13:53:42 -07:00
Mike Bostock
bc24b67ad6 Initial commit. 2016-04-05 13:50:36 -07:00