The resolution of the bitmap I'm using is 480 x 480.
When I'm trying to get the width of this bitmap inside of onSurfaceChanged using bellow code.
public void onSurfaceChanged(SurfaceHolder holder, int format, int width, int height) {
super.onSurfaceChanged(holder, format, width, height);
bDialBg = BitmapFactory.decodeResource(getResources(), R.drawable.dial_bg);
scale = ((float) width) / (float) bDialBg.getWidth();
}
bDialBg.getWidth() result supposed to be 480 as my image is 480x480 instead the result is 720.
I double checked the image resolution I'm using, I also resized the image again using Photoshop which is 480 x 480. but still the result of bDialBg.getWidth() is 720.