How to display JPEG or GIF images in a MIDlet.
1 posts in topic
Flat View  Flat View

Posted By:   Ravinder_Gitta
Posted On:   Thursday, January 31, 2002 09:39 PM

I was able to display PNG images in a MIDlet. I have seen an example which displays JPEG/GIF images(Not accessed from a webserver, included in the jar). But is there any way by which we can display images from a web server(by giving http://.../image.jpg).

createImage(byte[] imageData,int imageOffset,int imageLength) method takes the byte array. Is there any example to use this method.

Re: How to display JPEG or GIF images in a MIDlet.

Posted By:   Liam_Quinn  
Posted On:   Friday, February 1, 2002 12:46 PM

The easiest way is to have a transformation server that converts the JPEG or GIF into a PNG and sends that back to the MIDlet. You can write the transformation server in a number of ways: a Perl CGI script that uses gif2png and djpeg + pnmtopng, or a Java servlet that uses JAI or JIMI, etc.

ReqwirelessWeb uses this approach with a Java servlet.

About | Sitemap | Contact