16

I am trying to develop an application for android phone using flash/as3, I want to know How to browse multiple photos from gallery using media promise or camera roll. Right now I am able to browse only one photo at a time.

       var mediaFile:CameraRoll = new CameraRoll();
       var imagePromise:MediaPromise;
       CameraRoll(mediaFile).browseForImage();

is there any code or resources that I can look at.

caitriona
  • 8,569
  • 4
  • 32
  • 36
Hegde
  • 481
  • 1
  • 8
  • 17
  • It appears based on the CameraRoll documentation that this isn't possible... my guess is that between all the flavors of Android and iOS there wasn't a common built-in app for multiple file selection available on all platforms so AIR doesn't support it. – shaunhusain Jul 23 '12 at 21:04

1 Answers1

1

You have to create the "browser".

You have to read/write the camera roll files one at a time (how all systems work) but your app can save the images and file references and do whatever with the images - user can select multiple images.

Import a file from camera roll, convert to bitmap, manipulate in any way and push into an array. If you're making a gallery, resize the bitmaps to thumbnail size. Your app should only stores the thumbnail bitmap in gpu, the original bmp is the camera roll file.

Here is an example of converting camera roll files to bmp: http://www.flashandmath.com/mobile/cameraroll/

moot
  • 653
  • 5
  • 13
  • Thank you, already tried that link, i need a system to list all the images at once, found a ANE that should work, but is only for IOS https://github.com/rivella50/ANE-CameraRoll I need a similar one for Android – Magico Apr 17 '15 at 06:00
  • That's the answer. You're asking how to code this functionality. Go ahead and remove this question because you're refusing the answer. – moot Apr 17 '15 at 19:06