Hello, I have written some code to get a cropped image from the phone which I've tested and is working on both the Android emulator and on the G1 hardware. The behavior is different on the Motorola Droid so I could use some help figuring this out.
I'm creating an intent to get the cropped image with this code segment:
Intent intent = new Intent(Intent.ACTION_GET_CONTENT);
intent.setType("image/*");
intent.putExtra("crop", "true");
intent.putExtra("outputX", width);
intent.putExtra("outputY", height);
intent.putExtra("aspectX", width);
intent.putExtra("aspectY", height);
intent.putExtra("scale", true);
intent.putExtra("noFaceDetection", true);
intent.putExtra("setWallpaper", false);
intent.putExtra("return-data", true);
I'm then calling startActivityForResult() passing the intent. This brings up the gallery browser on the phone alowing me to select an image and it will go into crop mode. This all works consistenlty across devices.
The difference is what happens after I've clicked Save after selecting my crop region. On the Motorola Droid it will simply return back to the gallery browser showing all the images.
The expected behavior and what happens in the emulator is my onActivityResult() is called where I then have the following code to grab the bitmap:
final Bundle extras = data.getExtras();
Bitmap bitmap = extras.getParcelable("data");
I'd appreciate any help as to the differences in the API and if there are changes I need to make to have this work on the Droid.
Thank you!
相关推荐
Ad Oculos Digital Image Processing_cropped2英文原版
这个matlab程序能够实现裁剪图像感兴趣区域,适合初学的。
wxPython GUI with ROI(crop) hover effect, also save main and cropped image with button (right or left click).
精通LINUX设备驱动开发_Cropped1
裁剪图像 任何比例中心的裁剪图像 在 imageview 中,您只能使用CENTER-CROP (0.5,0.5) ,但它在 imageview 上显示图像的中心(0.5,... android : id = " @+id/iv_cropped_land_left " android : scaleType = " matrix
蛋白质的糖基化作用分类及相关数据库_cropped
AR face database which contains 100 persons, each person has 26 gray and cropped images
hands mask of GTEA (with GTEA GAZE PLUS) ,1067 labeled frames, each frame of GTEA is 405x720, each frame of GTEA GAZE PLUS is 720x960.
It returns an optionally scaled and/or cropped HTML img or canvas element. It also provides methods to parse image meta data to extract IPTC and Exif tags as well as embedded thumbnail images and to ...
实现生成对抗网络(Generative-Adversarial-Networks,GAN)的工程实现。...* Train Age-cGAN on Wiki-Cropped images to improve face verification * Use conditional GANs for image-to-image translation
自动裁剪 自动裁剪功能非常适合您的网站的个人资料图片处理或ID卡的批处理工作,它将以检测...# Get a Numpy array of the cropped image cropped_array = cropper . crop ( 'portrait.png' ) # Save the cropped imag
[Gray___Meyer]_Analysis_and_Design_of_Analog_Integrated_Circuits_5th_cropped.pdf
这是一个学习语言的例程,对学习很有好处
一个常用的人脸数据库。可以做人脸识别,头部姿态对齐等工作
随机裁剪占位符 ...git clone https://github.com/dswaby/random-cropped-placeholder <sudo> npm install 将图像添加到源图像文件夹 创建 imagelist.json 列表图像 访问 这个项目最初是从派生出来的
该源码案例是一个实现人脸识别的工具库,源码...getFullDebugImage(Bitmap bitmap), to obtain a non-cropped image as the original, but with the detected faces painted, and the cropped area painted in green.
人脸数据库umist数据,处理成.mat格式
image sensor offering 720p high definition video capture at 30 frames per second (fps) in an industry- leading miniaturized form factor. The low-power 1/9-inch OV9724 CameraChipTM sensor is built on ...
= Some of my tags occasionally hit the sides of the movie and are cropped = If this happens you should change the aspect for the movie to make it wider. This can be done by increasing the width, but ...
R软件代码转换为matlab 将大鼠SPECT扫描归一化为MRI图集 有关如何将SPECT扫描扭曲至MRI大鼠图谱的文档。 信息 每只动物都有一个SPECT和一个CT扫描。 这些扫描是对齐的。...(Cropped image files) |-