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

  • Home
  • SEARCH
  • 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 8197855
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T05:49:38+00:00 2026-06-07T05:49:38+00:00

I am loading images in an ImageView from url. (from RSS feed) The problem

  • 0

I am loading images in an ImageView from url. (from RSS feed)

The problem is that the resolution of the loaded image is lower than the original image !!

I searched Stackoverflow and found that the solution is to set the “inScaled” option to false to prevent image re-scaling.
but, this solution didn’t work for me.

Here is the code:

    URL feedImage= new URL(img_link);
    HttpURLConnection conn= (HttpURLConnection)feedImage.openConnection();
    InputStream is = conn.getInputStream();
    BitmapFactory.Options  BFoptions = new BitmapFactory.Options();
    BFoptions.inScaled = false;
    Bitmap img = BitmapFactory.decodeStream(is,null, BFoptions);
    int density = img.getDensity(); Log.e("img", "Image density is " + density);
    int width =img.getWidth(); Log.e("img", "Image width is " + width);
    int height  = img.getHeight(); Log.e("img", "Image height is " + height);

    my_image.setImageBitmap(img);

The variables density, width and height are lower than the original image’s values.

and here is a part of my layout:

<RelativeLayout 
    xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:ads="http://schemas.android.com/apk/lib/com.google.ads" 
    android:layout_width="fill_parent"
    android:layout_height="fill_parent"
    android:orientation="vertical">


            <ImageView
                    android:id="@+id/joke_image"
                    android:layout_width="match_parent"
                    android:layout_height="match_parent"         
                    android:contentDescription="temp description"/>


            <ScrollView
                    android:id="@+id/SV"
                    android:layout_width="fill_parent"
                    android:layout_height="30dp"
                    android:background="@drawable/background"
                    android:paddingTop="10dp"
                    android:paddingLeft="10dp"
                    android:paddingRight="10dp"
                    android:paddingBottom="50dp">

                    <!-- bla 
                         bla 
                         bla  

                         -->


            </ScrollView>   
</RelativeLayout>

Thanks in advance

  • 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-06-07T05:49:40+00:00Added an answer on June 7, 2026 at 5:49 am

    Finally it was solved 🙂

    It appeared to be not related to the code or the ImageViews, …..

    All the images in the RSS feeds are thumbnails … which is the reason that they appear small in the app but large in the website.

    So the solution was to replace the “_s.jpg” at the end of each image’s url with “_n.jpg” 🙂

    I hope this answer will help someone else 🙂

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

i m loading an image from an url and displaying it in imageView .i
I'm loading the image from the url by using LoadImage method and storing it
I have this code that pulls an image from an url and displays it
I am loading an image from an URL on button click, and storing it
I have problem with loading images from the Documents folder of iPhone application into
I'm dynamically loading images from a web service. The images will be loaded (with
i have a listview that displays images from a directory and it is loading
I get images from a URL using XML Parsing. I loaded the all images
Loading images from URL into a uiimage and then adding those images to a
I am loading image from url coming from xml image not showing image CGRect

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.