Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7404681
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 29, 20262026-05-29T05:17:25+00:00 2026-05-29T05:17:25+00:00

I’m working on an application where the user is able to select files, either

  • 0

I’m working on an application where the user is able to select files, either a new image from the camera, an image from the gallery, or a plain old file. It then shows an icon and the name for the selected item. I have this working with one exception. The gallery application integrates picasaweb pictures. If the user selects a picture from a picasa album, I’m not able to get a thumbnail for it.

I’m using the MediaStore.Images.Thumbnails.getThumbnail() method, and it works for other images in the gallery just fine, but for the picasaweb files, I get, regardless of what “kind” of thumbnail I attempt to get (although MICRO is what I’m after):

ERROR/MiniThumbFile(2051): Got exception when reading magic, id =
5634890756050069570, disk full or mount read-only? class
java.lang.IllegalArgumentException

I noticed the URI’s given for the selected files are different. The local image files look like:

content://media/external/images/media/6912

and the picasaweb urls look like:

content://com.android.gallery3d.provider/picasa/item/5634890756050069570

I attempted to use a query to get at the raw THUMB_DATA, using Thumbnails.queryMiniThumbnails(), with Thumbnails.THUMB_DATA in the projection array, but I got a “no such column” error.

Is there another method for getting thumbnails that would work better? And will I have the same problem when I try and access the full image data?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-29T05:17:26+00:00Added an answer on May 29, 2026 at 5:17 am

    What I have found is that on my Galaxy Nexus, the images for Picassa are stored in one of subdirectories under the /sdcard/Android/data/com.google.android.apps.plus/cache directory. When the content provider is com.google.android.gallery3d.provider then the number after “item” in the URL contains the name of the image (in your example above “5634890756050069570”). This data correspondes to a file in one of the subdirectories under /sdcard/Android/data/com.google.android.apps.plus/cache with the extension “.screen”. If you were to copy this image from your phone (in your case 5634890756050069570.screen) using DDMS and rename it with the extension “.jpeg” you could open it and view it on your computer.

    The following onActivityResult method will check for this content provider being returned, and then will recursively search for the file in the /sdcard/Android/data/com.google.android.apps.plus/cache directory. The private member variable fileSearchPathResults is filled in by the recursive search method walkDirectoryRecursivelySearchingForFile().

    private String fileSearchPathResult = null;
    
    protected void onActivityResult(int requestCode, int resultCode, Intent data) {
        Uri selectedImage = data.getData();
                String[] filePathColumn = { MediaStore.Images.Media.DATA };
                String filePath = null;
    
                // This code is required to get the image path on content providers
                // on API > 10 where the image is from a picassa web album, since Google changed
                // the content provider in versions with API > 10
                if (selectedImage.toString().contains("com.google.android.gallery3d.provider")) {
                    StringBuilder contentProviderPath = new StringBuilder(selectedImage.toString());
                    int beginningIndex = contentProviderPath.lastIndexOf("/");
                    String fileNameWithoutExt = contentProviderPath.subSequence(beginningIndex + 1,
                            contentProviderPath.length()).toString();
                    Log.i(TAG, fileNameWithoutExt);
                    try {
                        File path = new File("/sdcard/Android/data/com.google.android.apps.plus/cache");
                        if (path.exists() && path.isDirectory()) {
                            fileSearchPathResult = null;
                            walkDirectoryRecursivelySearchingForFile(fileNameWithoutExt, path);
                            if (fileSearchPathResult != null) {
                                filePath = fileSearchPathResult;
                            }
                        }
                    } catch (Exception e) {
                        Log.i(TAG, "Picassa gallery content provider directory not found.");
                    }
                }
        }
    
    
        public void walkDirectoryRecursivelySearchingForFile(String fileName, File dir) {
            String pattern = fileName;
    
            File listFile[] = dir.listFiles();
            if (listFile != null) {
                for (int i = 0; i < listFile.length; i++) {
                    if (listFile[i].isDirectory()) {
                        walkDirectoryRecursivelySearchingForFile(fileName, listFile[i]);
                    } else {
                        if (listFile[i].getName().contains(pattern)) {
                            fileSearchPathResult = listFile[i].getPath();
                        }
                    }
                }
            }
        }
    

    With the filePath, you can create a Bitmap of the image with the following code:

            Bitmap sourceImageBitmap = BitmapFactory.decodeFile(filePath);
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a bunch of posts stored in text files formatted in yaml/textile (from
link Im having trouble converting the html entites into html characters, (&# 8217;) i
For some reason, after submitting a string like this Jack’s Spindle from a text
I have a string like this: La Torre Eiffel paragonata all&#8217;Everest What PHP function
I want use html5's new tag to play a wav file (currently only supported
I am currently running into a problem where an element is coming back from
I'm parsing an RSS feed that has an &#8217; in it. SimpleXML turns this
I need to clean up various Word 'smart' characters in user input, including but
I have a text area in my form which accepts all possible characters from
Does anyone know how can I replace this 2 symbol below from the string

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.