Blur on transparent images with RMagick

A

August Lilleaas

Hello,

Let's start with some code. http://pastie.org/340438 . If you run it
(after changing the font on line 33), you get a neat image with the
text appearing two times. One flat, the other with a blur.

Now, set the background_color to 'transparent' on line 30, and voila
-- no blur.

I'm running RMagick 2.8.0 and ImageMagick 6.4.4 2008-11-21 Q16. Anyone
knows what this is all about?
 
T

Tim Hunter

August said:
Hello,

Let's start with some code. http://pastie.org/340438 . If you run it
(after changing the font on line 33), you get a neat image with the
text appearing two times. One flat, the other with a blur.

Now, set the background_color to 'transparent' on line 30, and voila
-- no blur.

I'm running RMagick 2.8.0 and ImageMagick 6.4.4 2008-11-21 Q16. Anyone
knows what this is all about?

blur_image only blurs the RGB channels. Use this instead:

@image = @image.blur_channel(0,3, Magick::AllChannels)

If you have any other questions about RMagick you can reach me at the
RMagick Help Forum on RubyForge
(http://rubyforge.org/forum/forum.php?forum_id=33) or directly at
rmagick AT rubyforge DOT org.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,181
Messages
2,570,970
Members
47,537
Latest member
BellCorone

Latest Threads

Top