Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. COThanks for your answer. Sorry for leaving no picture. It is a pixel-art bitmap. There is just the problem that I don't know, which size and resolution my image should have and which folder(drawable, drawable-hdpi, drawable-normal-mdpi and so on) it has to be in. I already studied the pages of google talking about this topic but this gives me no clue. The width of the image is the width of the screen, the height is set to 80dip. Another question: why is this the 'rare case'?
      singulars
    2. CO@Till: because most of the time, you will usually use vector images or images that is smooth and so can be rescaled automatically. Pixel-art, on the other hand, usually requires manual tweaking to the rescaled image. Try disabling bilinear filtering (and so, using nearest-neighbor filter), and see if it works better in your case: `Bitmap.createScaledBitmap(backgroundImage, (int) (canvasWidth * sf), canvasHeight, false);`. Make sure to resize only to an integer or a small fraction multiples of the original image (e.g. if original is 100x100, you can try 300x300, 200x200, 50x50, 25x25, 20x20)
      singulars
    3. CO@Till: try to play in Photoshop or GIMP or whatever your favorite image editor is, and try to find a setting which looks acceptable, and then try to reproduce this setting in Android (or just ships multiple bitmaps if you can't reproduce the setting in Android). Make sure to use nearest neighbor filtering or a specialized pixel-art rescale filter (e.g. scale2x), since you don't want the blurred edges that other rescale filters makes (those filters are useful for photos, where the blurred edges increases the "perceived" image resolution; in your case you want a clean, crisp edge)
      singulars
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload