On Tue, 2009-06-23 at 09:24 -0500, Bart McDonald wrote:
> Hey everyone,
> 
>  
> 
> I have been challenged to be able to create a PDF document that has
> 200,000 or more pages in it.  I have used both the memdocument and
> streameddocument but both seem to slow down more and more until they
> finally crash (around 4500 pages), and no pdf output.

Can you supply a backtrace of the crash? Build PoDoFo for debugging
(-DCMAKE_BUILD_TYPE=debug) and then run it under a debugger.

You haven't mentioned basics like the compiler/platform/development
environment you're using, so I can't give you better instructions.

> Is there a way to flush the contents of the memdocument to file and
> continue creating the output so the memory load is lessened?  Any
> hints or ideas would be greatly appreciated.

You'll definitely need to use PdfStreamedDocument. PdfMemDocument is
designed to hold the whole structure in memory, and while it has some
optimisations for delayed loading and for using streams directly from
the PDF file it's not well suited to _creating_ large PDFs.

It would be rather nice if PdfMemDocument could be given an output file
and told to flush its dirty state to it, but at present it doesn't know
how to do that.

To find out what's going wrong when you use PdfStreamedDocument, I'd
need a backtrace of the crash you're encountering, or at least a
self-contained piece of test code I can build and debug. Preferably
both.


-- 
Craig Ringer




------------------------------------------------------------------------------
_______________________________________________
Podofo-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/podofo-users

Reply via email to