enable Camera Zoom - Android Camera

Android examples for Camera:Camera Zoom

Description

enable Camera Zoom

Demo Code


import android.hardware.Camera;
import android.hardware.Camera.AutoFocusCallback;

public class Main{
    /**/*from w  w  w .jav a  2s  . c  o  m*/
     *
     * @param camera
     * @return
     */
    public static boolean enableZoom(final Camera camera) {
        final Camera.Parameters params = camera.getParameters();
        return params.isZoomSupported();
    }
    /**
     *
     * @return
     */
    public boolean enableZoom() {
        return enableZoom(this.camera);
    }
}

Related Tutorials