Android ImageView image display problem where the image downloaded from web - android

I use something like this to download image from web. The image is normally displays on web. Here is the link of the Image. It downloads on Android device successfully but not displaying on an ImageView control. And this Image downloads and showing successfully. What can be causes some specific images can't be showen by Android ImageView control?
Android API Level: 7
Thank you!

This image cannot be displayed in Android Browser:
http://www.mekanist.net/img/places/75/faros_20110909125521412.jpg
This problem may be caused by unsupported details of jpeg image format.
You should consider to investigate the thumb-maker code.

Drawable img = Drawable.createFromPath(filePath);
filePath is the image you downloaded on your phone sdcard absolute path
ImageView ivPic=(ImageView) findViewById(R.id.ivPic);;
ivPic.setImageDrawable(img);

Related

How to update image by a developer that is set into a imageview by load(url) method of glide?

I am new in android app developing and got stuck in this problem. To understand my problem -
Let, I am a developer and I have an app. The app has a imageview. In that imageview, the image will be loaded using glide load(url) method from my(developer) website. Now I(developer) want to change the image that will be shown in the app same imageview. But if I change the image the image url will be changed and glide load(url) method will not be able to download new image? How can I solve this problem or what topic should learn to handle this issue or what is the alternative?
Download image
Save to disk (optional)
Modify image (optional)
Show modified image in ImageView.
(You don't need glide here)

Download blur image before actual image gets downloaded in android

I want to do image downloading as whatsapp does as blur images appear and when we click on image clear image gets downloaded.I want to do the same kind of work in my android App.Can anyone suggest how to achieve this?
You can use any image loading liabrary(Picasso,Glide or UIL)
Firstly load image of low quality say if you using Picasso
Picasso.with(this).load("....").resize(100,100).into(imageViews);
than on click load full image.

Convert pdf from link to image and then share

I am searching for a library, sdk whatever, which converts a pdf (from a link) to an image, and then I want to share this image without leaving any trails (random png images left of the conversion or a downloaded pdf file somewhere). Has anyone any ideas on what and how I should do this?
Thanks in advance.
If you open pdf into webview then follow this step
WebView pdfWebView;
Bitmap pdfBitMap;
pdfWebView.buildDrawingCache();
pdfBitMap = pdfWebView.getDrawingCache();

Android how to load Image file with different extension using Picasso

This is a different situation. I want to load a image file which has stored with different extension like 'photo.xyz' instead of 'photo.jpg or photo.png' using Picasso. to avoid image from gallery i am storing image like this. Please help me is there any option to show like this.
Neither Picasso nor Android (which does the actual image decoding) cares what the file name is. It can be anything. The type of the image is always determined from the first few bytes of the actual image data.
As a small workaround you can programmatically put .nomedia file into your app folder to prevent images to be cached by mediaserver and displayed in a Gallery app.

Load animated image from url on android

I've one url
http://radblast.wunderground.com/cgi-bin/radar/WUNIDS_composite?maxlat=38.35494788602722&maxlon=-121.87068343162537&minlat=37.180387917398&minlon=-122.96931557357311&rainsnow=1&smooth=1&frame=0&num=10&alpha=1&delay=10&cors=1&theext=.gif&nodebug=0&png=0&min=1&noclutter=0&radar_bitmap=1&noclutter_mask=1&brand=wundermap&width=800&height=1082
It has no of image animated.
I want to show the image on in my app not in browser and webview.
how to show it?
I've tried to downlaod the image and stored on sdcard.
i've checked
http://weavora.com/blog/2012/02/07/android-how-to-use-animated-gif/
but i dont know how to load the gif image from sd card path.

Categories

Resources