Commit cd7ba82
committed
DOC: Fix resizing of animation examples
On resize, either `init_func` will be called, or if not defined, the
main `func` with `i=0` is called. On animations that save a state, the
latter can cause weird glitching as the history will skip around.
* For `bayes_update`, I fixed it by providing an `init_func`.
* For `double_pendulum`, I fixed it by simplifying the trace line (since
we have the entire history pre-computed.)1 parent 6ba7d5f commit cd7ba82
File tree
2 files changed
+8
-10
lines changed- galleries/examples/animation
2 files changed
+8
-10
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
41 | 41 | | |
42 | 42 | | |
43 | 43 | | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
44 | 49 | | |
45 | 50 | | |
46 | 51 | | |
| |||
62 | 67 | | |
63 | 68 | | |
64 | 69 | | |
65 | | - | |
| 70 | + | |
66 | 71 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
14 | | - | |
15 | | - | |
16 | 14 | | |
17 | 15 | | |
18 | 16 | | |
| |||
92 | 90 | | |
93 | 91 | | |
94 | 92 | | |
95 | | - | |
96 | 93 | | |
97 | 94 | | |
98 | 95 | | |
99 | 96 | | |
100 | 97 | | |
101 | 98 | | |
102 | | - | |
103 | | - | |
104 | | - | |
105 | | - | |
106 | | - | |
107 | | - | |
| 99 | + | |
| 100 | + | |
108 | 101 | | |
109 | 102 | | |
110 | 103 | | |
| |||
0 commit comments