2011-12-21 4 views

답변

10
ImageView imageView = (ImageView)findViewById(R.id.imageview); 
Drawable drawable = imageView.getDrawable(); 
Rect imageBounds = drawable.getBounds(); 

그런 다음 Matrix.mapRect를 사용하십시오.

+1

위대한 작품입니다. – saarraz1

+0

다행스럽게도 –

+0

나를위한 완벽한 코드는 입니다. Rect bounds = imageView.getDrawable(). getBounds(); RectF boundsF = new RectF (경계); imageView.getImageMatrix(). mapRect (boundsF); boundsF.round (bounds); ' 감사합니다. 작동 했으므로 마침내 전환을 수정했습니다! – charlag

관련 문제