Just to explain my problem a little more, I would like to change a circular region on this image to black & white while the rest of the image remains the same. I am able to get the complete image in black & white by
Bitmap myBitmap = BitmapFactory.decodeResource(getResources(), R.drawable.myImage); ColorMatrix colorMatrix = new ColorMatrix(); colorMatrix.setSaturation(0); paint = new Paint(); ColorMatrixColorFilter cmcf = new ColorMatrixColorFilter(colorMatrix); paint.setColorFilter(cmcf); Bitmap blackAndWhiteBitmap = Bitmap.createBitmap(myBitmap.getWidth(), myBitmap.getHeight(), Bitmap.Config.ARGB_8888); Canvas drawingCanvas = new Canvas(blackAndWhiteBitmap ); drawingCanvas.drawBitmap(myBitmap, 0, 0, paint); Can someone please suggest a solution. On Apr 21, 4:05 pm, Gaurav <[email protected]> wrote: > Can someone please respond to this. I would like to make some > modifications in the existing pixels represented by a path, this is a > little different from FingerPaint Sample where we draw a fresh path > overwriting the existing pixels. > > On Apr 21, 2:05 am, Gaurav <[email protected]> wrote: > > > How can we manipulate parts of an image selectively. For example, I > > have a canvas based on bitmap of image I am working on. I would like > > to change the brightness of a path on this canvas while the rest of > > the image remains the same. > > > -Gaurav --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~----------~----~----~----~------~----~------~--~---

