Image save filure [closed]
- List item
Hi, I've got vety tricky problem. My app fails to write image. Problem is not usual because on a different phone it worked perfectly.
Image saving fails on SE wt19i. SdCard works ok - phone can save photos with no problem. Moreover I
file.mkdirs()
also work as it should.
Of course I have correct manifest file: <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
What could possibly cause failure ?
Here is my code:
private boolean saveImage (Mat mat) {
File path = new File(Environment.getExternalStorageDirectory() + "/Images/");
path.mkdirs();
File file = new File(path, "SeCam " + new Date() + ".jpeg");
String filename = file.toString();
return Highgui.imwrite(filename, mat);
}
probably imwrite can't open the file for writing, since 'file' is still opened ?