Open Bug 589285 Opened 16 years ago Updated 3 years ago

liquid chars is slower with d2d

Categories

(Core :: Graphics: Canvas2D, defect)

x86
Windows 7
defect

Tracking

()

REOPENED

People

(Reporter: jrmuizel, Unassigned)

References

(Blocks 2 open bugs)

Details

This demo http://spielzeugz.de/html5/liquid-chars.html is slower with d2d enabled and much slower than chrome.
Blocks: d2d-perf
Status: NEW → RESOLVED
Closed: 16 years ago
Resolution: --- → DUPLICATE
Blocks: 564643
Status: RESOLVED → REOPENED
Resolution: DUPLICATE → ---
Summary: liquid chars is slow → liquid chars is slower with d2d
What makes it slow on D2D does not even appear to be the OPERATOR_ADD usage (although that indeed does make it a little slower), but mainly the many glyphs rendered in separate drawing calls. For D2D goes through some steps to draw fonts (jrmuizel knows more about this than I do), which make setting up drawing a text run fairly expensive. With a lot of glyphs per run this results in performance which is just fine. When we have a load of runs each with a single glyph, this seems to becomes very slow. For some cases buffering a bunch of glyphs and drawing them in a single call could help. In this case however each glyph is drawn with a different transform, and I don't really see an obvious solution here :s.
it's also much slower than in the IE9 preview, which is what I was comparing it to... they're the ones that don't have ADD.
(In reply to comment #3) > it's also much slower than in the IE9 preview, which is what I was comparing it > to... they're the ones that don't have ADD. Oh, that's very interesting, so they're drawing this with OVER, then?
Yep, as best I can tell. They're just ignoring the compositing operator setting; it's hard to tell the difference on this particular demo.
fwiw, I believe chrome does text drawing on canvas using path filling instead of regular text rasterization. IE may do this as well.
(In reply to comment #6) > fwiw, I believe chrome does text drawing on canvas using path filling instead > of regular text rasterization. IE may do this as well. Interesting, do you believe we should experiment with that?
Depends on: 600255
Severity: normal → S3
Component: Graphics → Graphics: Canvas2D
You need to log in before you can comment on or make changes to this bug.