summaryrefslogtreecommitdiffstats
path: root/cmds/stagefright/record.cpp
diff options
context:
space:
mode:
authorAndreas Huber <andih@google.com>2010-03-19 11:43:15 -0700
committerAndreas Huber <andih@google.com>2010-04-09 13:47:58 -0700
commit03b268eac37ca2589bfff0bf58daf79d29cc14f4 (patch)
treedfb5d0de728a4faa531efc77e66093b48e4ac4f9 /cmds/stagefright/record.cpp
parentfe774a9c3ffe12979e182563b0e922ffc0ad20ef (diff)
downloadframeworks_av-03b268eac37ca2589bfff0bf58daf79d29cc14f4.zip
frameworks_av-03b268eac37ca2589bfff0bf58daf79d29cc14f4.tar.gz
frameworks_av-03b268eac37ca2589bfff0bf58daf79d29cc14f4.tar.bz2
Various fixes to enable recording on passion and nexus1.
Change-Id: I75a461c9882e2449082ad754ee7b231c1ceec039
Diffstat (limited to 'cmds/stagefright/record.cpp')
-rw-r--r--cmds/stagefright/record.cpp11
1 files changed, 8 insertions, 3 deletions
diff --git a/cmds/stagefright/record.cpp b/cmds/stagefright/record.cpp
index 845c854..5a87f4c 100644
--- a/cmds/stagefright/record.cpp
+++ b/cmds/stagefright/record.cpp
@@ -147,7 +147,7 @@ int main(int argc, char **argv) {
OMXClient client;
CHECK_EQ(client.connect(), OK);
-#if 1
+#if 0
sp<MediaSource> source = createSource(argv[1]);
if (source == NULL) {
@@ -165,14 +165,15 @@ int main(int argc, char **argv) {
success = success && meta->findInt32(kKeyHeight, &height);
CHECK(success);
#else
- int width = 800;
+ int width = 720;
int height = 480;
sp<MediaSource> decoder = new DummySource(width, height);
#endif
sp<MetaData> enc_meta = new MetaData;
// enc_meta->setCString(kKeyMIMEType, MEDIA_MIMETYPE_VIDEO_H263);
- enc_meta->setCString(kKeyMIMEType, MEDIA_MIMETYPE_VIDEO_MPEG4);
+ // enc_meta->setCString(kKeyMIMEType, MEDIA_MIMETYPE_VIDEO_MPEG4);
+ enc_meta->setCString(kKeyMIMEType, MEDIA_MIMETYPE_VIDEO_AVC);
enc_meta->setInt32(kKeyWidth, width);
enc_meta->setInt32(kKeyHeight, height);
@@ -213,6 +214,8 @@ int main(int argc, char **argv) {
#if 0
CameraSource *source = CameraSource::Create();
+ source->start();
+
printf("source = %p\n", source);
for (int i = 0; i < 100; ++i) {
@@ -227,6 +230,8 @@ int main(int argc, char **argv) {
buffer = NULL;
}
+ source->stop();
+
delete source;
source = NULL;
#endif