BlackBerry Forums Support Community
              

Closed Thread
 
Thread Tools
Old 07-15-2005, 03:07 PM   #1
matwi
New Member
 
Join Date: Jun 2005
Model: 7290
Posts: 13
Default Image Manipulation

Please Login to Remove!

Hi

Side info - The blackberry browser has a nice feature in which it allows you to scroll an image vertically and horizontally smoothly with the wheel. It also allows you to save an image so that it can be viewed later.

Having said that, given an image that I have retrieved via my application and storing it in an array of bytes, I want to now display it on the browser so that I use that nice image manipulation and saving feature.

and oh, my images are .png

(Why invent the wheel when its allready been invented)

Any guesses on how to approach this problem will be helpful

Thanks
Offline  
Old 07-18-2005, 04:27 AM   #2
jhfisher
New Member
 
Join Date: Jul 2005
Model: 7100T
Posts: 12
Default

you need help to display the image? luckily i've just done this for another application, this should grab your image byte data and reassemble it to screen:

String bites = (String) store.getContents();
byte bytes[] = bites.getBytes();
Bitmap pngImg = Bitmap.createBitmapFromPNG(bytes,0,bytes.length);
myscreen.add(new BitmapField(pngImg));
Offline  
Old 07-18-2005, 04:52 PM   #3
matwi
New Member
 
Join Date: Jun 2005
Model: 7290
Posts: 13
Default

Quote:
Originally Posted by jhfisher
you need help to display the image? luckily i've just done this for another application, this should grab your image byte data and reassemble it to screen:

String bites = (String) store.getContents();
byte bytes[] = bites.getBytes();
Bitmap pngImg = Bitmap.createBitmapFromPNG(bytes,0,bytes.length);
myscreen.add(new BitmapField(pngImg));
Thank you for answering. I have done that earlier, but it does not have the feature that allows me to move through the screen with my wheel to view a large image.

Example: Open a large image on the blackberry browser, you can press CONTROL and scroll using the wheel, you will scroll horizonatlly, without the CONTROL you will scroll vertically... etc. this is the main feature that i want to be able to perform.
Offline  
Old 07-19-2005, 05:07 AM   #4
jhfisher
New Member
 
Join Date: Jul 2005
Model: 7100T
Posts: 12
Default

ahh right, the answer may be to use net.rim.device.api.browser.field

that way you can display browser data in your apps, not tried it but it may mimic the behaviour you're after by default. other than that you may have to get dirty and knee deep in code.

Last edited by jhfisher; 07-19-2005 at 05:07 AM.. Reason: typo
Offline  
Old 07-20-2005, 12:24 PM   #5
matwi
New Member
 
Join Date: Jun 2005
Model: 7290
Posts: 13
Default

Do you know of any other libraries where such a functionalty exist
(Other than using a browser)
Offline  
Closed Thread



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


Akiles Crimp@Coil Electric Coil Crimpers Machine CrimpACoil W/ Attachments picture

Akiles Crimp@Coil Electric Coil Crimpers Machine CrimpACoil W/ Attachments

$950.00



Ignition Coil for Ford Tractor 12V 2000 3000 4000 5000 Naa600 800 1965 & Up D5TE picture

Ignition Coil for Ford Tractor 12V 2000 3000 4000 5000 Naa600 800 1965 & Up D5TE

$26.38



Utility Aluminum Trim Coil 24

Utility Aluminum Trim Coil 24" x 40-45 FT Long with Minor Scratches and Dents

$84.95



D4PE12029AA 6 Volt Ignition Coil Fits Ford/New Holland Tractor 600 700 800 picture

D4PE12029AA 6 Volt Ignition Coil Fits Ford/New Holland Tractor 600 700 800

$26.44



1100-0541 6 Volt Ignition Coil for Ford Tractor 2N 8N 9N Front Mount 9N12024 picture

1100-0541 6 Volt Ignition Coil for Ford Tractor 2N 8N 9N Front Mount 9N12024

$27.36



Ignition Coil 6 Volt Fits IH Fits FARMALL and Fits International Tractors picture

Ignition Coil 6 Volt Fits IH Fits FARMALL and Fits International Tractors

$37.99







Copyright © 2004-2016 BlackBerryForums.com.
The names RIM © and BlackBerry © are registered Trademarks of BlackBerry Inc.