Poppler internal API problem
We are still using the internal Poppler API to import PDFs. This is very bad, since the internal Poppler API is not stable, and will keep breaking. (We already don't build with poppler > 0.12.1)
How about using the public Glib API to render to a Cairo SVG surface instead? This is how pdf2svg works, and to be honest I had to use that utility several times to augment Inkscape, because it handles text much better. What are the advantages to using internal Poppler API directly?
Regards, Krzysztof
On Mar 5, 2010, at 12:46 PM, Krzysztof Kosiński wrote:
We are still using the internal Poppler API to import PDFs. This is very bad, since the internal Poppler API is not stable, and will keep breaking. (We already don't build with poppler > 0.12.1)
How about using the public Glib API to render to a Cairo SVG surface instead? This is how pdf2svg works, and to be honest I had to use that utility several times to augment Inkscape, because it handles text much better. What are the advantages to using internal Poppler API directly?
You should try skimming our archives to see what has been discussed in the past.
Personally I dislike using internal hooks, but I do know the Cairo SVG surface gave us very poor quality results for what we want. Not that it looked bad, per se, but more that the structure of the resulting data was poor for editing and for source.
Among other things we've discussed this with other projects and with the Poppler people themselves. They agreed that the standard public APIs did not match what we as an editor would need. So they've started on crafting a new standard API that we and other projects including some Qt can also leverage.
Probably the best thing to help with at this point would be to come up with some test case files and usage scenarios so we can make sure the new API will give us all the hooks we need. Off the top of my head I can think of documents with mixed CMYK and RGB, color profiles, embedded fonts, metadata, etc. as all needing to be handled well.
Now as 0.48 is out, how about the poppler problem? How do we proceed?
regards, Adib. -- 2010/3/6 Jon Cruz <jon@...18...>:
On Mar 5, 2010, at 12:46 PM, Krzysztof Kosiński wrote:
We are still using the internal Poppler API to import PDFs. This is very bad, since the internal Poppler API is not stable, and will keep breaking. (We already don't build with poppler > 0.12.1)
How about using the public Glib API to render to a Cairo SVG surface instead? This is how pdf2svg works, and to be honest I had to use that utility several times to augment Inkscape, because it handles text much better. What are the advantages to using internal Poppler API directly?
You should try skimming our archives to see what has been discussed in the past.
Personally I dislike using internal hooks, but I do know the Cairo SVG surface gave us very poor quality results for what we want. Not that it looked bad, per se, but more that the structure of the resulting data was poor for editing and for source.
Among other things we've discussed this with other projects and with the Poppler people themselves. They agreed that the standard public APIs did not match what we as an editor would need. So they've started on crafting a new standard API that we and other projects including some Qt can also leverage.
Probably the best thing to help with at this point would be to come up with some test case files and usage scenarios so we can make sure the new API will give us all the hooks we need. Off the top of my head I can think of documents with mixed CMYK and RGB, color profiles, embedded fonts, metadata, etc. as all needing to be handled well.
Download Intel® Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev _______________________________________________ Inkscape-devel mailing list Inkscape-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/inkscape-devel
W dniu 14 września 2010 12:43 użytkownik the Adib <theadib@...1439...> napisał:
Now as 0.48 is out, how about the poppler problem? How do we proceed?
regards, Adib.
Right now, I see 3 options
1: Use poppler-glib to render to a Cairo SVG surface. 2: Convince Poppler developers to stabilize the internal API. 3: Fork Poppler. 4. Use a different PDF library.
1 is good but might reduce the quality of imported documents. 2 is best but very unlikely. 3 is antisocial and evil but would preserve the current PDF import capability without regressions. I don't know much about other PDF libraries so can't comment on 4.
Regards, Krzysztof
On Sep 14, 2010, at 3:41 PM, Krzysztof Kosiński wrote:
W dniu 14 września 2010 12:43 użytkownik the Adib <theadib@...1439...> napisał:
Now as 0.48 is out, how about the poppler problem? How do we proceed?
regards, Adib.
Right now, I see 3 options
1: Use poppler-glib to render to a Cairo SVG surface. 2: Convince Poppler developers to stabilize the internal API. 3: Fork Poppler. 4. Use a different PDF library.
1 is good but might reduce the quality of imported documents. 2 is best but very unlikely. 3 is antisocial and evil but would preserve the current PDF import capability without regressions. I don't know much about other PDF libraries so can't comment on 4.
You missed the other option, get a new public API from the poppler developers.
That is actually what they agreed upon, and need feedback on crafting.
just for the record: http://lists.freedesktop.org/archives/poppler/2010-February/005560.html
so far I do not see any work on generic interface on the poppler side on the cairo side I heard some rumor that someone is working on cmyk implementation but there is nothing about on the roadmap nor todo list on the website.
the german computer magazin c't testet some vector graphics programs in a recent issue: only inkscape does not handle cmyk correctly.
Adib.
2010/9/15 Jon Cruz <jon@...18...>:
On Sep 14, 2010, at 3:41 PM, Krzysztof Kosiński wrote:
W dniu 14 września 2010 12:43 użytkownik the Adib <theadib@...1439...> napisał:
Now as 0.48 is out, how about the poppler problem? How do we proceed?
regards, Adib.
Right now, I see 3 options
1: Use poppler-glib to render to a Cairo SVG surface. 2: Convince Poppler developers to stabilize the internal API. 3: Fork Poppler. 4. Use a different PDF library.
1 is good but might reduce the quality of imported documents. 2 is best but very unlikely. 3 is antisocial and evil but would preserve the current PDF import capability without regressions. I don't know much about other PDF libraries so can't comment on 4.
You missed the other option, get a new public API from the poppler developers.
That is actually what they agreed upon, and need feedback on crafting.
participants (3)
-
Jon Cruz
-
Krzysztof Kosiński
-
the Adib