Peter Yen wrote:
>> Thanks for your quick response. The background is unknown at the time of
>> processing. Actually I don't need a very accurate methodology to remove all
>> background, removing partially is good enough.
I once wrote a (GPL'd) C module that fairly reliably extracts the
backgrou
On Thu, May 28, 2009 at 10:53 PM, Peter Yen wrote:
> Hi Fredrik,
>
> Thanks for your quick response. The background is unknown at the time of
> processing. Actually I don't need a very accurate methodology to remove all
> background, removing partially is good enough.
>
> imagick has method like f
One way to get rid of a single color background is to get the
background color (look at the upper left pixel) and then compare every
pixel to it. If they are the same, make it transparent, otherwise
leave it be. This obviously only works if nothing in the foreground is
colored the same as the backg
On Thu, May 28, 2009 at 10:22 PM, Peter Yen wrote:
> Is there any sample code to use PIL to remove the image background and make
> it transparent? Any help and advice is highly appreciated.
Depends on what the background is. The further it is from "a single
known color", the harder it gets.
_
Hi Fredrik,
Thanks for your quick response. The background is unknown at the time of
processing. Actually I don't need a very accurate methodology to remove all
background, removing partially is good enough.
imagick has method like floodfill, curious how to do that with PIL.
thanks a lot
-peter
Hi,
Is there any sample code to use PIL to remove the image background and make
it transparent? Any help and advice is highly appreciated.
-peter
___
Image-SIG maillist - Image-SIG@python.org
http://mail.python.org/mailman/listinfo/image-sig