Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

//package com.java2s;
import android.hardware.Camera;

import android.util.Log;

import java.util.List;

public class Main {
    public static void listSupportPreviewSize(Camera.Parameters parameters) {
        if (parameters == null) {
            return;
        }
        List<Camera.Size> list = parameters.getSupportedPreviewSizes();
        for (int j = 0; j < list.size(); j++) {
            Camera.Size s = list.get(j);
            Log.i("CameraHelper", "support size : width=" + s.width + ",height=" + s.height);
        }
    }
}