[poppler] Question on how to ensure API compatibility

Albert Astals Cid aacid at kde.org
Sun Aug 5 06:43:31 PDT 2012


El Diumenge, 5 d'agost de 2012, a les 15:20:28, Albert Astals Cid va escriure:
> El Diumenge, 5 d'agost de 2012, a les 13:15:54, Adam Reichold va escriure:
> > -----BEGIN PGP SIGNED MESSAGE-----
> > Hash: SHA1
> > 
> > Hello everyone,
> > 
> > I am currently investigating how to enable the use of Thomas Freitag's
> > multi-threading patch via the Qt4 frontend. So far, I think that
> > calling displayPageSlice with fMT = true in renderToImage and using a
> > per-page SplashOutputDev for doing so should suffice.
> > 
> > I would like to go about this by adding a parameter to
> > DocumentData::getOuputDev which forces creation of a new output device
> > instead of using the per-document one.
> > 
> > Now what I am unsure about is whether adding a parameter with default
> > value like "bool renderPerPage = false" to the Page::renderToImage
> > method would break API (or ABI) compatibility? If so, would adding
> > another overload adding this parameter help or should I add another
> > method which is then called by Page::renderToImage?
> > 
> > Sorry, for these rather basic questions. I have no experience in
> > writing shared libraries.
> 
> We do not care about API/ABI compatibility at the poppler/ level, we only
> care about it at the qt4/ glib/ cpp/ levels.

Oh wait, you were asking about the qt4 frontend :D

Let me ask the same question i made to Thomas in the bug about thread safety, 
have you measured how much time/cpu/memory overhead the "extra safety" to work 
per thread adds? Because if it's "almost nothing" i don't see the need to pass 
the burden of the decision to the user of the library.

Cheers,
  Albert

> 
> Cheers,
>   Albert
> 
> > Best regards, Adam.
> > 
> > P.S.: Of course doing so would keep setting render hints unlocked.
> > Personally, I think documenting this would be enough.
> > -----BEGIN PGP SIGNATURE-----
> > Version: GnuPG v2.0.19 (GNU/Linux)
> > Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
> > 
> > iQEcBAEBAgAGBQJQHlXqAAoJEPSSjE3STU34C9IH/33KqPlQQO5gIXdRXszIG8t9
> > 79cTmQRvrYgQ8ifyfKHkwDgB8vJmaR7eiu75xjFh3LV0AV5hWNolXthIxtbhVnRj
> > 7aRvvr6zif+LCUjCgkISXDykA3kP/JnmDBqGm//QP6zDTEUzLQZGOs3zhATrH0oP
> > f1VZxghDAYpW0wcF+4/dsjM726ejsNHqAFgAvJOYXM8QgFgyxGyyZQ0UM3H+1B4b
> > GvrBaAGJb83LaklSv4evfsjMwVFqLARMFzGDGHOL0Spr1XVs3FdAuAIBibdvQ7IV
> > /PcJXnGJ68RDS4KlmUrrkthIhedq7s+IqjAraNSGjNmgLFlSST2LzIwRNGK/J3w=
> > =+sCn
> > -----END PGP SIGNATURE-----
> > _______________________________________________
> > poppler mailing list
> > poppler at lists.freedesktop.org
> > http://lists.freedesktop.org/mailman/listinfo/poppler
> 
> _______________________________________________
> poppler mailing list
> poppler at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/poppler


More information about the poppler mailing list