Thread View: borland.public.jbuilder.java.api
1 messages
1 total messages
Started by Vincent
Mon, 26 May 2003 08:30
Color to Black&white
Author: Vincent
Date: Mon, 26 May 2003 08:30
Date: Mon, 26 May 2003 08:30
23 lines
1774 bytes
1774 bytes
Hi, I'd like to transform a colored picture (from a gif or jpeg file for exemple) in a Black and White image (wbmp format). I use a ColorConvertOp to do that, but I don't know how to param it to have a nice conversion, not a pixel level conversion. Here is the code I used: BufferedImage bi4 = new BufferedImage(bi3.getWidth(), bi3.getHeight(), BufferedImage.TYPE_BYTE_BINARY); ColorConvertOp cco2 = new ColorConvertOp(ColorSpace.getInstance(ColorSpace.CS_GRAY), null); cco2.filter(bi3, bi4); Where bi3 is my original BufferedImage. Do you know where I can find more information on this conversion, because in the help I don't understand everything (I have no knowledge on picture conversion). Thanks for all Vincent
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads