[poppler] Patch proposal: Implementation for real gouraud shaded triangles

Christian Feuersaenger ludewich at users.sourceforge.net
Sun Aug 22 08:21:00 PDT 2010


Dear Albert,

attached you find a test.pdf in which the improvements can be seen.

The rendering quality of my patch is much better; it eliminates the 
moire effects of the flat shading approximation (top left image).

Compare also the image with opacity on page 2 of test.pdf.

Besides the improved rendering quality, the most obvious change is the 
required runtime: on my system, the default xpdf requires 15 seconds 
until it stops rendering the first page whereas xpdf with poppler 
support and my new patch requires about one second. The pdftoppm utility 
is also considerably faster.

Let me stress that the patch is unrelated to my previous bugfixes, so 
rendering problems are only fixed together with the other bugfix.

Best regards

Christian

Am 19.08.2010 19:54, schrieb Christian Feuersaenger:
> Dear Albert,
>
> attached you find a test.pdf in which the improvements can be seen.
>
> The rendering quality of my patch is much better; it eliminates the
> moire effects of the flat shading approximation (top left image).
>
> Compare also the image with opacity on page 2 of test.pdf.
>
> Besides the improved rendering quality, the most obvious change is the
> required runtime: on my system, the default xpdf requires 15 seconds
> until it stops rendering the first page whereas xpdf with poppler
> support and my new patch requires about one second. The pdftoppm utility
> is also considerably faster.
>
> Let me stress that the patch is unrelated to my previous bugfixes, so
> rendering problems are only fixed together with the other bugfix.
>
> Best regards
>
> Christian
>
> Am 18.08.2010 23:15, schrieb Albert Astals Cid:
>> A Dijous, 15 de juliol de 2010, Christian Feuersaenger va escriure:
>>> Dear poppler developers,
>>>
>>> hereby I propose a new patch for a high quality, fast gouraud shader for
>>> triangle shadings.
>>>
>>> The patch provides
>>> - scalable triangle shadings (in contrast to the old approach),
>>> - correct shading, no approximation using flat triangles,
>>> - greatly (!) improved rendering speed,
>>> - support for opacity (in contrast to the previous approach).
>>>
>>> This patch is relative to the master branch,
>>> git show poppler-0.14.0-91-g31ac578 .
>>>
>>> It is unrelated to my previous patch proposals concerning shadings; the
>>> other patch proposal (my mail several weeks ago) is still important and
>>> relevant. The patch in this mail is independent and does not include my
>>> previous patch proposals.
>>>
>>> I tested the new patch with pdftoppm and with the xpdf-poppler fork of
>>> Rogerio Brito; it appears to work reliable. I tested
>>> - matrix shadings and triangle patch shadings (Types 4 and 5),
>>> - degenerated triangles,
>>> - clipping,
>>> - opacity,
>>> - RGB color spaces.
>>>
>>> The implementation now supports these shadings on a display driver level
>>> and is implemented directly in the splash device (using scanline
>>> sweeps).
>>>
>>> I've been defensive: I have no test cases for other color spaces and I
>>> have no test data for non-parametric shadings. Consequently, I disabled
>>> the shader for these cases; it will fall back to the existing solutions
>>> (approximate shading by means of many flat triangles).
>>>
>>> I hope you find my patch proposal useful. I believe it is worthy of
>>> being part of libpoppler.
>>
>> Do you have a pdf where we can see the improvement this patch gives?
>>
>> Albert
>>
>>>
>>> Thanks,
>>>
>>> Christian
>> _______________________________________________
>> 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

-------------- next part --------------
A non-text attachment was scrubbed...
Name: test.pdf
Type: application/pdf
Size: 98318 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/poppler/attachments/20100822/4beaa2f2/attachment-0001.pdf>


More information about the poppler mailing list