Package org.robolectric.shadows
Class ShadowMediaRecorder
- java.lang.Object
-
- org.robolectric.shadows.ShadowMediaRecorder
-
@Implements(android.media.MediaRecorder.class) public class ShadowMediaRecorder extends Object
-
-
Field Summary
Fields Modifier and Type Field Description static int
STATE_DATA_SOURCE_CONFIGURED
static int
STATE_ERROR
static int
STATE_INITIAL
static int
STATE_INITIALIZED
static int
STATE_PREPARED
static int
STATE_RECORDING
static int
STATE_RELEASED
-
Constructor Summary
Constructors Constructor Description ShadowMediaRecorder()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
__constructor__()
protected static void
__staticInitializer__()
int
getAudioChannels()
int
getAudioEncoder()
int
getAudioEncodingBitRate()
int
getAudioSamplingRate()
int
getAudioSource()
Camera
getCamera()
MediaRecorder.OnErrorListener
getErrorListener()
MediaRecorder.OnInfoListener
getInfoListener()
int
getMaxDuration()
long
getMaxFileSize()
int
getOutputFormat()
String
getOutputPath()
Surface
getPreviewDisplay()
int
getState()
protected Surface
getSurface()
int
getVideoEncoder()
int
getVideoEncodingBitRate()
int
getVideoFrameRate()
int
getVideoHeight()
int
getVideoSource()
int
getVideoWidth()
protected void
prepare()
protected void
release()
protected void
reset()
protected void
setAudioChannels(int numChannels)
protected void
setAudioEncoder(int audio_encoder)
protected void
setAudioEncodingBitRate(int bitRate)
protected void
setAudioSamplingRate(int samplingRate)
protected void
setAudioSource(int audio_source)
protected void
setCamera(Camera c)
protected void
setMaxDuration(int max_duration_ms)
protected void
setMaxFileSize(long max_filesize_bytes)
protected void
setOnErrorListener(MediaRecorder.OnErrorListener l)
protected void
setOnInfoListener(MediaRecorder.OnInfoListener listener)
protected void
setOutputFile(String path)
protected void
setOutputFormat(int output_format)
protected void
setPreviewDisplay(Surface sv)
protected void
setVideoEncoder(int video_encoder)
protected void
setVideoEncodingBitRate(int bitRate)
protected void
setVideoFrameRate(int rate)
protected void
setVideoSize(int width, int height)
protected void
setVideoSource(int video_source)
protected void
start()
protected void
stop()
-
-
-
Field Detail
-
STATE_ERROR
public static final int STATE_ERROR
- See Also:
- Constant Field Values
-
STATE_INITIAL
public static final int STATE_INITIAL
- See Also:
- Constant Field Values
-
STATE_INITIALIZED
public static final int STATE_INITIALIZED
- See Also:
- Constant Field Values
-
STATE_DATA_SOURCE_CONFIGURED
public static final int STATE_DATA_SOURCE_CONFIGURED
- See Also:
- Constant Field Values
-
STATE_PREPARED
public static final int STATE_PREPARED
- See Also:
- Constant Field Values
-
STATE_RECORDING
public static final int STATE_RECORDING
- See Also:
- Constant Field Values
-
STATE_RELEASED
public static final int STATE_RELEASED
- See Also:
- Constant Field Values
-
-
Method Detail
-
__staticInitializer__
@Implementation protected static void __staticInitializer__()
-
__constructor__
@Implementation protected void __constructor__()
-
setAudioChannels
@Implementation protected void setAudioChannels(int numChannels)
-
setAudioEncoder
@Implementation protected void setAudioEncoder(int audio_encoder)
-
setAudioEncodingBitRate
@Implementation protected void setAudioEncodingBitRate(int bitRate)
-
setAudioSamplingRate
@Implementation protected void setAudioSamplingRate(int samplingRate)
-
setAudioSource
@Implementation protected void setAudioSource(int audio_source)
-
setCamera
@Implementation protected void setCamera(Camera c)
-
setMaxDuration
@Implementation protected void setMaxDuration(int max_duration_ms)
-
setMaxFileSize
@Implementation protected void setMaxFileSize(long max_filesize_bytes)
-
setOnErrorListener
@Implementation protected void setOnErrorListener(MediaRecorder.OnErrorListener l)
-
setOnInfoListener
@Implementation protected void setOnInfoListener(MediaRecorder.OnInfoListener listener)
-
setOutputFile
@Implementation protected void setOutputFile(String path)
-
setOutputFormat
@Implementation protected void setOutputFormat(int output_format)
-
setPreviewDisplay
@Implementation protected void setPreviewDisplay(Surface sv)
-
setVideoEncoder
@Implementation protected void setVideoEncoder(int video_encoder)
-
setVideoEncodingBitRate
@Implementation protected void setVideoEncodingBitRate(int bitRate)
-
setVideoFrameRate
@Implementation protected void setVideoFrameRate(int rate)
-
setVideoSize
@Implementation protected void setVideoSize(int width, int height)
-
setVideoSource
@Implementation protected void setVideoSource(int video_source)
-
prepare
@Implementation protected void prepare()
-
start
@Implementation protected void start()
-
stop
@Implementation protected void stop()
-
reset
@Implementation protected void reset()
-
release
@Implementation protected void release()
-
getSurface
@Implementation(minSdk=21) protected Surface getSurface()
-
getCamera
public Camera getCamera()
-
getAudioChannels
public int getAudioChannels()
-
getAudioEncoder
public int getAudioEncoder()
-
getAudioEncodingBitRate
public int getAudioEncodingBitRate()
-
getAudioSamplingRate
public int getAudioSamplingRate()
-
getAudioSource
public int getAudioSource()
-
getMaxDuration
public int getMaxDuration()
-
getMaxFileSize
public long getMaxFileSize()
-
getOutputPath
public String getOutputPath()
-
getOutputFormat
public int getOutputFormat()
-
getVideoEncoder
public int getVideoEncoder()
-
getVideoEncodingBitRate
public int getVideoEncodingBitRate()
-
getVideoFrameRate
public int getVideoFrameRate()
-
getVideoWidth
public int getVideoWidth()
-
getVideoHeight
public int getVideoHeight()
-
getVideoSource
public int getVideoSource()
-
getPreviewDisplay
public Surface getPreviewDisplay()
-
getErrorListener
public MediaRecorder.OnErrorListener getErrorListener()
-
getInfoListener
public MediaRecorder.OnInfoListener getInfoListener()
-
getState
public int getState()
-
-