Tôi đã tìm thấy mã ví dụ cho GestureListenerlớp, nhưng tôi không hiểu phương thức thu phóng:
private float initialScale = 1;
public boolean zoom (float originalDistance, float currentDistance) {
    float ratio = originalDistance / currentDistance; //I get this
    camera.zoom = initialScale * ratio; //This doesn't make sense to me because it seems like every time you pinch to zoom, it resets to the original zoom which is 1. So basically it wouldn't 'save' the zoom right?
    System.out.println(camera.zoom); //Prints the camera zoom
    return false;
}Tôi không giải thích điều này phải không?
zoomStart(float distance)và một zoomStop(float initialDistance, float finalDistance)phương pháp