2

对于我的应用程序,我希望能够以各种分辨率/质量捕获视频。根据 API,只有两个选项:0 或 1:

    Intent i = new Intent("android.media.action.VIDEO_CAPTURE");
    i.putExtra(MediaStore.EXTRA_OUTPUT, MediaStore.Images.Media.EXTERNAL_CONTENT_URI);
    i.putExtra(android.provider.MediaStore.EXTRA_VIDEO_QUALITY, 1);

如何设置视频分辨率:1 提供最好的 1080p,0 提供 MMS 质量(可怕)。

ICS Android 原生相机提供 3 个选项:SD、720p、1080p,我如何获得这些。

4

1 回答 1

2

Using the intent for recording video, as you noted, you have two choices.... If you want more choices, you will need to write your own video recorder.

See http://developer.android.com/guide/topics/media/camera.html#capture-video for more information. VERY IMPORTANT: Note the section on MediaRecorder that gives you the options and the sequence that they MUST be entered in. Among those you will find options for video size, frame rate, audio and video encoding bit rates, etc.

Later,
--jim

于 2012-07-02T03:50:06.610 回答