Regarding images in J2ME

I am trying to build an application that sends an image by transforming it into a byte array. My problem is that, when I receive the byte array, I want to save it as a file on the mobile phone. Can someone suggest me a way of solving this, please?

jsr-75 is optional, but you can very easily store your byte[] image in the RMS (record store). See:
http://java.sun.com/javame/reference/apis/jsr118/javax/microedition/rms/RecordStore.html

Similar Messages

  • General Question Regarding Image Processing

    Hi All,
    I need a suggestion regarding image processing and this is the best place to get best advise.
    we need an image processing utility for our web processing.
    requirements are as described below:
    we have a e commerce based application where we need to display product images which we are currently displaying successfully.
    now we have to provide user with image processing functionality like user can zoom image can flip image can rotate image.
    what we want like when user click on zoom we can generate a dynamic image of that region based on a single source of image and can provide zooming functionality.
    more over company requirements is to go for only open source solution [:-)]
    we tried some open source solutions but due to the in house E-Commerce framework constraints we not able to integrate them,.
    can any one point me to any open source java based library so that we can use that to provide solution or do we need some other approach.
    Here is a link for a image zooming example hough this is highly professional solution using Adobe Scene7 but we want to implement something like in image zooming
    [Zoom Demo|http://s7d2.scene7.com/s7ondemand/zoom/flasht_zoom.jsp?company=S7Web&sku=AnthroISwebDemo&config=S7Web/AnthroISwebDemo&zoomwidth=500&zoomheight=500&viewer=/skins/S7Web/SWFs/loaders/genericzoomLfour.swf&vc=codeRoot%3D%2Fis-viewers351%2Fflash%2F]
    any help in this regard will be much appreciated.
    Thanks in advance
    -Umesh

    It is never safe to assume that any allocation was successful, and while it's incredibly unlikely that you're running into any such situation, it's entirely possible for a formal protocol to declare that a given message send should return immediately without waiting around:
    http://developer.apple.com/documentation/Cocoa/Conceptual/ObjectiveC/Articles/ch apter13_section_8.html#//appleref/doc/uid/TP30001163-CH9-BAJIGHAF
    An "impression" doesn't prove much unfortunately, so I'd recommend getting friendly with the debugger to see what's really going on.

  • How to Compare Two Camera's capture  Image in j2me

    i want to know ,how to compare two Camera's capture image in j2me,
    in my midlet application i used MMapi to access Camera.& capture two image through Camera. Then i want to store new image instead of previous one in mobile phone memory.
    Please tell me how that comparing will done.
    thanks in advance.

    Hi,
    I didn�t know about the image comparison, but here is one more idea to store the new picture, whenever you captured the picture take the time and when you take another picture compare the times of both pictures then save the picture with latest time.
    But there is one flaw in this approach, if user explicitly changed the time and captured the pictures it won�t work properly.
    - satdmail -

  • Images in J2ME

    I have created four images:
    errorImage = Image.createImage("/res/error.png");
    welcomeImage = Image.createImage("/res/welcome.png");
    mainImage = Image.createImage("/res/main.png");
    conImage = Image.createImage("/res/warning.png");
    The .java file is in /src, the images are in /res
    But I can't see images using J2ME Wireless Toolkit

    Stupid!
    just put the images into /res then change like this:
    errorImage = Image.createImage("/error.png");
    welcomeImage = Image.createImage("/welcome.png");
    mainImage = Image.createImage("/main.png");
    conImage = Image.createImage("/warning.png");
    ^_^

  • C3- Problem regarding Images

    Hello,
    I m having C3 but seems one problem i.e. All the images or photos in memory card automatically shown in "Photos- My Photos".
    Anything deleting from that deletes frm memory card too.
    I want to show selected photos in "My Photos".
    Any suggestions regarding it.

    See http://kb.mozillazine.org/Animated_images

  • Open camera and capture image using J2me.

    please I want J2me code to open the mobile camera and capture image....
    please reply me as quick as possible....(very urgent)...

    eng_amy wrote:
    please I want J2me code to open the mobile camera and capture image....Well..
    eng_amy wrote:
    please reply me as quick as possible....(very urgent).....(checks watch) ..it's obviously too late. Never mind.

  • Add Image in j2me

    hi everyone
    i have developed a chat application through which we can chat online from mobile with wireless toolkit using netbeans5.5.
    Application is running fine on all phones but i am getting a strange problem with images on some phones.
    i have added images in it and nokia phones are displaying them well
    but samsung d500 and iPod and sm oter ones are unable to find the images which are theare in images folder of application
    code to create image used is
    Image welcome=Image.createImage("/images/my.jpg");
    ImageItem item=new ImageItem("",welcome,ImageItem.LAYOUT_CENTER|ImageItem.LAYOUT_NEWLINE_BEFORE,"Your Mobile deos not suppot images");
    cMainForm.append(item);
    please help me out that why mobiles oter than nokia are not able to find them.
    thanks

    Buddy png format image is suppose to be displayed change the format
    and try it again
    With regards
    Rizwan

  • Problems calling image on J2ME mobile phone screen

    I have an image size (160kb) of certain size and width. I am calling this image onto a mobile phone screen (j2me) and upon calling this image, I am getting OutOfMemoryException. Sometimes, I do get the partial image displayed on the phone screen.
    My requirement is either reduce the size of the image or avoid the OutOfMemoryException. Does anyone has gone through the similar situation. Any ideas on how to solve this problem is greatly appreciated.
    Thanks,
    coolers.

    Thanks for the response. I posted it there.
    Here is the link
    http://forum.java.sun.com/thread.jspa?threadID=682766
    Thanks,
    Coolers

  • No Image in my cell but there's an image in J2ME wireless toolkit

    Hi all,
    I'm really lost here. I coded my java code and run it in J2ME wireless toolkit and the image is there, I put the image on the res folder and the image file format is .PNG, its working in the default color phone. However whe send it to my cellphone, sending the .jar file, and after installation, as I run the program, I cant see the image, all UI is ok but not the image. Thanks a lot
    Here's the code:
    import javax.microedition.midlet.*;
    import javax.microedition.lcdui.*;
    public class HelloWorld extends MIDlet implements CommandListener, ItemStateListener
    private Form frm;
    private Display display;
    private TextField txtName;
    private TextField txtAge;
    String[] genderArray = {"Male", "Female"};
    private ChoiceGroup gender;
    String[] statusArray = {"Single", "Married", "Widow"};
    private ChoiceGroup status;
    private Command cmdExit;
    public HelloWorld( )
         display = Display.getDisplay(this);
         frm = new Form("Hello World");
         txtName = new TextField("Name: ","",40,TextField.ANY);
         txtAge = new TextField("Age: ","",2,TextField.NUMERIC);
         Image[] imageArray2 = null;
         Image[] imageArray3 = null;
         try {
              Image icon = Image.createImage("/icon.png");
              Image img = Image.createImage("/myPic.png");
              imageArray2 = new Image[] {icon, icon};          
              imageArray3 = new Image[] {icon, icon, icon};
         frm.append(new ImageItem(null, img, ImageItem.LAYOUT_CENTER,null));     
         } catch(java.io.IOException err)
              // Found an error
         gender = new ChoiceGroup("Gender: ",ChoiceGroup.EXCLUSIVE,genderArray,imageArray2);
         status = new ChoiceGroup("Status: ",ChoiceGroup.POPUP,statusArray,imageArray3);
         cmdExit = new Command("Exit",Command.EXIT,1);
         frm.addCommand(cmdExit);
         frm.append(txtName);
         frm.append(txtAge);
         frm.append(gender);
         frm.append(status);
    public void startApp( )
         display.setCurrent(frm);
    public void pauseApp( )
    public void destroyApp(boolean unconditional)
    public void commandAction(Command c, Displayable s)
    if ( c == cmdExit )
         destroyApp(false);
         notifyDestroyed( );
    public void itemStateChanged(Item item)
    Thanks.

    HI Phoenix_Mj
    I'm a beginner in J2ME world and it might happen that I'm be missing some impt step from coding to transferring.
    Do I have to configure anything?
    Im I right by saying, only the .jar file is then transmitted to the device?
    Lastly, where should I put my images? what folder to be specific?
    I can't run the application correctly even trying to run it over the OTA....
    No images is being displayed...
    Please help guys.
    By the way thanks, Phoenix_Mj
    God Bless to all

  • Regarding Images

    Hi
    I need to show images in the column of a table on each row. I stored the image in mimes/components/package folder. But in the code , can anyone tell me the url to access the image?
    Regards
    Sreekar

    Hi sreekar,
    1) U have to store ur image inside the src/mimes/components/packages.
    2) After storing the image now if u want to use it inside ur table row, append the UIelement inside the table row while creating the table.
    3) Then in the properties of the image.GO to source property and then specify the name of the image with the extension.(Ex test.bmp)
    4) Then if u deploy ur appln u will be able to c the image displayed in the table.
    Hope it helps,
    Regards,
    Nagarajan.

  • Regarding Images save in SAP database

    HI Sapers,
    our client is having the business scenario like, Material will be supplied by vendor is in bulk quantity, ex. they will sent the material through transport vehicles, at the time of receiving the material from vendor the security people will needs to create a gate pass which consists of vehicle number plate image and diver image,
    The material sent by vendor is against a P.O. only, we can get the all the information from SAP data base, my basic requirement is how we can save the JPEG files in to sap data base. pl provide the necessary steps of it.
    Thanks in advance,
    Venkat.

    HI,
    Check the links
    http://www.sap-img.com/oracle-database/how-to-save-an-image-in-a-sql-server-database.htm
    http://help.sap.com/saphelp_banking463/helpdata/en/7d/f63a25015111d396480000e82de14a/content.htm
    http://help.sap.com/SAPHELP_NW70EHP1/helpdata/EN/43/a996152ce41bbde10000000a1553f7/content.htm
    Regards
    KK
    Edited by: Kishore Kumar Galla on Mar 18, 2010 11:52 AM

  • Regarding SMS in J2me

    Hello there,
    just wondering if its possible to intercept sms messages in j2me MIDP ? with intercept i mean you can get control of first receving the message and then being able to forward it to the phone or delete it....
    thanks
    Mudassar

    No you can't. The only SMS you can have acces are those for the PUSH. (with a port number that equals the declaration in the .jad file). The PUSH allows you to see its payload and make some treatment on it.
    But a simple MIDlet can not intercept normal SMS.
    Regards.

  • Need help regarding image scanning from scanner and resizing it...

    Hi,
    I need help regarding scanning of image directly from scanner. Here is the scenario when the person clicks scan button on the webpage should scan the image and resize it and store it in some temp location. Is there any way i can do this. Any Help regarding this would be great!!!
    Thanks,
    Avinash.
    Edited by: Kalakonda on Jul 24, 2009 8:08 AM

    Kalakonda wrote:
    I need help regarding scanning of image directly from scanner. Here is the scenario when the person clicks scan button on the webpage should scan the image and resize it and store it in some temp location. Is there any way i can do this. Any Help regarding this would be great!!!So what you are doing is you have a Scanner (hardware: like an HP flatbed scanner) attached to a server that you want to use as a scanning station? Is this the senario that you are talking about?

  • Creating image with j2me

    Dear sir,
    how can i retrive image from servlet so that my Httpconnection url would be like this
    http://localhost:8080/banner/logo.PNGi'm trying to display image using midlet to go through servlet to fetch image from database.can anyone plz help me or suggest any alternative way to solve this problem

    I have succeeded in creating a mutable image that contains text and image (.png), through
                         Image img;
                         img = Image.createImage(50, 60);
         protected void paint(Graphics g){
              g.drawImage(img, getWidth()/2, getHeight()/2, Graphics.HCENTER | Graphics.VCENTER);
              Graphics graph = img.getGraphics();
              graph.setColor(0, 0, 0);
              graph.setFont(Font.getFont(Font.FACE_PROPORTIONAL, Font.STYLE_BOLD,
                             Font.SIZE_LARGE));
              graph.drawString("Printing test from "
                                       + System.getProperty("microedition.platform") + " on ", 10, 10, 0);
              graph.drawImage(image, img.getWidth()/2, img.getHeight()/2,Graphics.HCENTER|Graphics.VCENTER);
              graph.fillArc(0,0,10,10,0, 360);
         }Now I want to create a .jpg image of this img image(Mutable image).
    What I am doing is that,
    1. I am converting this image in to int array, using getRGB() method.
    2. Then I am converting int array in to byte array.
    3. And then I am opening a file(extension is .jpg)
    4. Then I am sending this byte array in to the file which is .jpg
    The .jpg file is getting created, but the data in it is very absurd, like yyyyyyyyyyyyyyyyyyyyyyyy.
    Please help me in this matter.
    Regards,
    Ashish

  • Question regarding image and links tag

    Hi. Im new to podcasting and have just had my first podcast excepted on itunes.
    Im using garageband.com to store my audio file and copy & pasting the address into itunes to submit it. (http://www.garageband.com/user/wabel/podcast/main.xml)
    What i dont understand is adding an cd cover image and links to a web site.
    I asume its sumular to html, where you type the code with link or image, but where? I cant edit within the above link!
    Please help.

    The "code" for images and links goes into the xml file.
    <?xml version="1.0" encoding="UTF-8"?>
    <rss xmlns:itunes="http://www.itunes.com/dtds/podcast-1.0.dtd" version="2.0">
    <channel>
    <ttl>60</ttl>
    <title></title>
    <link></link>
    <language></language>
    <copyright></copyright>
    <itunes:subtitle></itunes:subtitle>
    <itunes:author></itunes:author>
    <itunes:summary></itunes:summary>
    <itunes:owner>
    <itunes:name>John Doe</itunes:name>
    <itunes:email>[email protected]</itunes:email>
    </itunes:owner>
    <itunes:image href="http://example.com/podcasts/everything/AllAboutEverything.jpg" />
    <itunes:category text=" ">
    <itunes:category text=" "/>
    </itunes:category>
    <item>
    <title></title>
    <itunes:author></itunes:author>
    <itunes:subtitle></itunes:subtitle>
    <itunes:summary></itunes:summary>
    <enclosure url=" " length=" " type=" " />
    <guid></guid>
    <pubDate></pubDate>
    <itunes:duration></itunes:duration>
    <itunes:keywords></itunes:keywords>
    </item>
    </channel
    </rss>

Maybe you are looking for