<div dir="ltr"><div dir="ltr">Hi Noel,<br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Mon, Apr 13, 2020 at 7:46 PM Noel Grandin <<a href="mailto:noelgrandin@gmail.com">noelgrandin@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div style="font-family:tahoma,sans-serif">Hi</div><div style="font-family:tahoma,sans-serif"><br></div><div style="font-family:tahoma,sans-serif">I notice when performance tuning that our drawinglayer stuff spends quite some time converting back and forth between XPrimitive2D and BasePrimitive stuff and copying sequence->vector and vector->sequence.</div><div style="font-family:tahoma,sans-serif"><br></div><div style="font-family:tahoma,sans-serif">Now as far as I can see (analysis below), the stuff exposed in our UNO layer is not usable from extensions because it doesn't tie into anything useful, so nothing should change as far as that goes.</div><div style="font-family:tahoma,sans-serif"><br></div><div style="font-family:tahoma,sans-serif">The benefit is that it becomes easier to optimise the copying and moving around of this stuff if it is C++ layers all the way down, with no UNO stuck in the middle of it.</div><div style="font-family:tahoma,sans-serif"><br></div><div style="font-family:tahoma,sans-serif">First stage of this change here:</div><div style="font-family:tahoma,sans-serif"><a href="https://gerrit.libreoffice.org/c/core/+/92107" target="_blank">https://gerrit.libreoffice.org/c/core/+/92107</a><br></div><div style="font-family:tahoma,sans-serif"><br></div></div></blockquote><div><br></div>Yeah, that looks great to me, but I don't like that dynamic / static loading of svgio library (like we already do in graphicfilter). Ideally svgio shouldn't need to depend on vcl - it just creates the primitives from the svg file, so vcl could just import svgio normally. For that also drawinglayer needs to be free from vcl dependency, so it is not a simple thing to do. I'm experimenting with this in feature/drawinglayercore branch [1], where I made a drawinglayercore library (like svx and svxcore, which is not ideal but necessary for simplicity), which will only have the core drawinglayer stuff and basic primitives and basegfx as the dependency.<br></div><div class="gmail_quote"><br></div><div class="gmail_quote">[1] <a href="https://cgit.freedesktop.org/libreoffice/core/commit/?h=feature/drawinglayercore&id=3abc1847fb81c358737e1d4443f3e6bf83c7691d">https://cgit.freedesktop.org/libreoffice/core/commit/?h=feature/drawinglayercore&id=3abc1847fb81c358737e1d4443f3e6bf83c7691d</a></div><div class="gmail_quote"><br></div><div class="gmail_quote">Anyway, an alternative to this would also be to create a XPrimtiive2DContainer UNO interface, which would allow to "transport" the Primitive2DContainer unmodified and wouldn't require that we convert, only on demand convert that to Sequence<XPrimitive2D>. Not sure if this solution is any better...<br></div><div class="gmail_quote"><br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div style="font-family:tahoma,sans-serif"></div><div style="font-family:tahoma,sans-serif">Regards, Noel</div><br></div></blockquote><div> </div><div>Regards, Tomaž<br></div></div></div>