Let me know what progress you do/don't make with this. I haven't done it so it would be good to know.
Thanks
Also,
file:///root1/ is the temp directory where the image needs to be located when testing with emulator.
when you run the emulator you will see an output line in the console that indicates where your "storage root" is located.
What I do is start the emulator, but before launching the Midlet navigate to the temp directory and drop the image file in. I don't know of a better/automatic way to have the image generated in the temp directory.
Main Topics
Browse All Topics





by: CodeFishPosted on 2009-01-27 at 07:27:17ID: 23477290
You should look at the FileConnection API: mobility/a pis/articl es/ filecon nection/ mobility/a pis/ttips/ fileconnec tion/
/Java/J2ME /ImageLoad er.htm
ini/j2me/J PEG_Encode r
/229101/Ja va-Micro-E dition/jav a/ jme-uplo ad-image-f ile-captur ed but haven't enough time/expertise to get it running:
http://developers.sun.com/
http://developers.sun.com/
You need to save/load the image via byte streams.
This example loads an image from over the network:
http://www.java2s.com/Code
The principles are the same, but instead of HttpConnection you want to use FileConnection.
I haven't tried it, but this looks promising:
http://ce.sharif.edu/~p_am
The code is difficult to follow, but it may help.
I tried to rework this code found at http://www.coderanch.com/t
Select allOpen in new window