Skip to main content

Re: J2ME Help required (URGENT !!!)

1 reply [Last post]

Hi Mubin,

- to convert the jpeg into something you can use for filter (to get pixels value):

byte[] byteImage = vc.getSnapshot(null);
Image camImage = Image.createImage(byteImage, 0, byteImage.length);

>From the Image, you can then get an array filled with the RGB values :

canImage.getRGBImage (int[] rgbData, int offset, int scanlength, int x, int y, int width, int height)

then get the pixels one by one from the array :
int rgbpixel= rgbData[x+y*width];

you may want to processs the image by parts , to avoid memory explosion (it'll be 1 int per pixel, with a default image res to 1280x960)

you also might want to reduce the capture resolution, depending on the firmware version you get, you can add those parameters :

( if the handset gives those values trough getProperty("video.snapshot.encodings") ... depends on the firmware version.

- to remove the confirmation message : you can set the application settings to 'ask once' instead of 'ask every time'. Popup will appear only once.
You also can sign with verisign certificate, when signed you can set the value to 'never ask'.


-----Message d'origine-----

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
Joined: 2007-07-24

Thanks a lot Chris,
I'll check this out and will let u know how it turns up. As far as the image size is concerned, I have tried that already, it fails when it comes to W810i, it gives errors.

Well another thing i wanted to know, where can i find help regarding image manipulations commands, which API should i look into, simple J2SE Documentation? If you are aware of the Sobel Filter, it takes a block of pixels and work its way through out the image, so i hope that doesnt cause any memory problems or something ...

Well I'll let u know in a day, Thanks a lot for the help !!!

Mubin Khan