问题描述
我想显示摄像机拍摄的多个图像到网格"视图.我遇到了很多问题,该怎么办,但对我来说却并非完美.我使用此来实施.但是使用它我可以在图像视图中获取图像,但是每当我捕获新图像时,该图像就会替换旧图像.现在我几乎不知道该怎么做才能陆续添加相机图像.任何人都知道如何实现这一点,然后请帮助我提供示例代码.预先谢谢你.
i want to display multiple images capture by camera to Grid view. i go through many questions how to do but non perfectly work for me. i use This to implement. but using this i am able to get the image in my image view but whenever i capture new image that image replace my older image. and now i am clue less what should i do to add camera images one after another. anyone know how to implement this then please help me with sample code. thank you in advance.
推荐答案
使用此链接的答案中提供的注释:
Use the comment provided in the answer in this link:
这应该达到您的目的.希望这可以帮助.让我知道您是否遇到任何问题
This should serve your purpose. Hope this helps. Let me know if you face any issues
您维护了onActivityResult的列表.将列表初始化为类变量表示
You maintain a list out the onActivityResult. Initialize the list as a class variable means
ArrayList<Contact> imageArry = new ArrayList<Contact>();
声明变量时,
在类定义后添加此行.那应该让您添加多张图片
add this line after class definition when you declare your variables. That should make you add multiple images
这篇关于将多个摄像机图像显示到网格视图的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!