Hi Sorry, I was looking for a constructor taking a PdfPage object. I managed to get it working and it shaved off a few lines of code but sadly did not help on the growth of size.
I want to thank you for the help. It has been much appreciated :) /Jacob On Mon, Feb 18, 2019 at 4:14 PM zyx <z...@gmx.us> wrote: > On Mon, 2019-02-18 at 15:02 +0100, Jacob Pedersen wrote: > > I got it working now, however I'm not sure which constructor you > > refer to > > Hi, > I refer to the public API: > > https://sourceforge.net/p/podofo/code/HEAD/tree/podofo/trunk/src/doc/PdfXObject.h#l90 > > > or how this can make the code simpler. > > and see what it does in the background: > > https://sourceforge.net/p/podofo/code/HEAD/tree/podofo/trunk/src/doc/PdfXObject.cpp#l164 > Thus basically avoid the FillXObjectFromExistingPage() call in your > code and replace it with the predefined constructor, which does more > things that your code (I suppose it does those things for good, but I > do not know it for sure). > > > For reference this works pretty good with text-only test file (grows > > just 1 kb), however a file with images it grows from 109 to 117 kb, > > so still room for improvement perhaps? > > No idea, it may depend on the actual PDF content, but I doubt there is > anybody willing to dive into it, or at least I'm not for sure. I'm > sorry. > Bye, > zyx > > > > _______________________________________________ > Podofo-users mailing list > Podofo-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/podofo-users >
_______________________________________________ Podofo-users mailing list Podofo-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/podofo-users