summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorThe Android Open Source Project <initial-contribution@android.com>2009-03-03 14:04:24 -0800
committerThe Android Open Source Project <initial-contribution@android.com>2009-03-03 14:04:24 -0800
commitad04d9201452001dbaac4349f084cc9316190b89 (patch)
treee8a8fbc4b27adf44a21e884351eecf47fca7e0b6 /include
parent99ffda877980468a9ae31e013cd10fb3645df1b0 (diff)
downloadframeworks_av-ad04d9201452001dbaac4349f084cc9316190b89.zip
frameworks_av-ad04d9201452001dbaac4349f084cc9316190b89.tar.gz
frameworks_av-ad04d9201452001dbaac4349f084cc9316190b89.tar.bz2
auto import from //depot/cupcake/@132589
Diffstat (limited to 'include')
-rw-r--r--include/media/AudioRecord.h9
-rw-r--r--include/media/IMediaRecorder.h2
-rw-r--r--include/media/PVMediaRecorder.h2
-rw-r--r--include/media/mediarecorder.h39
4 files changed, 9 insertions, 43 deletions
diff --git a/include/media/AudioRecord.h b/include/media/AudioRecord.h
index ff64855..dd585c9 100644
--- a/include/media/AudioRecord.h
+++ b/include/media/AudioRecord.h
@@ -125,8 +125,7 @@ public:
* channelCount: Number of PCM channels (e.g 2 for stereo).
* frameCount: Total size of track PCM buffer in frames. This defines the
* latency of the track.
- * flags: A bitmask of acoustic values from enum record_flags. It enables
- * AGC, NS, and IIR.
+ * flags: Reserved for future use.
* cbf: Callback function. If not null, this function is called periodically
* to provide new PCM data.
* notificationFrames: The callback function is called each time notificationFrames PCM
@@ -134,12 +133,6 @@ public:
* user Context for use by the callback receiver.
*/
- enum record_flags {
- RECORD_AGC_ENABLE = AudioSystem::AGC_ENABLE,
- RECORD_NS_ENABLE = AudioSystem::NS_ENABLE,
- RECORD_IIR_ENABLE = AudioSystem::TX_IIR_ENABLE
- };
-
AudioRecord(int streamType,
uint32_t sampleRate = 0,
int format = 0,
diff --git a/include/media/IMediaRecorder.h b/include/media/IMediaRecorder.h
index eace996..0dff84e 100644
--- a/include/media/IMediaRecorder.h
+++ b/include/media/IMediaRecorder.h
@@ -24,7 +24,6 @@ namespace android {
class ISurface;
class ICamera;
-class IMediaPlayerClient;
class IMediaRecorder: public IInterface
{
@@ -42,7 +41,6 @@ public:
virtual status_t setOutputFile(int fd, int64_t offset, int64_t length) = 0;
virtual status_t setVideoSize(int width, int height) = 0;
virtual status_t setVideoFrameRate(int frames_per_second) = 0;
- virtual status_t setListener(const sp<IMediaPlayerClient>& listener) = 0;
virtual status_t prepare() = 0;
virtual status_t getMaxAmplitude(int* max) = 0;
virtual status_t start() = 0;
diff --git a/include/media/PVMediaRecorder.h b/include/media/PVMediaRecorder.h
index 3315c59..f795d04 100644
--- a/include/media/PVMediaRecorder.h
+++ b/include/media/PVMediaRecorder.h
@@ -19,7 +19,6 @@
#define ANDROID_PVMEDIARECORDER_H
#include <media/mediarecorder.h>
-#include <media/IMediaPlayerClient.h>
namespace android {
@@ -45,7 +44,6 @@ public:
status_t setPreviewSurface(const sp<ISurface>& surface);
status_t setOutputFile(const char *path);
status_t setOutputFile(int fd, int64_t offset, int64_t length);
- status_t setListener(const sp<IMediaPlayerClient>& listener);
status_t prepare();
status_t start();
status_t stop();
diff --git a/include/media/mediarecorder.h b/include/media/mediarecorder.h
index 8991f08..436e8f1 100644
--- a/include/media/mediarecorder.h
+++ b/include/media/mediarecorder.h
@@ -19,7 +19,6 @@
#define ANDROID_MEDIARECORDER_H
#include <utils.h>
-#include <media/IMediaPlayerClient.h>
namespace android {
@@ -88,24 +87,7 @@ enum media_recorder_states {
MEDIA_RECORDER_RECORDING = 1 << 4,
};
-// The "msg" code passed to the listener in notify.
-enum {
- MEDIA_RECORDER_EVENT_ERROR = 1
-};
-
-enum {
- MEDIA_RECORDER_ERROR_UNKNOWN = 1
-};
-
-// ----------------------------------------------------------------------------
-// ref-counted object for callbacks
-class MediaRecorderListener: virtual public RefBase
-{
-public:
- virtual void notify(int msg, int ext1, int ext2) = 0;
-};
-
-class MediaRecorder : public BnMediaPlayerClient
+class MediaRecorder
{
public:
MediaRecorder();
@@ -123,7 +105,6 @@ public:
status_t setOutputFile(int fd, int64_t offset, int64_t length);
status_t setVideoSize(int width, int height);
status_t setVideoFrameRate(int frames_per_second);
- status_t setListener(const sp<MediaRecorderListener>& listener);
status_t prepare();
status_t getMaxAmplitude(int* max);
status_t start();
@@ -132,22 +113,18 @@ public:
status_t init();
status_t close();
status_t release();
- void notify(int msg, int ext1, int ext2);
private:
void doCleanUp();
status_t doReset();
- sp<IMediaRecorder> mMediaRecorder;
- sp<MediaRecorderListener> mListener;
- media_recorder_states mCurrentState;
- bool mIsAudioSourceSet;
- bool mIsVideoSourceSet;
- bool mIsAudioEncoderSet;
- bool mIsVideoEncoderSet;
- bool mIsOutputFileSet;
- Mutex mLock;
- Mutex mNotifyLock;
+ sp<IMediaRecorder> mMediaRecorder;
+ media_recorder_states mCurrentState;
+ bool mIsAudioSourceSet;
+ bool mIsVideoSourceSet;
+ bool mIsAudioEncoderSet;
+ bool mIsVideoEncoderSet;
+ bool mIsOutputFileSet;
};
}; // namespace android