Commit 7f5913c
authored
Perf: Pause RAF loop when there are no updates (#99)
- [x] Implement RAF Loop Pause optimization
- [x] Fix SDF text font loading race condition
- This results in text that is not rendered if an SDF font atlas texture
is not uploaded in time to the GPU before the RAF loop is paused.
- [x] Fix text doubling
- Some text appears to be double rendered which is causing text to
appear thicker and tests to fail.
- Turns out the `gl.clear()` command was still be affected by the last
scissor operation causing the entire canvas to not get cleared each
time.File tree
9 files changed
+42
-153
lines changed- examples
- src/core
- renderers/webgl
- scene
- text-rendering/font-face-types/SdfTrFontFace
- visual-regression/certified-snapshots/chromium-ci
9 files changed
+42
-153
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
262 | 262 | | |
263 | 263 | | |
264 | 264 | | |
| 265 | + | |
| 266 | + | |
| 267 | + | |
265 | 268 | | |
266 | | - | |
| 269 | + | |
267 | 270 | | |
268 | 271 | | |
269 | 272 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
217 | 217 | | |
218 | 218 | | |
219 | 219 | | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
220 | 223 | | |
221 | 224 | | |
222 | 225 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
102 | 102 | | |
103 | 103 | | |
104 | 104 | | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
105 | 108 | | |
106 | 109 | | |
107 | 110 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
19 | | - | |
20 | | - | |
21 | | - | |
22 | 19 | | |
23 | | - | |
24 | 20 | | |
25 | 21 | | |
26 | 22 | | |
| |||
62 | 58 | | |
63 | 59 | | |
64 | 60 | | |
65 | | - | |
| 61 | + | |
66 | 62 | | |
67 | 63 | | |
68 | 64 | | |
69 | 65 | | |
70 | 66 | | |
71 | 67 | | |
72 | 68 | | |
| 69 | + | |
73 | 70 | | |
74 | 71 | | |
75 | 72 | | |
| |||
146 | 143 | | |
147 | 144 | | |
148 | 145 | | |
149 | | - | |
| 146 | + | |
150 | 147 | | |
151 | 148 | | |
152 | 149 | | |
| |||
158 | 155 | | |
159 | 156 | | |
160 | 157 | | |
161 | | - | |
162 | | - | |
| 158 | + | |
| 159 | + | |
163 | 160 | | |
164 | 161 | | |
165 | 162 | | |
| |||
177 | 174 | | |
178 | 175 | | |
179 | 176 | | |
180 | | - | |
181 | | - | |
182 | | - | |
183 | | - | |
184 | | - | |
185 | | - | |
186 | | - | |
| 177 | + | |
187 | 178 | | |
188 | 179 | | |
189 | 180 | | |
190 | 181 | | |
191 | 182 | | |
192 | 183 | | |
193 | | - | |
| 184 | + | |
194 | 185 | | |
195 | 186 | | |
196 | | - | |
197 | | - | |
| 187 | + | |
| 188 | + | |
198 | 189 | | |
199 | 190 | | |
200 | 191 | | |
201 | 192 | | |
202 | 193 | | |
203 | | - | |
| 194 | + | |
204 | 195 | | |
205 | 196 | | |
206 | 197 | | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
207 | 203 | | |
208 | 204 | | |
209 | 205 | | |
| |||
240 | 236 | | |
241 | 237 | | |
242 | 238 | | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
243 | 246 | | |
244 | 247 | | |
245 | 248 | | |
| |||
304 | 307 | | |
305 | 308 | | |
306 | 309 | | |
307 | | - | |
308 | | - | |
309 | | - | |
310 | | - | |
311 | | - | |
312 | | - | |
313 | | - | |
314 | | - | |
315 | 310 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
29 | 34 | | |
30 | 35 | | |
31 | 36 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
179 | 179 | | |
180 | 180 | | |
181 | 181 | | |
| 182 | + | |
182 | 183 | | |
183 | 184 | | |
184 | 185 | | |
| |||
This file was deleted.
Lines changed: 4 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
82 | 82 | | |
83 | 83 | | |
84 | 84 | | |
85 | | - | |
86 | | - | |
87 | | - | |
88 | | - | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
89 | 88 | | |
90 | 89 | | |
91 | 90 | | |
| |||
120 | 119 | | |
121 | 120 | | |
122 | 121 | | |
123 | | - | |
| 122 | + | |
124 | 123 | | |
125 | 124 | | |
126 | 125 | | |
| |||
0 commit comments