tags:

views:

54

answers:

1

Hi guys, I have an android application that needs to zoom an image about centre. i implemented the code
Matrix matrix = new Matrix(); matrix.setScale(scaleWidth, scaleHeight); imView.setScaleType(ScaleType.MATRIX); imView.setImageMatrix(matrix); imView.invalidate(); But i get the zooming about top left of the imView(imageView). i need to make it about centre. anybody please help

A: 

Use the four-argument version of setScale that takes a pivot point.

Blrfl
thank you...........
asifkt