Mám ImageView, že chcem ukázať len časti z času na čas. Ale začínajúc rovnakými súradnicami x, y. Existuje jednoduchý spôsob, ako to urobiť?
odpovede:
0 pre odpoveď č. 1skontrolujte to
Drawable drawable = getResources().getDrawable(R.drawable.image);
Bitmap bitmap = ((BitmapDrawable) drawable ).getBitmap();
bitmap= Bitmap.createBitmap(bitmap , startX, startY, width, height);
imgview.setBackgroundDrawable(new BitmapDrawable(bitmap));
môžete tiež zmeniť obrázok
Bitmap resizedImage = Bitmap.createScaledBitmap(bitmap, scrwidth, scrwidth, false);