I have an application on Google Play published 4 or 5 months ago. The images had shown fine until the last samsung update.
In one part of the code I'm using the following function:
void android.graphics.Canvas.drawBitmap (Bitmap bitmap, Rect src, Rect dst, Paint paint)
The problem is that since the update does not behave as before about the margins when the src
parameter are smaller than dst
.
Before
BEFORE http://www.pegastacus.com/img/others/before_margins_ok.png
After
AFTER http://www.pegastacus.com/img/others/after_margins_bad.png
The value of the params are:
bitmap = A scaled bitmap from BitmapFactory.decodeResource of 328x222 px.
src = [-76, -289, 404, 511]
dst = the entire screen [0,0,480,800]
As you see, the margins should be 76px for left and right and 289px for top and bottom.
Why this suddenly change of behavior? I am lost. Anyone have any idea??