public class MediaRecorder extends Object
| Modifier and Type | Class and Description |
|---|---|
class |
MediaRecorder.AudioEncoder |
class |
MediaRecorder.AudioSource |
static interface |
MediaRecorder.OnErrorListener |
static interface |
MediaRecorder.OnInfoListener |
class |
MediaRecorder.OutputFormat |
class |
MediaRecorder.VideoEncoder |
class |
MediaRecorder.VideoSource |
| Modifier and Type | Field and Description |
|---|---|
static int |
MEDIA_RECORDER_ERROR_UNKNOWN |
static int |
MEDIA_RECORDER_INFO_MAX_DURATION_REACHED |
static int |
MEDIA_RECORDER_INFO_MAX_FILESIZE_REACHED |
static int |
MEDIA_RECORDER_INFO_UNKNOWN |
| Constructor and Description |
|---|
MediaRecorder() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
finalize() |
static int |
getAudioSourceMax() |
int |
getMaxAmplitude() |
void |
prepare() |
void |
release() |
void |
reset() |
void |
setAudioChannels(int numChannels) |
void |
setAudioEncoder(int audio_encoder) |
void |
setAudioEncodingBitRate(int bitRate) |
void |
setAudioSamplingRate(int samplingRate) |
void |
setAudioSource(int audio_source) |
void |
setCamera(Camera c) |
void |
setCaptureRate(double fps) |
void |
setLocation(float latitude,
float longitude) |
void |
setMaxDuration(int max_duration_ms) |
void |
setMaxFileSize(long max_filesize_bytes) |
void |
setOnErrorListener(MediaRecorder.OnErrorListener l) |
void |
setOnInfoListener(MediaRecorder.OnInfoListener listener) |
void |
setOrientationHint(int degrees) |
void |
setOutputFile(FileDescriptor fd) |
void |
setOutputFile(String path) |
void |
setOutputFormat(int output_format) |
void |
setPreviewDisplay(Surface sv) |
void |
setProfile(CamcorderProfile profile) |
void |
setVideoEncoder(int video_encoder) |
void |
setVideoEncodingBitRate(int bitRate) |
void |
setVideoFrameRate(int rate) |
void |
setVideoSize(int width,
int height) |
void |
setVideoSource(int video_source) |
void |
start() |
void |
stop() |
public static final int MEDIA_RECORDER_ERROR_UNKNOWN
public static final int MEDIA_RECORDER_INFO_UNKNOWN
public static final int MEDIA_RECORDER_INFO_MAX_DURATION_REACHED
public static final int MEDIA_RECORDER_INFO_MAX_FILESIZE_REACHED
public void setCamera(Camera c)
public void setPreviewDisplay(Surface sv)
public void setAudioSource(int audio_source)
throws IllegalStateException
IllegalStateExceptionpublic static final int getAudioSourceMax()
public void setVideoSource(int video_source)
throws IllegalStateException
IllegalStateExceptionpublic void setProfile(CamcorderProfile profile)
public void setCaptureRate(double fps)
public void setOrientationHint(int degrees)
public void setLocation(float latitude,
float longitude)
public void setOutputFormat(int output_format)
throws IllegalStateException
IllegalStateExceptionpublic void setVideoSize(int width,
int height)
throws IllegalStateException
IllegalStateExceptionpublic void setVideoFrameRate(int rate)
throws IllegalStateException
IllegalStateExceptionpublic void setMaxDuration(int max_duration_ms)
throws IllegalArgumentException
IllegalArgumentExceptionpublic void setMaxFileSize(long max_filesize_bytes)
throws IllegalArgumentException
IllegalArgumentExceptionpublic void setAudioEncoder(int audio_encoder)
throws IllegalStateException
IllegalStateExceptionpublic void setVideoEncoder(int video_encoder)
throws IllegalStateException
IllegalStateExceptionpublic void setAudioSamplingRate(int samplingRate)
public void setAudioChannels(int numChannels)
public void setAudioEncodingBitRate(int bitRate)
public void setVideoEncodingBitRate(int bitRate)
public void setOutputFile(FileDescriptor fd) throws IllegalStateException
IllegalStateExceptionpublic void setOutputFile(String path) throws IllegalStateException
IllegalStateExceptionpublic void prepare()
throws IllegalStateException,
IOException
IllegalStateExceptionIOExceptionpublic void start()
throws IllegalStateException
IllegalStateExceptionpublic void stop()
throws IllegalStateException
IllegalStateExceptionpublic void reset()
public int getMaxAmplitude()
throws IllegalStateException
IllegalStateExceptionpublic void setOnErrorListener(MediaRecorder.OnErrorListener l)
public void setOnInfoListener(MediaRecorder.OnInfoListener listener)
public void release()
Copyright © 2008-2013. All Rights Reserved.