You should consider reading the MIDP API Javadocs... they will tell you exactly what you can and can't do.
There is no AWT, so java.awt.Image must be replaced with javax.microedition.lcdui.Image. This class is not identical. MIDP API classes are generally far more limited in functionality than J2SE equivalents. Remember that the J2SE API is at around 100 times larger than MIDP.
There is no Color class.
You cannot retrieve the value of one pixel. You can retrieve an entire array of pixels, much like the way PixelGrabber works in AWT.
You cannot replace a single pixel, but you can create a new image from a pixel array.
I say "you can": you can on MIDP-2 devices, not on MIDP-1.
PHP Code:
// get image dimensions
int width = img.getWidth();
int height = img.getHeight();
// create array large enough to hold all the pixels
int[] pixels = new int[width * height];
// grab a copy of the pixels
img.getRGB(pixels, 0, width, 0, 0, width, height);
// compute the index for a pixel from (x,y)
int i = (y * width) + x;
// get the pixel value
int pixel = pixels[i];
// deconstruct the colour
int alpha = (pixel >> 24) & 0xff;
int red = (pixel >> 16) & 0xff;
int green = (pixel >> 8) & 0xff;
int blue = pixel & 0xff;
// construct a colour
int newPixel = ((alpha & 0xff) << 24) |
((red & 0xff) << 16) |
((green & 0xff) << 8) |
(blue & 0xff);
// replace old pixel value in the pixel array
pixels[i] = newPixel;
// create a new image from the modified pixel array
Image newImage = Image.createRGBImage(pixels, width, height, true);
This can be very memory hungry. The int[] needs four bytes for every pixel (for an image 1024x1024, that would be 4Mb). The Image objects may need a similar amount of memory each.
Cheers,
Graham.