androidsd卡图片路径
Ⅰ android手机里的照片在哪个文件夹里
android手机里的照片在DCIM-Camera文件夹。
具体步骤:
1、先将手机与电脑相连,在电脑上找到可移动磁盘设备,点击打开。
(1)androidsd卡图片路径扩展阅读:
定义
1. DCIM (Data Center Infrastructure management) 数据中心基础设施管理 是将IT(信息技术)和设备管理结合起来对数据中心关键设备进行集中监控、容量规划等集中管理。通过软件、硬件和传感器等,DCIM提供一个独立的管理平台,对数据中心IT设备和基础设施进行实时监控和管理。
3. 离散福镜像法:方程(MPIE)的矩量法是目前分析微带结构的主要方法之一.MPIE算法的核心是空域格林函数的求解.提出了二级离散复镜像法(DCIM)与表面波处理相结合的方法对空域格林函数进行计算.根据表面波的性质,提出了2种二级DCIM和表面波相结合的方案,分段比较两方案的...
4. 接口模块:Dominion 电脑接口模块 (DCIM),这是一种非常小的转接头,直接插入服务器的键盘、视频及鼠标连接端口。
5. DCIM(Data Center Integrated Management)数据中心集成管理
Ⅱ 安卓手机相片在什么位置
安卓手机拍照后照片存放的位置默认为:/sdcard/DCIM/100MEDIA 或者 /sdcard/DCIM/Camera文件夹里边,这里的sdcard是指手机中的SD卡。
根据不同安卓手机系统的后期开发,文件夹名称可能不太一样,但安卓手机的相片一定是在DCIM目录文件夹里边。
(2)androidsd卡图片路径扩展阅读:
Android的系统架构和其操作系统一样,采用了分层的架构。从架构图看,Android分为四个层,从高层到低层分别是应用程序层、应用程序框架层、系统运行库层和Linux内核层。
Android会同一系列核心应用程序包一起发布,该应用程序包包括客户端,SMS短消息程序,日历,地图,浏览器,联系人管理程序等。所有的应用程序都是使用JAVA语言编写的。
开发人员也可以完全访问核心应用程序所使用的API框架。该应用程序的架构设计简化了组件的重用;任何一个应用程序都可以发布它的功能块并且任何其它的应用程序都可以使用其所发布的功能块(不过得遵循框架的安全性)。同样,该应用程序重用机制也使用户可以方便的替换程序组件。
Ⅲ 如何正确获得Android内外SD卡路径
/**
* 获取手机自身内存路径
*
*/
public static String getPhoneCardPath(){
return Environment.getDataDirectory().getPath();
}
/**
* 获取sd卡路径
* 双sd卡时,根据”设置“里面的数据存储位置选择,获得的是内置sd卡或外置sd卡
* @return
*/
public static String getNormalSDCardPath(){
return Environment.getExternalStorageDirectory().getPath();
}
/**
* 获取sd卡路径
* 双sd卡时,获得的是外置sd卡
* @return
*/
public static String getSDCardPath() {
String cmd = "cat /proc/mounts";
Runtime run = Runtime.getRuntime();// 返回与当前 Java 应用程序相关的运行时对象
BufferedInputStream in=null;
BufferedReader inBr=null;
try {
Process p = run.exec(cmd);// 启动另一个进程来执行命令
in = new BufferedInputStream(p.getInputStream());
inBr = new BufferedReader(new InputStreamReader(in));
String lineStr;
while ((lineStr = inBr.readLine()) != null) {
// 获得命令执行后在控制台的输出信息
Log.i("CommonUtil:getSDCardPath", lineStr);
if (lineStr.contains("sdcard")
&& lineStr.contains(".android_secure")) {
String[] strArray = lineStr.split(" ");
if (strArray != null && strArray.length >= 5) {
String result = strArray[1].replace("/.android_secure",
"");
return result;
}
}
// 检查命令是否执行失败。
if (p.waitFor() != 0 && p.exitValue() == 1) {
// p.exitValue()==0表示正常结束,1:非正常结束
Log.e("CommonUtil:getSDCardPath", "命令执行失败!");
}
}
} catch (Exception e) {
Log.e("CommonUtil:getSDCardPath", e.toString());
//return Environment.getExternalStorageDirectory().getPath();
}finally{
try {
if(in!=null){
in.close();
}
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
try {
if(inBr!=null){
inBr.close();
}
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}
return Environment.getExternalStorageDirectory().getPath();
}
//查看所有的sd路径
public String getSDCardPathEx(){
String mount = new String();
try {
Runtime runtime = Runtime.getRuntime();
Process proc = runtime.exec("mount");
InputStream is = proc.getInputStream();
InputStreamReader isr = new InputStreamReader(is);
String line;
BufferedReader br = new BufferedReader(isr);
while ((line = br.readLine()) != null) {
if (line.contains("secure")) continue;
if (line.contains("asec")) continue;
if (line.contains("fat")) {
String columns[] = line.split(" ");
if (columns != null && columns.length > 1) {
mount = mount.concat("*" + columns[1] + "\n");
}
} else if (line.contains("fuse")) {
String columns[] = line.split(" ");
if (columns != null && columns.length > 1) {
mount = mount.concat(columns[1] + "\n");
}
}
}
} catch (FileNotFoundException e) {
// TODO Auto-generated catch block
e.printStackTrace();
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
return mount;
}
//获取当前路径,可用空间
public static long getAvailableSize(String path){
try{
File base = new File(path);
StatFs stat = new StatFs(base.getPath());
long nAvailableCount = stat.getBlockSize() * ((long) stat.getAvailableBlocks());
return nAvailableCount;
}catch(Exception e){
e.printStackTrace();
}
return 0;
}
Ⅳ android怎么从sd卡指定的文件夹中获取所有图片的路径URL,谢谢~感谢各位大神了
直接调用文件管理器选择图片即可。
1、调用系统提供的图片选择器,代码如下:
//注意,在Android4.4系统下建议使用 Intent.ACTION_OPEN_DOCUMENT方式
if (Utility.isKK()) {
Intent intent = new Intent(Intent.ACTION_OPEN_DOCUMENT);
intent.addCategory(Intent.CATEGORY_OPENABLE);
intent.setType("image
public static String getDataColumn(Context context, Uri uri, String selection,
String[] selectionArgs) {
Cursor cursor = null;
final String column = "_data";
final String[] projection = {
column
};
处理返回结果:
protected void onActivityResult(int requestCode, int resultCode,
Intent intent) {
super.onActivityResult(requestCode, resultCode, intent);
if (resultCode == RESULT_OK) {
switch (requestCode) {
case PIC_RESULT://选择图库
case PIC_RESULT_KK:
imageFileUri = intent.getData();//获取选择图片的URI
break;
}
}
2、除此自外,系统还提供一种选择器,这个图片选择器可以屏蔽掉那个auto backup的目录.所以就开始打算用这个图片选择器来选图片了.
Intent intent=new Intent(Intent.ACTION_GET_CONTENT);//ACTION_OPEN_DOCUMENT
intent.addCategory(Intent.CATEGORY_OPENABLE);
intent.setType("image/jpeg");
if(android.os.Build.VERSION.SDK_INT>=android.os.Build.VERSION_CODES.KITKAT){
startActivityForResult(intent, SELECT_PIC_KITKAT);
}else{
startActivityForResult(intent, SELECT_PIC);
}
为什么要分开不同版本呢?其实在4.3或以下可以直接用ACTION_GET_CONTENT的,在4.4或以上,官方建议用ACTION_OPEN_DOCUMENT,主要区别是他们返回的Uri.4.3返回的是带文件路径的,而4.4返回的却是content://com.android.providers.media.documents/document/image:3951这样的,没有路径,只有图片编号的uri.可以通过以下方式,处理URI。
参考:Android 4.4从图库选择图片,获取图片路径并裁剪
public static String getPath(final Context context, final Uri uri) {
final boolean isKitKat = Build.VERSION.SDK_INT >= Build.VERSION_CODES.KITKAT;
// DocumentProvider
if (isKitKat && DocumentsContract.isDocumentUri(context, uri)) {
// ExternalStorageProvider
if (isExternalStorageDocument(uri)) {
final String docId = DocumentsContract.getDocumentId(uri);
final String[] split = docId.split(":");
final String type = split[0];
if ("primary".equalsIgnoreCase(type)) {
return Environment.getExternalStorageDirectory() + "/" + split[1];
}
// TODO handle non-primary volumes
}
// DownloadsProvider
else if (isDownloadsDocument(uri)) {
final String id = DocumentsContract.getDocumentId(uri);
final Uri contentUri = ContentUris.withAppendedId(
Uri.parse("content://downloads/public_downloads"), Long.valueOf(id));
return getDataColumn(context, contentUri, null, null);
}
// MediaProvider
else if (isMediaDocument(uri)) {
final String docId = DocumentsContract.getDocumentId(uri);
final String[] split = docId.split(":");
final String type = split[0];
Uri contentUri = null;
if ("image".equals(type)) {
contentUri = MediaStore.Images.Media.EXTERNAL_CONTENT_URI;
} else if ("video".equals(type)) {
contentUri = MediaStore.Video.Media.EXTERNAL_CONTENT_URI;
} else if ("audio".equals(type)) {
contentUri = MediaStore.Audio.Media.EXTERNAL_CONTENT_URI;
}
final String selection = "_id=?";
final String[] selectionArgs = new String[] {
split[1]
};
return getDataColumn(context, contentUri, selection, selectionArgs);
}
}
// MediaStore (and general)
else if ("content".equalsIgnoreCase(uri.getScheme())) {
// Return the remote address
if (isGooglePhotosUri(uri))
return uri.getLastPathSegment();
return getDataColumn(context, uri, null, null);
}
// File
else if ("file".equalsIgnoreCase(uri.getScheme())) {
return uri.getPath();
}
return null;
}
public static String getDataColumn(Context context, Uri uri, String selection,
String[] selectionArgs) {
Cursor cursor = null;
final String column = "_data";
final String[] projection = {
column
};
try {
cursor = context.getContentResolver().query(uri, projection, selection, selectionArgs,
null);
if (cursor != null && cursor.moveToFirst()) {
final int index = cursor.getColumnIndexOrThrow(column);
return cursor.getString(index);
}
} finally {
if (cursor != null)
cursor.close();
}
return null;
}
public static boolean isExternalStorageDocument(Uri uri) {
return "com.android.externalstorage.documents".equals(uri.getAuthority());
}
public static boolean isDownloadsDocument(Uri uri) {
return "com.android.providers.downloads.documents".equals(uri.getAuthority());
}
public static boolean isMediaDocument(Uri uri) {
return "com.android.providers.media.documents".equals(uri.getAuthority());
}
public static boolean isGooglePhotosUri(Uri uri) {
return "com.google.android.apps.photos.content".equals(uri.getAuthority());
}
3、使用其它开源组件如PhotoView。
Ⅳ android 手机照相机拍照的照片,默认的保存路径是什么。
装了SD卡的:
/sdcard/DCIM/camera
未装SD卡的:
/stystm/DCIM/camera
一般安卓手机的相机功能都会有固定的存放路径,这个位置默认为:/sdcard/DCIM/100Andro或者/sdcard/DCIM/Camera,这里的sdcard是指手机中的SD卡,在电脑中显示的为可移动磁盘。
根据不同品牌安卓手机的后期开发,文件夹名称可能不太一样,但一般是在DCIM目录文件夹里边,当然也会有特别,例如在酷派手机中手机拍照的图片是存放在根目录中的Photo中。
首先,打开手机上的相机,点击设置按钮,里面会有一个选择存储位置,一般默认是存储在手机内存,可以进行修改,存到SD卡中。通过数据线连接到电脑后,一般是一个叫DCIM的文件。
(5)androidsd卡图片路径扩展阅读:
手机摄像头的技术:
“像素”指的是相机传感器上的最小感光单位,通常所说的“XXX万像素”实际是指相机的分辨率,其数值大小主要由相机传感器中的像素点(即最小感光单位)数量决定。
相机的像素能决定的是其所拍图片的分辨率,而图片的分辨率越高,只代表了图片的尺寸越大,并不能说明图片越清晰。
传感器
相机传感器主要分两种,CCD和CMOS。同时代的CMOS比CCD的开口率要低很多(也就是相同面积下,感光芯片真正接收光的面积CCD会比较大)。富士等创新型cmos的出现,CCD因为成本高,成像上越来越没优势就被淘汰了。
CMOS传感器又分为背照式和堆栈式两种,二者系出同门,技术最早都由索尼研发,索尼背照式传感器品牌名为“ExmorR”,堆栈式传感器为“ExmorRS”。
相对来说,传感器尺寸越大,感光性能越好,捕捉的光子(图形信号)越多,信噪比越高,成像效果自然也越出色,然而更大的传感器却会导致手机的体积、重量、成本增加。
Ⅵ 获取android手机的自带存储路径和sdcard存储路径
android手机获取自带存储路径和sd卡存储路径的方式是:
调用Environment.getExternalStorageDirectory,返回的存储目录并不是系统内置的SD卡目录。
1、手机将eMC存储挂载到 /mnt/external_sd 、/mnt/sdcard2 等节点,而将外置的SD卡挂载到 Environment.getExternalStorgeDirectory这个结点。
(6)androidsd卡图片路径扩展阅读:
Android在正式发行之前,最开始拥有两个内部测试版本,并且以着名的机器人名称来对其进行命名,它们分别是:阿童木(AndroidBeta),发条机器人(Android 1.0)。后来由于涉及到版权问题,谷歌将其命名规则变更为用甜点作为它们系统版本的代号的命名方法。
Android的系统架构和其操作系统一样,采用了分层的架构。从架构图看,Android分为四个层,从高层到低层分别是应用程序层、应用程序框架层、系统运行库层和Linux内核层。
Ⅶ Android SD卡路径问题以及如何获取SDCard 内存详解
较好的方法是通过Environment
来获取路径,最后给出一个例子,教你怎样获取SDCard
的内存,显示出来告诉用户。讲述的内容如下:0202
0、获取sd卡路径。
1、讲述
Environment
类。
2、讲述
StatFs
类。
3、完整例子读取
SDCard
内存
0、获取sd卡路径
方法一:
private
String
folder
=
"/sdcard/DCIM/Camera/"(SD卡上拍照程序的图片存储路径);
//写死绝对路径,不赞成使用方法二: