4 ms·
I once put a good deal of effort prototyping a full-featured <canvas>-based video player. One feature was subtitles, which was text-on-canvas. I found that an
by taylorbuley 12y ago
I once put a good deal of effort prototyping a full-featured <canvas>-based video player. One feature was subtitles, which was text-on-canvas.
I found that an absolutely positioned div beat the pants off the performance of rendering text to canvas in almost all scenarios. In fact, I would almost never espouse layering of canvas rendering, and rather propose the layering of <canvas> elements themselves and letting markup engines take care of the composition.