You are viewing a plain text version of this content. The canonical link for it is here.
Posted to batik-dev@xmlgraphics.apache.org by Vincent Hardy <vi...@eng.sun.com> on 2000/11/07 06:38:42 UTC
[commit] More on text layout problem
Forcing the use of a non-Rectangle2D clip has a fairly large performance
cost (it makes the rendering engine use a slower rendering path) and
after running a benchmark on moscow.svg I tried to do better
than the previous fix I had put in. I ended up moving the work around
from AbstractGraphicsNode to ConcreteTextNode, the effect is the same,
but the performance is way better. On moscow.svg:
| Old build | Fix 1 | Fix 2
| (with bug) | |
+------------------------------------------
Initial paint | 7290ms | 9764ms | 7391ms
paint 2 | 2203ms | 3775ms | 2274ms
paint 3 | 2194ms | 3856ms | 2264ms
paint 4 | 2374ms | 3825ms | 2183ms
There are few text elements in this huge example, so this explains
why there is almost no difference between the new fix and previously.
However, this tells us that the 'cost' of the fix is between 30 and
50% and we will have that on text. The 2D team thinks this is fixed
in 1.4. I have not checked yet, but I will.
Also note that the performance degradation is also what we will get
when using non-rectangular clips, which will happen is some svg
documents,
but also when we rotate an image in the viewer.
V.