Re: Downsampling bitmaps from RSVG quality

Emmanuel Pacaud <[email protected]>
Newsgroups gmane.comp.lib.cairo
Message-ID <[email protected]>
Hi,

Le jeu. 23 juil. 2015 à 6:43, Samuel Williams 
<[email protected]> a écrit :
> I'm resizing and generating PNGs from SVG inputs.
> 
> I want the best possible quality but the downsampling of large input 
> images to small output images seems to be quite crude.
> 
> I've tried looking at how to use set_filter but it's not obvious how 
> to use this in conjunction with RSVG's render_rsvg_handle. I tried 
> rendering to a recording surface and then using a surface pattern 
> with a filter set but that didn't help. Here is an example of the 
> Ruby code:

In your code, you are not doing subsampling, you just render a SVG file 
to a bitmap surface with a given size, which mean set_filter will 
almost do nothing (except for the possible bitmap subsurfaces rsvg is 
creating while rendering, in the case of blur filter for example).

So what you get currently is the best possible cairo rendering of an 
SVG file. Without givin any specific example of what you find crude in 
the PNG output, it will be difficult to understand what goes wrong.

	Cheers,

		Emmanuel.




-- 
cairo mailing list
[email protected]
http://lists.cairographics.org/mailman/listinfo/cairo
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.