java me - Help in J2ME for creating image and parse it -


Can anyone tell me how can I parse a png image in several PGG images in J2ME? ??

For the exam: I have to parse for 10 image only with 15 n 15 pixels for the source image of 150 * 150 pixels.

This is my code:

  The Public Class HelloMIDlet MIDlet tool provides commandListener {Private Boolean Midlet Paused = false; Private command exit; Private form form; Private string etam string item; Image IM, IM2; Form Form 1 = Faucet; Public HelloMIDlet () {try {// source image im = Image.createImage ("/ image1.JPG"); Int height = im.getHeight (); Int width = im.getWidth (); Int x = 0; Int y = 0; While (y & lt; height) {while (x  

Please help me make it right ... It is an emergency!

Thank you very much ...

Perhaps if I think it is right, So if you have a 150x150 single image that contains many other images, then index it for every image and use the graphics.Setclip () when you paint and paint the picture in proper coordination. For example, you want to paint the image 15, 15 of the picture on the coordinates 50, 50 on the device screen.

  ... g.setClip (15, 15); G.drawImage (Image, 35, 35, G. TOP; GLEFT); ...  

Hopes


Comments

Popular posts from this blog

python - Overriding the save method in Django ModelForm -

html - CSS autoheight, but fit content to height of div -

qt - How to prevent QAudioInput from automatically boosting the master volume to 100%? -