I am modifying the TouchImageView (https://github.com/MikeOrtiz/TouchImageView/issues) to have zoom in and out for when you double tap. I have started as per this post - How
Doubles the current zoom to zoom in, then returns to original zoom level:
float oldScale = 1.0f;
public void zoomIn() {
LogUtil.i(TAG, "Zooming in");
oldScale = saveScale;
saveScale *= 2;
matrix.setScale(saveScale, saveScale);
setImageMatrix(matrix);
invalidate();
}
public void zoomOut() {
LogUtil.i(TAG, "Zooming out");
saveScale = oldScale;
matrix.setScale(saveScale, saveScale);
setImageMatrix(matrix);
invalidate();
}
You might want to translate the matrix to centre on the point the user double clicked.