History log of /frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
22dc508717c7767927064ec7c152def99e54adcb 20-Apr-2017 Pawin Vongmasa <pawin@google.com> Make IGraphicBufferSource::setTimeLapseConfig take fps

Test: Manual use of Camera, Movies, Photos and YouTube apps.

Test: With CtsMediaTestCases.apk installed,
adb shell am instrument -e size small -w
'android.media.cts/android.support.test.runner.AndroidJUnitRunner'

Bug: 37302530
Change-Id: Id0d4f7fed57349a2f5484f6b6264981471e8f022
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
a821d858116ef87995f1c1cb404810852b684863 14-Apr-2017 Wonsik Kim <wonsik@google.com> Revise capture interval calculation in StagefrightRecorder

Bug: 37302530
Test: cts-tradefed run cts-dev --module CtsMediaTestCases --test android.media.cts.MediaRecorderTest
Change-Id: Idfb4aea475a40f928380835db9e6f304fe435377
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
73c3e6363b31fb27882c4666453ad8ef050b3cc1 28-Mar-2017 Wonsik Kim <wonsik@google.com> MediaRecorder: Handle 24-hour timelapse duration

Handle FPS in double / 64-bit integer and allow room for error.

Bug: 34870132
Test: cts-tradefed run cts-dev --module CtsMediaTestCases --test android.media.cts.MediaRecorderTest
Change-Id: I371d22d9ae70e2d77b08bd6c501e8b34a71592d1
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
afb43f76821e6a63e17e6484289a40430ada6978 09-Mar-2017 Ray Essick <essick@google.com> Name changes to Media Metrics Keys

The API council noticed that we used keys like "ht" and "wid" which
are more properly namespaced like "android.media.mediacodec.height".
This changes those keys on the generation side of the system; it goes
together with other changes that document the namespaced-names in the
consumption and documentation side of the system.

Bug: 35811992
Test: check 'dumpsys media.metrics', subset of CTS
Change-Id: Ie05a105229ab931a6b14c0157cc642b5d8413dde
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
ea42da480ddd116cb70f2c8a7642df7c12b996af 17-Feb-2017 Ray Essick <essick@google.com> Merge "Media metrics for android.media.MediaRecorder"
764d945bfdb9dec60f2b482fbf6c5e83824ed950 13-Dec-2016 Hangyu Kuang <hkuang@google.com> media: Support accurate pause/resume/stop in GraphicBufferSource.

Process all buffers that have been queued to the encoder on
StagefrightRecorder::pause()/stop(). Furthermore, add timestamp support for
pause/stop. Buffers willi keep getting encoded until 1) a buffer with a higher
timestamp is queued, or 2) the bufferqueue is abandoned by the producer.

Test: Recording with hacking GoogleCamera timestamp. And Mediarecorder CTS test.
Bug:32765698
Change-Id: I9ec33d635aef269836d7a5d9f4b906cb41b46a0d
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
ac4e4189db77dc0af7671b162d11be5ccec69339 13-Feb-2017 Ray Essick <essick@google.com> Media metrics for android.media.MediaRecorder

underlying collection of MediaRecorder metrics for getMetrics() API
and for media metrics cloud analysis.

Bug: 35150984
Test: hacked CTS, observation of 'dumpsys media.metrics'
Change-Id: Ife2ab06158b0015549ed17d52d7f4c35781f5e0f
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
fc079f79d8d4f6ef9f138aa615486c10dda99fb7 08-Feb-2017 Hangyu Kuang <hkuang@google.com> media: Protect access to writer after free in stagefright recorder.

Test: MediaRecorder Test.
Bug: 34123593
Change-Id: I030aaeae9b0ee570207c5b0bc73602ae1aa7c115
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
fe44e4f74fe2582cbf012687059278dbcbdaa6f7 04-Jan-2017 Hangyu Kuang <hkuang@google.com> media: Support recording exceeds filesize limit by splitting files.

Test: Hacking camera app to record file larger than size limit.
Bug:28150626
Change-Id: I500913ec96d8ef49a78989d3f973bc7e8d923cb7
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
addf2cbb120346ae42e78fa739245a353db5edad 29-Sep-2016 Chong Zhang <chz@google.com> IOMX: consolidate createInputSurface APIs

- Create GraphicBufferSource in IOMX regardless of persistency.

- Remove createInputSurface on IOMXNode, only keep setInputSurface
which accepts either a persistent or non-persistent surface.

- Instead of holding a IGraphicBufferConsumer, hold
IGraphicBufferSource across session as the persistent surface.

- Fix up GraphicBufferSource to allow usage across sessions.
GraphicBufferSource itself becomes agnostic to persistency.

- Remove max encoder input buffers profiling code.

bug: 31399200
Change-Id: I15ed52cc64509fd87736372a580abf7b51bf4de7
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
8f889be4754d40f39c9377b055988f58f3ed64a8 21-Sep-2016 Hangyu Kuang <hkuang@google.com> media: Fix mpeg2ts muxer.

1) Fix the CSD handling due to missing timestamp in CSD buffer.
2) Remove the concatenation of audio frames and write out every audio frame
immediately to unblock the video frame write out.
3) Unblock audio track thread after geting CSD.

Bug:21620607
Change-Id: I4926ef7202e1692a2c50a5e8158a9cfb19d9ed3f
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
f5a40c689555e845dd79184810355e5307f23e01 19-Aug-2016 Wonsik Kim <wonsik@google.com> mediarecorder: fix timestamp adjustment for early pause/resume am: a5aeb87eab
am: 5fe669bafa

Change-Id: I974f0099a03d7a783aeebbb514b7936f11caa463
a5aeb87eabfda3cb385eed405b843bdcb64252be 29-Jul-2016 Wonsik Kim <wonsik@google.com> mediarecorder: fix timestamp adjustment for early pause/resume

Bug: 30549032
Change-Id: Iafb916454499e9fac3af3b8a6abe06c652f84564
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
7d64d30d0dcdb97be921790e2702e5adfe751d92 12-Aug-2016 Chih-Hung Hsieh <chh@google.com> resolve merge conflicts of 6ae8c7b to stage-aosp-master am: 32d6e5f0eb
am: a944197b97

Change-Id: I03472be260cbfdaf436514d319e91063c738b82c
32d6e5f0ebe9e00f80401e5f4fd6e285a474590d 12-Aug-2016 Chih-Hung Hsieh <chh@google.com> resolve merge conflicts of 6ae8c7b to stage-aosp-master

Change-Id: Iabb5d9b93b98e428c53f0504fbfe832ed24d988d
0d1ed381fde5dac12dd84fcf3da66dac46699378 09-Aug-2016 Chih-Hung Hsieh <chh@google.com> Fix clang-tidy warnings in stagefright.

* Add explicit keyword to conversion constructors.
* Or add NOLINT to implicit conversion constructors.
Bug: 28341362
* Use const reference type for read-only parameters.
Bug: 30407689
* Use const reference type to avoid unnecessary copy.
Bug: 30413862
Test: build with WITH_TIDY=1

Change-Id: I7a15ac1e37973fe2c661f577a6106b913653de40
Merged-In: I7a15ac1e37973fe2c661f577a6106b913653de40
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
e19f2956de379b9c9a852d50d83d0608ca42bfe9 15-Jul-2016 Lajos Molnar <lajos@google.com> stagefright: prefer B frames for high frame-rate recording

Some codecs do not support B-frames with temporal layering.
- Prefer temporal layering for slow-motion and time lapse videos
(since B-frames are not as useful for time lapse, and layering is
needed for slow-motion)
- Prefer B-frames for HFR capture

Bug: 27596987
Change-Id: I12f530e9f624e2948e176b5548e0d9d65eed95d8
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
2da225766572a3d4746b4e21cb231a0243b114ab 14-Jul-2016 Lajos Molnar <lajos@google.com> stagefright: update temporal layering selection in MediaRecorder

- Use max expected decode framerate to decide on number of layers
- Optimize for decoding on 30fps display (battery saver mode)

Bug: 27596987
Change-Id: I8902b4a78670cb0aebb8bccd640367e262f172b2
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
c96cfbe66d7bf261c57ff93984bc6a4b3a58f6fc 13-Jul-2016 Lajos Molnar <lajos@google.com> stagefright: enable temporal layering for timelapse and hfr recording

Bug: 27596987
Change-Id: I310abc22425290117629d5e592f473396a5733d1
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
5a4a0a1e4a44b8e48aff8e74df56d37dc6d7129c 24-Jun-2016 Hangyu Kuang <hkuang@google.com> media: set correct mode if both capture and playback rate are set.

This will avoid the recording operate in slow motion/time-lapse mode even
if capture rate and playback rate diff a little bit.

Bug:28313712
Change-Id: I7b50c6eacbde4189a4d0d76f95861dd029991685
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
b2379ba0a32638bae2ea0460644f68cf5a0967ce 24-May-2016 Eric Laurent <elaurent@google.com> Fix android.permission.CAPTURE_AUDIO_OUTPUT permission check

Make sure we use the correct PID and UID when checking
android.permission.CAPTURE_AUDIO_OUTPUT permission from audio
policy service.

Bug: 28772898
Change-Id: I8f0c45bf7a5728b4364a451eefb6c025892ae9a5
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
3e328782f1e1061d08ea0c45b855cc418a2d9ea6 09-May-2016 Lajos Molnar <lajos@google.com> stagefright: untangle metadata-mode handling

- specify requested metadata mode from producers to OMX
- (pass requested metadata in IOMX::storeMetadataInBuffers)
- use correct logic for native handle source
- use native handle source for encoded meta buffers

Bug: 22775369
Change-Id: I58b03acd3e9a5367d5010d7f87b7af5cae23362c
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
e6cab24fa5857eaf48c957988f153b47a52d1b45 14-Apr-2016 Wonsik Kim <wonsik@google.com> media: clear pause state at stop()

Bug: 28151768
Change-Id: I37e0b4562398008d6a1176bf3570cb6170997390
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
833b47505c513cb5c8f22aa922a7ea20d153b319 05-Apr-2016 Andy Hung <hunga@google.com> MediaPlayerService: Remove 64 bit compilation warnings

Bug: 16890215
Change-Id: I83d27d8c0c51bd868737bc2a1d6e046702d2a91c
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
9f5c692300e02f9f1b4e08b238a76f1428c854d3 17-Mar-2016 Wonsik Kim <wonsik@google.com> media: adjust time offset in case of time lapse

Bug: 27636840
Change-Id: I7be87042b450e0e7e4d9e74072a2acdf4af1a4dd
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
b77d03b62cb743d0faf74b54aa466b4d220b5e61 03-Mar-2016 Lajos Molnar <lajos@google.com> stagefright: connect color aspects and surface dataspace

1. Keep configuration format as video decoder and encoder will need
it to reset their default color aspects on mode/size change.

2. Separate color aspect handling for decoder and encoder as they
are quite different. Update decoder and encoder color aspect setting
to latest policy.

3. propagate dataspace to GraphicBufferSource, MediaCodecSource,
CameraSource and SoftwareRenderer

Bug: 25684127
Change-Id: Ie9a7528af36ed44605a7ce3e69b5794ef16b1c66
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
d56db1d2bee182d1851097a9c712712fc094d117 18-Dec-2015 Eino-Ville Talvala <etalvala@google.com> Camera: Switch camera2 to auto-gen C++ binder interfaces

- Move camera service AIDL files to frameworks/av
- Build C++ interface stubs with AIDL tools
- Add necessary native-side parcelables and update existing ones
- Remove manually-written stubs, rearrange remaining manual stubs
- Adjust implementations to work with auto-generated stubs
- Adjust method signatures for auto-gen differences
- Add rich error messages using binder::Status

Bug: 25091611
Change-Id: I6f69f34b9d1a3f8d1fb7db87357363f8fa8483ff
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
9d73ec661e34f91f8d80a11cc5208a23997b75a0 04-Feb-2016 Lajos Molnar <lajos@google.com> stagefright: move MetadataRetriever off of OMXCodec

Also remove some unneeded OMXCodec includes.

Bug: 17108024
Change-Id: I1e4b32d83216e9c6b1d76a18fb346dc632be4b1d
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
6b0795009b8f53ab771e0074b76381977d016f4b 04-Feb-2016 Lajos Molnar <lajos@google.com> stagefright: move MetadataRetriever off of OMXCodec

Also remove some unneeded OMXCodec includes.

Bug: 17108024
Change-Id: I1e4b32d83216e9c6b1d76a18fb346dc632be4b1d
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
feb76cc0340f3eb4c9ae91cbfab4dcea449422f5 28-Jan-2016 Chien-Yu Chen <cychen@google.com> Merge changes from topic 'camera-hardening'

* changes:
camera: Add support to pass native handles across binders
Camera: Fix client permission check
Add cameraserver process
8a3ff465d394b969166f4df8c1bad9d2f1103747 28-Jan-2016 Wonsik Kim <wonsik@google.com> Merge "media: reset total paused duration for MediaRecorder at stop"
148c3d67710ca9353f14e5c37a0a38c88d4f0e53 27-Jan-2016 Wonsik Kim <wonsik@google.com> media: reset total paused duration for MediaRecorder at stop

Bug: 20092236
Change-Id: I05a11a2f9b8a0fbc54900aa6ba00bf49e8a0bafd
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
98a668f6ea51e4d894d2ebb61a0e18287fb14008 18-Dec-2015 Chien-Yu Chen <cychen@google.com> Camera: Fix client permission check

Modify StageFright's CameraSource to forward calling PID as
client PID when connecting to CameraService so CameraService
can check if the client PID has permission to use camera.

Change CameraService to check calling UID is trusted before
using the passed in client PID and client UID to verify permission.

Bug: 24511454
Change-Id: I4906ab73510e2c75714690bed675e3c13aca3ccf
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
9aa87d4ef502c9700a31fe46dc6e1d6f99cf4e5e 07-Dec-2015 Wonsik Kim <wonsik@google.com> stagefright: add HEVC support to MediaRecorder

Bug: 22879917
Change-Id: I6c97b051467de44c506a8ff021321e5953a63fc3
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
d008275796ac4cccf85fefce53cef733a49bc1fa 31-Aug-2015 Wonsik Kim <wonsik@google.com> Implement pause/resume functionality to MediaRecorder

Bug: 20092236
Change-Id: Ia0e92ff246302fd5fdef53c4f961d6645cc26a86
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
b5213840103ae1ce3425a6db3d851fce5f767889 23-Sep-2015 Dan Austin <danielaustin@google.com> am 7cac3edc: Merge "libstagefright : fix the bug of wrong value setting for slice-height"

* commit '7cac3edc679c9d3f88268c2f5a83cba1333e20e5':
libstagefright : fix the bug of wrong value setting for slice-height
e62ba9cce4631737e38db1b0d8a7a64ee81cc397 23-Sep-2015 xrwu <xellos.1983@gmail.com> libstagefright : fix the bug of wrong value setting for slice-height

Change-Id: I2ad0fa6039fb3b31e7dbfdcf15be4703664da04d
Signed-off-by: xrwu <xellos.1983@gmail.com>
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
46d26dd29195450db15704e84d65740628a821fb 16-Jul-2015 Chong Zhang <chz@google.com> MediaRecorder: enable audio for slow motion recording

bug:22460747

Change-Id: I23f773ecf7b86928a8eacd25a481636e645affbe
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
d46a6b9fd8b2a4f9098757384711e2cd03a91651 15-May-2015 Eino-Ville Talvala <etalvala@google.com> Camera1 API: Support SW encoders for new camera HALs

- Support new set video format/dataspace command in camera service
- HALv3: Select gralloc usage flags based on format
- HALv1: Pass format command directly to HAL layer
- Use format/dataspace command in CameraSource
- Switch all API1 recording to use metadata mode
- Switch all >= HALv2 API1 recording to use kMetadataBufferTypeANWBuffer

Bug: 13222807
Change-Id: I2e609b92c65792611bb1dab09e0c41c363ebbc42
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
8f469e18c307cb9dc0d16ed9225972aa8be4516f 13-May-2015 Chong Zhang <chz@google.com> stagefright: rename usePersistentInputSurface to setInputSurface

and clear persistent surface pointer when MediaRecorder is reset

bug: 21045118
bug: 21045402
Change-Id: Ifd0d6deeb969f2252123929541b30b518cecbf9a
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
e2a2dfcbf0c9d6bb7139263ecf0d8e53b4ca1049 01-May-2015 Chong Zhang <chz@google.com> MediaRecorder: implement persistent input surface APIs

Bug: 19127604
Bug: 19489395

Change-Id: I7dd8015a8fe029f9867fcdb52322629c77eff50b
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
be71aa29a3c86d2e01cd17839d2a72ab09a1bce5 28-Apr-2015 Svet Ganov <svetoslavganov@google.com> Respect the record audio app op - media

Change-Id: I3a97977b6e9a09355e2008f780d22d480fb7308b
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
38ad9c7d19a0699065b078a0e8dd7ece3d055bf7 23-Apr-2015 Ronghua Wu <ronghuawu@google.com> Merge "libmediaplayerservice: set priority and operating rate for the codec used by recorder."
fdbc1b3a885f1e8a59b1788e48e24ea4c66acbc8 22-Apr-2015 Ronghua Wu <ronghuawu@google.com> libmediaplayerservice: set priority and operating rate for the codec used by recorder.

Bug: 20481562
Change-Id: Ibff54395e00809500d98e3759f9677f8168c98ae
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
6d339f1f764bbd32e3381dae7bfa7c6c575bb493 18-Apr-2015 Lajos Molnar <lajos@google.com> libmediaplayerservice: fix warnings, make warnings errors, use clang

Change-Id: I1b2f6b65c5abbc366068a60b8909104f31b94228
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
9ee53a49860e91c2b012883eef09d669a7829e06 21-Feb-2015 Chong Zhang <chz@google.com> MediaRecorder: pass capture fps in float

bug: 19460202

Change-Id: Ic8f2dc02dfd482c4b2065b16e28721fc6e3cf696
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
e76dba7af9589d9ed7b116eec3a74168a8352925 19-Feb-2015 Chong Zhang <chz@google.com> MPEG4Writer: add capture fps in meta data

bug: 19460202

Change-Id: I3a6ea3a5149d124ca9a2487a300dcc2db4405d0f
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
c9f122d8f32ba6928ac9087448025fa3bed1553d 03-Feb-2015 Zhijun He <zhijunhe@google.com> StageFrightRecorder: update setVideoFrameRate sanity check

Allow high speed recording fps to be up to 1000fps

Change-Id: I975d11b8a9abbd50ce6982fb46f4a4a3a035e475
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
e62e2637458931d20623b76d0080a56c2f316334 10-Dec-2014 Marco Nelissen <marcone@google.com> am a2bc118c: am 2a0f484e: am a04c05ab: Merge "Truncate file before recording into it."

* commit 'a2bc118cfe860f9c108ba089b021d3b003185c56':
Truncate file before recording into it.
a2bc118cfe860f9c108ba089b021d3b003185c56 10-Dec-2014 Marco Nelissen <marcone@google.com> am 2a0f484e: am a04c05ab: Merge "Truncate file before recording into it."

* commit '2a0f484e7d95490274e77cd4adc01592cfdf6e3a':
Truncate file before recording into it.
69113e8ccc30fbdb8733ca2070bd3491b21e656d 10-Dec-2014 Marco Nelissen <marcone@google.com> Truncate file before recording into it.

Recording into an existing file of non-zero length could leave old
data in the file after the recording ends. Best case that wastes
space, worst case it results in a file that's considered corrupt
on playback.

Change-Id: I2c77a107603b2b36790958360ff0856c2b28d677
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
c6ac859f5a82ea8642bc6351a45508a15f224f32 08-Dec-2014 Marco Nelissen <marcone@google.com> Remove filename based writer constructors

MediaPlayerService can't open files (it needs an already opened
file descriptor), so these were just wasting space.

Change-Id: I323044a6c1814a7bff952ed71b5c7792df2abf03
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
0f8f4e681b867dd611d2d916453337cb0770d4da 22-Oct-2014 Hochi Huang <hochi.huang@mediatek.com> [FM] Fix FM App record fail Buganizer ID: 17975676

Review: https://partner-android-review.git.corp.google.com/#/c/185234

Signed-off-by: Hochi Huang <hochi.huang@mediatek.com>

Change-Id: I872ce744d23049e251a46aebc4019be5b25e3612
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
bc78bd02f0b823b18e3a4f8b8f862780b51994c0 06-Oct-2014 Praveen Chavan <pchavan@codeaurora.org> StageFrightRecorder: Enable meta-data mode for VP8 hardware encoder.

Meta-data mode for input is preferred (rather required) for recording
with camera v1. This capability is queried and enabled per codec; enable
it for VP8 hardware encoder.

Bug: 17664960

Change-Id: I4735c61670ebe0a555002cc25ef3ed823ab02f1f
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
a147b4f91143d9f2fb608e22f9fca14bbd029573 02-Oct-2014 Lajos Molnar <lajos@google.com> mediarecorder: set level if setting default profile

Bug: 17676461
Change-Id: If01ccd09935945d330de0842be95c3544951b6b9
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
54ef1bae010f12dfe6a40ff4452695b1b11ff449 09-Sep-2014 Chong Zhang <chz@google.com> StagefrightRecorder: default to codec and fps from camcorder low profile

Bug: 16870964
Change-Id: I18425af630d3f041a3bcf77fbae3f07856fe8af2
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
76dc9c5052741bf0910a23a20c9df6018c4979d8 20-Aug-2014 Robert Shih <robertshih@google.com> StagefrightRecorder: add VIDEO_ENCODER_VP8 case in setupVideoEncoder

Bug: 16329805
Change-Id: Ibc80cdeb1958f739dd67b65e57f6b7cc551a9db3
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
68e97e7388bc9efa03e56c999645002cc3f38df5 24-Jul-2014 Robert Shih <robertshih@google.com> StagefrightRecorder: check for WEBM format instead of MP4

Bug: 16544665
Change-Id: Idc45bd4cafc65a11132d10fdf21f8439e186f35f
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
114819633470ebd5b346c13c2a82a0025d2d39c0 10-Jul-2014 Robert Shih <robertshih@google.com> StagefrightRecorder: webm (video only) support

Bug: 16329805
Change-Id: I8a0ecd100fca397add97a1416125bcc6aeb86364
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
ef0cf50343f8a6d74894f96f5ecb5eec4c5f1bc6 11-Jun-2014 Chong Zhang <chz@google.com> Log an error when audio/video encoder failed to create

Change-Id: I493981cddeb9452c533e2917d8c440897d5e6b49
related-to-bug: 15106730
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
1a5690652f3f6ee40f15c2f9f6c4b6badf4dbcf5 26-Feb-2014 Chong Zhang <chz@google.com> initialize encoder at start() time for camera source

Bug: 13156212
Change-Id: I845ef51f662f04c50179dbfb128204922a424e1d
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
dc6ac201032d0f6ad0c8149ae2f009ec38693025 22-Feb-2014 Chong Zhang <chz@google.com> Merge "support for time lapse/slow motion when using SURFACE source"
2c9c8cba8562cc3a27532e4cd348912cc78d8d98 11-Feb-2014 Chong Zhang <chz@google.com> support for time lapse/slow motion when using SURFACE source

Bug: 13032650
Change-Id: Iecbadf9f29c8c49353416fc467fb3acdde279595
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
ccb067b1d8424ba610cbd3de83368bd55b532b5b 11-Feb-2014 Andreas Huber <andih@google.com> fix the build by fixing more warnings.

Change-Id: Ied0ec39eb83b101582702d1e30c21643ccf6353e
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
1d6fa7af1288b550faabe4ec2cf98684236723db 11-Feb-2014 Narayan Kamath <narayan@google.com> resolved conflicts for merge of 566be7c3 to master

Change-Id: I7b1cc71057b2bd4f771e7bcf508a8c3abd6017ce
377b2ec9a2885f9b6405b07ba900a9e3f4349c38 03-Feb-2014 Kévin PETIT <kevin.petit@arm.com> Make frameworks/av 64-bit compatible

Contains the necessary changes to make frameworks/av build and work
on a 64-bit machine.

Signed-off-by: Craig Barber <craig.barber@arm.com>
Signed-off-by: Kévin PETIT <kevin.petit@arm.com>
Signed-off-by: Ashok Bhat <ashok.bhat@arm.com>
Signed-off-by: Marcus Oakland <marcus.oakland@arm.com>

Change-Id: I725feaae50ed8eee25ca2c947cf15aee1f395c43
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
72cecca17d735db6532c45f0a7e10c47ee6f065a 26-Dec-2013 Chong Zhang <chz@google.com> Change StagefrightRecorder to use MediaCodec

Bug: 12305192
Change-Id: I72d7cb571be5bd348b58ad650f3269d24c15d350
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
b5099903c059dc913e0e592969c10d15fac0c14c 15-Nov-2013 Robert Shih <robertshih@google.com> Merge "Fixed StagefrightRecorder::setupVideoEncoder to use the clipped bitrate value mVideoBitRate; removed unused arguments after refactoring."
4db37cedd4db8230f3ec6191d8d7ba2b0036886e 12-Nov-2013 Robert Shih <robertshih@google.com> Fixed StagefrightRecorder::setupVideoEncoder to use the clipped bitrate value
mVideoBitRate; removed unused arguments after refactoring.

Bug: 11074303
Change-Id: Ieb5dd7dc67e5bc16b6e580ba11b157e4365f3cd6
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
9c7f845780d62ea09469a8dac7117cc01adfea5c 30-Oct-2013 Lajos Molnar <lajos@google.com> StageFrightRecorder: do not use meta-data mode for software encoders

Camera HAL v1 uses vendor-specific camera-source meta-data mode, but
software encoders use generic gralloc-source mode, so they are not
compatible.

Change-Id: I0d1bab8eada26dcb70c97b1eec83f06d1f331239
Signed-off-by: Lajos Molnar <lajos@google.com>
Bug: 11446505
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
59ca8040a0cfb0324c6be7dded74d02e9f5cf6e8 27-Mar-2013 Marco Nelissen <marcone@google.com> Fix valgrind error.

The constructor calls reset(), which in turn calls stop(), which then
accesses mCaptureTimeLapse before it has been initialized.

Change-Id: Ia94ac740b9bd1a0389c72647a5639dd25320d92c
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
99617adda9bc46c43f511f0940bc735c73de61de 13-Mar-2013 Mathias Agopian <mathias@google.com> remove uses of Surface in favor or IGraphicBufferProducer

Change-Id: I13d7a9553aa335bca790a3a59d389d7533c83d57
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
ceb388d6c03c38b96dc41c0ea4804b749aa077c4 19-Feb-2013 Eino-Ville Talvala <etalvala@google.com> CameraService and Stagefright: Support AppOps

Camera:
- Signal to AppOpsService when camera usage starts and stops
- Listen to permissions revocations and act on them
- Currently just kill camera connection when permissions lost

Stagefright:
- Pass on client name, UID to camera as needed

Bug: 8181262
Change-Id: I9e33c9d05e9daa77dbb2d795045d08eb887ec8f0
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
8ba01021b573889802e67e029225a96f0dfa471a 18-Dec-2012 Andy McFadden <fadden@android.com> Rename ISurfaceTexture and SurfaceTexture

The C++ class names don't match what the classes do, so rename
ISurfaceTexture to IGraphicBufferProducer, and SurfaceTexture to
GLConsumer.

Bug 7736700

Change-Id: I64520a55f8c09fe6215382ea361c539a9940cba5
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
b4a55269a5b39c73de2cc1d4013d0631ef18c77d 12-Oct-2012 James Dong <jdong@google.com> Fix some missing checks against missing codecs

o related-to-bug: 6971073

Change-Id: Ia6d926663231f9a9ef31c82c85c70595c4a30ebe
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
bf5bea96f236adb5eef78c2f414ef82b3602a0f7 19-Jul-2012 Eino-Ville Talvala <etalvala@google.com> Codecs: Add MetaDataMode support to software video encoders.

This support is needed to enable efficient video recording with
emulator and camera HAL 2.

- Update SoftAVCEncoder and SoftMPEG4Encoder to support MetaDataMode
extension.
- Allow CameraSource to handle opaque pixel formats, so that
MetaDataMode can be used.
- Remove hardware codec restriction for MetaDataMode

Bug: 6243944
Change-Id: I970eb3d55542a413b6d75a78f76d3a8583155601
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
f60c660f048d5f5e2458cff243c20400d73757a7 29-Apr-2012 Dave Burke <daveburke@google.com> Added support for HE-AAC recording

Fixed bug in decoder related to sample rates / channel counts
Made decoder follow Fraunhofer pattern
Log if bitrate not available
Bug: 6275957

Change-Id: I47a8e29358fa4a88ebc73fe02d46a2bfb96c64fe
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
aeb8fd460ed87d032b3fb8bb61e21eb542ce0f5b 19-Apr-2012 Dave Burke <daveburke@google.com> Add Fraunhofer AAC encoder with AAC-ELD support.

Change-Id: I6cd499d257d72f50a5b508bed97796a591a51506
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
bdddc659a941afdb7f4958f582c6901c07246097 31-Mar-2012 Daniel Lam <dalam@google.com> Refactored SurfaceMediaSource

SurfaceMediaSource takes advantage of BufferQueue to avoid
duplicated code.

Change-Id: I5e60b8eca21e6c3cf728d363cd8f3786125182d1
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
df712ea86e6350f7005a02ab0e1c60c28a343ed0 26-Feb-2012 Mathias Agopian <mathias@google.com> fix libgui header location

Change-Id: Iec71706cdd4f29c6904993648ce873e83ef9cafe
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
2e77ad2a9f7afb57b6f9127dd7c229e774baa9c8 22-Feb-2012 James Dong <jdong@google.com> Allow to record time lapse videos without using setProfile()

o also added a check on whether capture rate was set before starting time lapse video recording.

o related-to-bug: 6045507

Change-Id: I8e1fdc8e8931e2684ab3822dc6260db44658e87d
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
f1d5aa162c02a16b7195a43a9bcea4d592600ac4 07-Feb-2012 James Dong <jdong@google.com> Move away from MediaDebug and use ADebug instead

Change-Id: I963a3b6f79a7292891973cbeeaf3378b38629f08
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
29357bc2c0dd7c43ad3bd0c8e3efa4e6fd9bfd47 06-Jan-2012 Steve Block <steveblock@google.com> Rename (IF_)LOGE(_IF) to (IF_)ALOGE(_IF) DO NOT MERGE

See https://android-git.corp.google.com/g/#/c/157220

Bug: 5449033
Change-Id: Ic9c19d30693bd56755f55906127cd6bd7126096c
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
5ff1dd576bb93c45b44088a51544a18fc43ebf58 06-Jan-2012 Steve Block <steveblock@google.com> Rename (IF_)LOGW(_IF) to (IF_)ALOGW(_IF) DO NOT MERGE

See https://android-git.corp.google.com/g/157065

Bug: 5449033
Change-Id: I00a4b904f9449e6f93b7fd35eac28640d7929e69
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
df64d15042bbd5e0e4933ac49bf3c177dd94752c 04-Jan-2012 Steve Block <steveblock@google.com> Rename (IF_)LOGI(_IF) to (IF_)ALOGI(_IF) DO NOT MERGE

See https://android-git.corp.google.com/g/156801

Bug: 5449033
Change-Id: Ib08fe86d23db91ee153e9f91a99a35c42b9208ea
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
3856b090cd04ba5dd4a59a12430ed724d5995909 20-Oct-2011 Steve Block <steveblock@google.com> Rename (IF_)LOGV(_IF) to (IF_)ALOGV(_IF) DO NOT MERGE

See https://android-git.corp.google.com/g/#/c/143865

Bug: 5449033
Change-Id: I0122812ed6ff6f5b59fe4a43ab8bff0577adde0a
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
b832a03d563dd000faa44f2577e92237525edc32 06-Oct-2011 James Dong <jdong@google.com> Fix an issue where we should allow negative values but did not

Change-Id: Ia8d718b4e6aec4c17db86e30134132f767fd72c5
related-to-bug: 5419527
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
3cecf640c4daf2df616b278bd9986018c8182908 30-Jun-2011 James Dong <jdong@google.com> Do not support still image capture mode for timelapse video recording

related-to-bug: 4973779

Change-Id: Ica665217ab10247b2242acc4e93d4fe9f83e3f45
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
b33f3407bab0970a7f9241680723a1140b177c50 02-Jul-2011 Pannag Sanketi <psanketi@google.com> Connect MediaRecorder Native to SurfaceMediaSource

Making a connection from MediaRecorder Native layer to the
SurfaceMediaSource for the purpose of encoding GL Frames. This will be
called from the java side inside the Mobile Filter Framework.

The mediarecorder native layer (client), when set the videosource to
option VIDEO_SOURCE_FRAMES, asks the StageFrightRecorder on the mediaserver
side to create a SurfaceMediaSource object and pass it back as a
sp<ISurfaceTexture> object. Using that, the client side will dequeue and
queue buffers. Connecting the GL Frames to the obtained
sp<ISurfaceTexture> is not part of this CL.

Related to bug id: 4529323

Change-Id: I651bec718dd5b935779e7d7a050b841c2d0b0fcd
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
d552b88515c6ccd18695e5db5e6032a6425d8c63 08-Jul-2011 James Dong <jdong@google.com> Use advertised h264 encoding parameters by default if the profile is not baseline

o Force to use AVC baseline profile for camcorder low quality videos

Change-Id: I3424c57dd0c55fc4991f5767b57695c8f3420ecb
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
4ca2c7c913f8bd4ada13aca56d36045d42d1e00f 01-Jun-2011 Wu-cheng Li <wuchengli@google.com> Add framework support for camcorder zoom.

The purpose of ICameraRecordingProxy and ICameraRecordingProxyListener is to
allow applications using the camera during recording.

Camera service allows only one client at a time. Since camcorder application
needs to own the camera to do things like zoom, the media recorder cannot
access the camera directly during recording. So ICameraRecordingProxy is a proxy
of ICamera, which allows the media recorder to start/stop the recording and
release recording frames. ICameraRecordingProxyListener is an interface that
allows the recorder to receive video frames during recording.

ICameraRecordingProxy
startRecording()
stopRecording()
releaseRecordingFrame()

ICameraRecordingProxyListener
dataCallbackTimestamp()

The camcorder app opens the camera and starts the preview. The app passes
ICamera and ICameraRecordingProxy to the media recorder by
MediaRecorder::setCamera(). The recorder uses ICamera to setup the camera in
MediaRecorder::start(). After setup, the recorder disconnects from camera
service. The recorder calls ICameraRecordingProxy::startRecording() and
passes a ICameraRecordingProxyListener to the app. The app connects back to
camera service and starts the recording. The app owns the camera and can do
things like zoom. The media recorder receives the video frames from the
listener and releases them by ICameraRecordingProxy::releaseRecordingFrame.
The recorder calls ICameraRecordingProxy::stopRecording() to stop the
recording.

The call sequences are as follows:
1. The app: Camera.unlock().
2. The app: MediaRecorder.setCamera().
3. Start recording
(1) The app: MediaRecorder.start().
(2) The recorder: ICamera.unlock() and ICamera.disconnect().
(3) The recorder: ICameraRecordingProxy.startRecording().
(4) The app: ICamera.reconnect().
(5) The app: ICamera.startRecording().
4. During recording
(1) The recorder: receive frames from ICameraRecordingProxyListener.dataCallbackTimestamp()
(2) The recorder: release frames by ICameraRecordingProxy.releaseRecordingFrame().
5. Stop recording
(1) The app: MediaRecorder.stop()
(2) The recorder: ICameraRecordingProxy.stopRecording().
(3) The app: ICamera.stopRecording().

bug:2644213

Change-Id: I15269397defc25cbbcae16abc071c8349c123122
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
86b7f47aa7482424cf8fd248f1315311919be3b0 10-May-2011 James Dong <jdong@google.com> Support platform and camera dependent recording start time offset

related-to-bug: 4390777

Change-Id: Icb52973ad4ac716f04fb103ef527915a966d06d5
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
07b1bb529a1ae76c46a71b01338c166f9490629d 12-May-2011 James Dong <jdong@google.com> Support for storing geo information in the recorded mp4/3gpp file.

o Geo data (latitude and longitude) is stored in udta box

Change-Id: I76e4aeb741c4b339f3753d3d28190151f3ea4919
related-to-bug: 4260295
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
64760240f931714858a59c1579f07264d7182ba2 11-May-2011 Dima Zavin <dima@android.com> update for new audio.h header location

Change-Id: Ic4c62c4037800802427eb7d3c7f5eb8b25d18876
Signed-off-by: Dima Zavin <dima@android.com>
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
760943b5e7a09b602aba04ec451e97662f48b0a4 21-Mar-2011 James Dong <jdong@google.com> Initial check-in for AACWriter

Change-Id: Ia21ca39a404484b2dda25c6101780d2ff11c4623

related-to-bug: 4211046
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
fce7a473248381cc83a01855f92581077d3c9ee2 20-Apr-2011 Dima Zavin <dima@android.com> audio/media: convert to using the audio HAL and new audio defs

Change-Id: Ibc637918637329e4f2b62f4ac7781102fbc269f5
Signed-off-by: Dima Zavin <dima@android.com>
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
75b0b5473c7b43f8c5972db7e6e8930988ead751 23-Feb-2011 Gloria Wang <gwang@google.com> To collect the total usage time of encoders in the media recorder

Change-Id: I94c9c94dec6bd714a3ebf96b4465b94f069e55b8
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
27944ef5cd8d0fb476c8c8958986e827c5f8ab83 09-Feb-2011 James Dong <jdong@google.com> Should reset errno to 0 before calling strtoll().

bug - 3431238

Change-Id: I855847209d2e022242b8eb62985759922ab94779
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
7757f5010a771fb8824b6fdf9788f588a1577e3f 26-Jan-2011 James Dong <jdong@google.com> Make sure that key frame is generated for timelapse video recording if there are at least two input video frames from camera source.

This will fix the stop failure issue where we have to wait n * time_interval before a key frame can be received by the file writer, where
o n is the actual number of buffers advertised by the video encoder
o time_interval is the interval settings for timelapse video recording
specifying the time distance between neighboring input video frames

The fix includes two parts:
o OMXCodec will not submit all n buffers at one time, but instead submit one input
frame at one time if it become available.

o Timelapse camera source made available the first two input frames and do not skip
them so that the first compressed output frame data can be received regardless
the specified time_interval

bug - 3367659

Change-Id: Ia68cc2cb0d71aa7dc54540e9ad82fae911ad530b
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
7bd460110b27a979384dda351788eac95d8467f5 20-Jan-2011 James Dong <jdong@google.com> Eliminate recording sound by starting the video track before audio track.

Due to the variable delays in the system, the recording sound can still be heard
if the audio track is started early. This happens even after we suppress a relative
long period of initial audio for a recording session. By starting the video track
before the audio track, we effectively play the recording sound earlier.

bug - 3371141

Change-Id: I2cccf77eae953d96827fc080c618b1d962445c26
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
2b4883641e324c50a2ee24c5bd15170c7d31e57d 19-Jan-2011 James Dong <jdong@google.com> Use metadata in video buffers for timelapse video recording by default to eliminate memcpy

bug - 3361771

Change-Id: Ib37ffe4be8edc8708baa76b3507b6f11372536d9
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
31389148f4ab7587e150f4043b7379eaefe2af2b 18-Jan-2011 James Dong <jdong@google.com> Fix the sluggish preview during timelapse video recording because software encoder is used.

bug - 3361771

Change-Id: Ic5344e9eabe7f1b82910b65b4260e4ad8dc51c32
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
42dd1d5f186252a7f09f8fb1a46ea82e3877b2d3 13-Jan-2011 James Dong <jdong@google.com> Add audio encoding parameters check

bug - 3345296

Change-Id: If3f33955f5473b0c5ad9c9b85f8b5cb21ddd7e65
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
2d1e5d35be5e6d4b55ac8b39fbfcbeb60fcdd084 20-Dec-2010 James Dong <jdong@google.com> Backward-compatibility max file size support, ignoring 0 or negative file size limit

bug - 3281011

Change-Id: I2d3ae4565602e2374ca794c5e8d0837ad33cf0e8
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
ba29002c7aee13c068049037cd14bba6a244da6b 10-Dec-2010 James Dong <jdong@google.com> First step towards renabling Timelapse video recording

Change-Id: I93836b066fb69d5152d3774546a9935057a1f12f
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
ea7b485595f8cec6a66668b5c54c8f297d843f77 05-Dec-2010 James Dong <jdong@google.com> Remove check if the target video resolution is not supported by CameraSource
and clean up Camera is CameraSource could not created.

bug - 3254411

Change-Id: I43497c450e7007de5ce027e2912b1421119e8887
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
1cc73922339a110d7ffc47e8842f958492dd85bf 02-Dec-2010 James Dong <jdong@google.com> If camera source uses the metadata, we must use HW encoder
Software video encoders are not able to deal with non-YUV metadata in the video buffer sent from camera

bug - 3242213

Change-Id: I97361ed88b2a687190e5129459011afff7f32c2d
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
f6882a9c8144dc0fd07f3434bb870e5251f51275 02-Dec-2010 James Dong <jdong@google.com> am 80639875: am d4c5478a: Merge "Be conservative in estimating the file size limit." into gingerbread

* commit '806398755fdc63438b607856574e5b885ad98e6b':
Be conservative in estimating the file size limit.
acd234bba9f048971d66890009eeff9a8db94be3 01-Dec-2010 James Dong <jdong@google.com> Be conservative in estimating the file size limit.

bug - 3045580

Change-Id: Ifdffa354b9433639c3f246a0eb581ef14af1e797
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
674ebd0b4e1143e38392a4e3bb38b4679a4577bc 19-Nov-2010 James Dong <jdong@google.com> Removed uncessary FILE structure pointer for I/O

o also move the fd owner from caller to callee in the Writers

Change-Id: I510ccfdd0fcc58f1777fea4ed1349fd251852c65
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
393410a441b6d06daf286ed496470e9d6b2b6ca8 11-Nov-2010 James Dong <jdong@google.com> Separate the key for audio sampling rate and video frame rate in MetaData.h

Change-Id: Ia33befaa7e6df8762703002d01aa79c04f15f040
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
62db7db731c47a00ee1493e94f3e1d953c6e297a 10-Nov-2010 James Dong <jdong@google.com> Fix uninitialized variable

o This was missed while the rotation patch was hand merged.

Change-Id: I4016f9fb9cd54c5e853da15bbaaa50b1d1dac8c8
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
13f6284305e4b27395a23db7882d670bdb1bcae1 09-Nov-2010 James Dong <jdong@google.com> Rotation support

- We only support 0, 90, 180, and 270 degree clockwise rotation

- Some players are known to ignore composition matrix in the MP4 file,
although this is part of the MP4 file standard.
Both QT and YT are supporting the rotation

The original patch (65a73f4e8c79d05c0d9001b660325748d4ecf37b) was not merged.
The only change I made is to reuse the same kKeyRotation in MetaData.h;
and thus do not neeed to use kKeyRotationDegree.

Change-Id: Ib328716d4842201c4adf57e4ddfe1f1ac1ae4d8a
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
aca1fe35480ae76dd6bae167ade40adc955e2d0d 17-Aug-2010 James Dong <jdong@google.com> Rotation support

- We only support 0, 90, 180, and 270 degree clockwise rotation

- Some players are known to ignore composition matrix in the MP4 file,
although this is part of the MP4 file standard.
Both QT and YT are supporting the rotation

Change-Id: I1b7f66a801e9d9c49d889c9b06dd6173fa7e76c4
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
8480835b4bc1350646376aa7f3ae33742a7adeb1 02-Nov-2010 James Dong <jdong@google.com> Use meta data in the media recording framework

o This patch allows us to do 720p video recording

Change-Id: I2ea37e80a59630145396b08ebcdc6ee71df53333
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
ff5bfcf19da45e6bb0136ef818b7c4bf8fd8db3d 04-Nov-2010 James Dong <jdong@google.com> Revert "Support rotation in media recorder"

This reverts commit f1febe470ac30f8992066cb263c10f58493c4c34.
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
5b6edb79827a910d8e677e35e77bc12fdc7772b9 04-Nov-2010 James Dong <jdong@google.com> Support rotation in media recorder

o needs to be tested with camera hal and camcorder application

Change-Id: Ie343185c8ad3ec55da8850efbdcf19cf98993232
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
635730831e08c32a5fe7c59125e0919b7e7899cd 24-Oct-2010 James Dong <jdong@google.com> Don't change the video recording frame rate if it is not requested.

o set the default video frame rate to the current frame rate being used
o add check on whether the requested frame rate is supported
o fix an issue where the hardware video encoder setting was bypassed
o increases the max frame rate from 30 t0 120 frames per second
the actual frame rate will be clipped if the requested frame rate is too
high when recording starts by checking the hardware encoder capabilities

Change-Id: I1b47671d74da0ebcb9601bdca390d430cc048fbc
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
f9f083e2853740c97588f4db82c24645ae5880e4 15-Oct-2010 Kenny Root <kroot@google.com> resolved conflicts for merge of a127c07c to master

Change-Id: Ifdfc6681cba00f36456eaf7a97f34a75b9d0c086
59b7dc39ea8332d3418a599e51447d7edb612ac4 12-Oct-2010 Andreas Huber <andih@google.com> Support for writing to MPEG2 transport stream files.

Change-Id: If3b7a807bc224a4b1cb2236537c3ebdc5aee0d97
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
54ff19ac69ace7c05ea90d225e26dab3b133f487 08-Oct-2010 James Dong <jdong@google.com> Move Camera specific logic out from StagefrightRecorder to CameraSource

o updated comments and streamlined the logic in
checkVideoSize() and checkFrameRate() as suggested

Change-Id: I49d04ac7998d4a215997aa63555dfb6e814e38d3
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
5f4d93467a03b3a38320416f8cc2c2c2c94bf3fc 04-Oct-2010 James Dong <jdong@google.com> Use setVideoSize API in StagefrightRecorder

Change-Id: Ia7ddf5e8d2b931453d2cb801169906191349ca07
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
78eff720c86eb6d4e3d45a144df60b2ca464d2d4 16-Sep-2010 Nipun Kwatra <nkwatra@google.com> Implemented frequent read returns for quick stop in time lapse.

If the frame capture interval is large, read will block for a long time.
Due to the way the mediaRecorder framework works, a stop() call from
mediaRecorder waits until the read returns, causing a long wait for
stop() to return. To avoid this, we return a copy of the last read
frame with the same time stamp if a frame is not available quickly.
This keeps the read() call from blocking too long. This method is
triggered when startQuickReadReturns() is called on
CameraSourceTimeLapse.

In the still camera case, also using waitRelative on Condition
instaed of sleeping, so that we can wake it up.
Also for the idle check instead of sleeping, we now wait on a
condition variable, which is woken up when the last takePicture
callback gets called.

Change-Id: Ia74386e175536aee0f44ae2f8b114c353d3d72f5
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
59d9e31c503e5c2f49448362a0d3a8f1150fb6c2 14-Sep-2010 Nipun Kwatra <nkwatra@google.com> Checks for auxiliary video recording.

- Check that time lapse mode is on when using auxiliary video recording.
- Check that auxiliary video size is strictly less than the main video
size.

Change-Id: Ic49d25e6ac30f6f885ce4f5fb38dbe0cc7bc1be1
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
155e833a7a5fc3e193691324cf9326da1bc3289a 02-Sep-2010 Nipun Kwatra <nkwatra@google.com> Moving decision to use still camera to CameraSourceTimeLapse

CameraSourceTimeLapse now decides whether to use still or video
camera automatically. It checks if the passed in size is a valid
preview size and if it is, then uses the video camera else uses
the still camera.

Removed from StagefrightRecorder the support to set parameter
useStillCameraForTimeLapse.

Change-Id: I71f5b0fc7080ca524792381efe918d22e41a7f36
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
cfe88a20345dad981842b2c8092e4c704d3f98b4 01-Sep-2010 Nipun Kwatra <nkwatra@google.com> Support for auxiliary video parameters.

Added support for passing width, height and video bitrate
for the auxiliary video.
Also setting encoder level depending on the video size and bitrate.

Change-Id: I4a90046853f67287c3e7e6babc75b4827f0c3e73
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
9c075bca0b75093ca0514a3c8f74d73c8e9e83fd 27-Aug-2010 Nipun Kwatra <nkwatra@google.com> Adding support for parallel recording sessions.

- Added setOutputFileAuxiliary to pass the auxiliary file descriptor. The java
interface through JNI will be checked in next.

- renamed setupCameraSource to setupCamera as the function just sets the camera.
- Added setupCameraSource which sets up the camera source. This functionality
was in setupVideoEncoder before.
- setupVideoEncoder now takes in a cameraSource instead of creating it on it
own.

- Refactored startMPEG4Recording() to use setupMPEG4Recording,
setupMPEG4MetaData.
- setupMPEG4Recording() takes in file descriptor, bitrates to setup a mpeg4
writer. This function can be called multiple times to setup multiple
writers.
- Added setupMPEG4MetaData() for setting up the meta data for mpeg4 writer.
startMPEG4Recording() now calls setupMPEG4Recording, setupMPEG4MetaData for
each recording session.

Change-Id: I07f5334a1ff8e12a36f58e94129fcfa6add2208b
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
a8c88e810ea1b8e90fd6c250d4c0a87eb628d4d8 24-Aug-2010 James Dong <jdong@google.com> am 28a92120: am 3f51fa78: Runtime dump support for MediaWriter

Merge commit '28a92120a702289533a9c9d004bd60f83b2fd98b'

* commit '28a92120a702289533a9c9d004bd60f83b2fd98b':
Runtime dump support for MediaWriter
515c0a56b6fbcca18a08f0daac7be278dede46d0 24-Aug-2010 Nipun Kwatra <nkwatra@google.com> am 701b710c: am 300b0b7e: Merge "setParamMaxFileDurationUs should allow zero time input as per API of setMaxDuration." into gingerbread

Merge commit '701b710c194181765616520f6d89d450b4b6c1f5'

* commit '701b710c194181765616520f6d89d450b4b6c1f5':
setParamMaxFileDurationUs should allow zero time input as per API of setMaxDuration.
4b79168835965cf0fc41ebe2a367e22b4cb20d08 11-Aug-2010 Jamie Gennis <jgennis@google.com> Change the framework to use the new camera preview path.

This change makes the camera HAL interface take an ANativeWindow interface from
which all the camera preview buffers will be allocated. The framework code
running in application processes now passes a Surface object rather than an
ISurface to the camera server via Binder when setting the preview surface. The
camera server then forwards that Surface object (which implements the
ANativeWindow interface) to the camera HAL, which uses it to communicate with
SurfaceFlinger to allocate the camera preview buffers.

Change-Id: Ie438f721559cd7de5e4f848a26d96360dda07b5f
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
dedf414d3fe2e79ee0aad0f1c82ca16ebd886ff6 18-Aug-2010 James Dong <jdong@google.com> Runtime dump support for MediaWriter

Change-Id: I10b2c474de612ee4cef4b7c9eae2ee1dd8c2e895
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
263ebfd8a17266eedc84eb879edb6a6a3395f760 21-Aug-2010 James Dong <jdong@google.com> am c8d2fa70: am cbd038fe: Merge "Make MediaWriter stop and pause return errors if necessary" into gingerbread

Merge commit 'c8d2fa704abebdbf0bd8aac185216dc068950217'

* commit 'c8d2fa704abebdbf0bd8aac185216dc068950217':
Make MediaWriter stop and pause return errors if necessary
be6fd201b9a04fe0f8fd409f10595ddb41832591 19-Aug-2010 Nipun Kwatra <nkwatra@google.com> setParamMaxFileDurationUs should allow zero time input as per API of setMaxDuration.

according to MediaRecorder::setMaxDuration documentation we should disable duration limit
when zero or negative time is passed. Currently setParamMaxFileDurationUs was treating
zero/negative as an error case. Fixed that.

Change-Id: I468c3bcc74cb5a34ee3e172cef5147550d6be096
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
37187916a486504acaf83bea30147eb5fbf46ae5 19-Aug-2010 James Dong <jdong@google.com> Make MediaWriter stop and pause return errors if necessary

o Make the API consistent with SF framework, which the MediaSource
provides a return status for stop

o Also, helps to convey errors that occurred right when a
premature stop() is called, leading to a potentially
mal-formed output file.

Change-Id: I52a932345f38570fdf8ea04d67d73dd94ccd30ef
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
8206beb4953e42a727417286cdf9d52c35c2889d 17-Aug-2010 James Dong <jdong@google.com> am f54da15b: am eff30e3d: Change the default time scale for audio/video track during recording and reduce rounding errors in calculating the sample duration

Merge commit 'f54da15b7c3fa55268451c485544e831832fdf15'

* commit 'f54da15b7c3fa55268451c485544e831832fdf15':
Change the default time scale for audio/video track during recording
c059860c73678a202bfa33062723e8f82fb779d9 13-Aug-2010 James Dong <jdong@google.com> Change the default time scale for audio/video track during recording
and reduce rounding errors in calculating the sample duration

- Default time scale for tracks other than audio is set to 90000.
- Audio track by default uses the audio sampling rate as the time scale.
- Default movie time scale remains to be 1000.
- The default time scale values will be overwritten by a user-supplied value if exits.

Change-Id: I81b40ed0626ea45e9fd24a89e21a2c5a4a2c3415
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
2dac90da3ea5120b52844a6ee38c300301de5756 12-Aug-2010 James Dong <jdong@google.com> am 0386d04b: am 581581fe: Merge "Fix all fd leaks in authoring engine" into gingerbread

Merge commit '0386d04b19619b03b6bce830010e11d31d3f8a5c'

* commit '0386d04b19619b03b6bce830010e11d31d3f8a5c':
Fix all fd leaks in authoring engine
25d83125cee222993673d3ba261ae1186bcad8c2 12-Aug-2010 James Dong <jdong@google.com> Fix all fd leaks in authoring engine

Change-Id: I17798543f9dd41cc8bef6f6086e66932f9f97be8
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
ca2fa61ef03cac008ea86e6fe16b2e5f9f1a2be3 04-Aug-2010 Nipun Kwatra <nkwatra@google.com> When using still camera for time lapse capture, don't set preview.

Since HD resolution may not be supported by the video camera,
don't set preivew using the HD size. The app should have set the
preview already, just use that.

Change-Id: I2f8e89bf2c7440f7bc8db7e4a228f4c8250d92b4
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
982a93173bc84f005172152d823cbb59dfcbeb12 05-Aug-2010 Andreas Huber <andih@google.com> am 1f513d88: am c17f35dd: Merge "Support for Gtalk video, includes AMR/H.263 assembler and packetization support, extensions to MediaRecorder to stream via RTP over a pair of UDP sockets as well as various fixes to the RTP implementation." into gingerbread

Merge commit '1f513d8821670a33d6361ea521b6756163a3f9bf'

* commit '1f513d8821670a33d6361ea521b6756163a3f9bf':
Support for Gtalk video, includes AMR/H.263 assembler and packetization support, extensions to MediaRecorder to stream via RTP over a pair of UDP sockets as well as various fixes to the RTP implementation.
39ddf8e0f18766f7ba1e3246b774aa6ebd93eea8 04-Aug-2010 Andreas Huber <andih@google.com> Support for Gtalk video, includes AMR/H.263 assembler and packetization support, extensions to MediaRecorder to stream via RTP over a pair of UDP sockets as well as various fixes to the RTP implementation.

Change-Id: I95b8dd487061add9bade15749e563b01cd99d9a6
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
e41f9ba4869a96f004c731d8d17939ae607143b9 04-Aug-2010 James Dong <jdong@google.com> am d152c1c7: am d194f3d6: Merge "Replace CHECK with a failure return value when mCamera->setParameters() fails if the camera is locked by someone else." into gingerbread

Merge commit 'd152c1c7534a80b84f6b389efa8a410ea359b3eb'

* commit 'd152c1c7534a80b84f6b389efa8a410ea359b3eb':
Replace CHECK with a failure return value when mCamera->setParameters() fails
48f6ce0e17297c575dcbb25671a7bee80ba13061 04-Aug-2010 James Dong <jdong@google.com> Replace CHECK with a failure return value when mCamera->setParameters() fails
if the camera is locked by someone else.

bug - 2827892

Change-Id: I217d4a00f04ebd57b557d3faef28787c14f23ea0
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
f95ce6452d87316b8f5df6692537bd039377f349 02-Aug-2010 Nipun Kwatra <nkwatra@google.com> Allowing useStillCameraForTimeLapse to be set through MediaRecorder.java

This will allow apps to make the decision of whether to use still image mode or
video mode for time lapse capture.

- setTimeLapseParameters now takes in a useStillCameraForTimeLapse parameter.
- Added support in StagefrightRecorder for passing through this parameter.

Change-Id: Iafbcb76f9a7903118ea5eb822c81008619630f03
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
30e3eb619f02cf36e6d1d31be528d6be552bb3e2 30-Jul-2010 James Dong <jdong@google.com> am e915b0ef: am d973a533: Merge "Lower the lower bound for max file duration check" into gingerbread

Merge commit 'e915b0ef5d574022dfeffc9b2b61e21c1433c89c'

* commit 'e915b0ef5d574022dfeffc9b2b61e21c1433c89c':
Lower the lower bound for max file duration check
e4fc55de48241c5fb4c4b9d652fd2d4cd0b71138 30-Jul-2010 James Dong <jdong@google.com> Lower the lower bound for max file duration check

- This fixed a CTS test where 200 ms is being used

Change-Id: Ib598b7b94be54e98a96703c58c5f244bc379cf7d
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
3722abe1a6ae53034b9dee6b12e8513804622fd5 28-Jul-2010 James Dong <jdong@google.com> am cb51115c: am 5587bb7e: Merge "Interleave the audio and video by default - default interleave duration is set to 1 second" into gingerbread

Merge commit 'cb51115cca81ba47d00aa344f6ed16d1056b056b'

* commit 'cb51115cca81ba47d00aa344f6ed16d1056b056b':
Interleave the audio and video by default
f01528f435e6b1f02d118fcd8305a148c27a89f1 28-Jul-2010 James Dong <jdong@google.com> Interleave the audio and video by default
- default interleave duration is set to 1 second

This can dramatically reduce the memory usage
by the MP4 file writer.

Change-Id: Ia3ff202cabfcd2d3f183065d31e4596617c2dded
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
e4e0a6994d39c4a7cba09c5fff442b2dca1df8f8 21-Jul-2010 Nipun Kwatra <nkwatra@google.com> Allowing setting of time lapse parameters through MediaRecorder.java

added setTimeLapseParameters() to MediaRecorder.java and SetParameter support
in StagefrightRecorder to allow enabling time lapse and setting the corresponding
parameters.

Change-Id: I509040aa71f8d3fc37337b0894a81d9c0fd7a40a
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
932e0a11d74d5e236ccef9ee314442385c3d4e9d 21-Jul-2010 James Dong <jdong@google.com> am 9049fe60: am d7514ec6: Merge "Progress status notification" into gingerbread

Merge commit '9049fe60c20640bd606741c8f45f3f781a1684f5'

* commit '9049fe60c20640bd606741c8f45f3f781a1684f5':
Progress status notification
7a42770f47225483a885b168d05e81b6a81189c0 20-Jul-2010 Nipun Kwatra <nkwatra@google.com> Use software encoder for time lapse capture.

Change-Id: I7f60eb1af95590c84b0cd98134f5a5a8963338dd
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
faed5cd124a54b8db3429f4c26b3220bbec4c8bb 16-Jul-2010 James Dong <jdong@google.com> Progress status notification

- Keep track of per-track progress

Change-Id: Ibd36f0e8c78581928c8aa2f5e23c5e7e0615c2cc
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
65e7e6facda89927cb26594b3b65ae81b3235ebc 12-Jul-2010 Nipun Kwatra <nkwatra@google.com> Adding support for timelapse capture using still camera's takepicture.
Also moving entire implementation into a new class CameraSourceTimeLapse
which inherits from CameraSource.

For timelapse capture using still camera, we start a thread which runs a
loop in which it calls Camera::takePicture() and then sleeps until the next
frame should be captured.
The function dataCallback() handles the callback from the camera with the
raw image data. This function copies the data and creates an artificial
timestamp corresponding to one frame time ahead of the last encoded frame's
time stamp. It then calls dataCallbackTimestamp() of the base class which
will think that it recieved the frame from a video camera and proceed as usual.

For moving the implementation to the subclass CameraSourceTimeLapse, added a
few virtual functions to CameraSource, which do the current thing for the base
class, but specialized things for CameraSourceTimeLapse.
E.g. startCameraRecording() in the base class just calls mCamera->startRecording(),
while in CameraSourceTimeLapse it may start a thread for the still camera case.

Change-Id: Ib787f24bd2e1f41681513f0257e1c4ca10a2b4de
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
cbcc684555a8774b21ba04c09b2f5cee8c88453a 15-Jul-2010 James Dong <jdong@google.com> am b068b47c: am d6a85a21: Merge "Support user-supplied timescales for authoring" into gingerbread

Merge commit 'b068b47c6d0214256116a0c661740bddf7acc18c'

* commit 'b068b47c6d0214256116a0c661740bddf7acc18c':
Support user-supplied timescales for authoring
8f5f2fcee5c12d08df71d17017410c50951fc2e3 02-Jul-2010 James Dong <jdong@google.com> Support user-supplied timescales for authoring

- also, change all the real time unit to microseconds in MPEG4Writer

Change-Id: I260f512f2eb670ade7b8858a56335a5d639de756
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
f6266bb1912255e92e590fcb6aedb719898545da 13-Jul-2010 James Dong <jdong@google.com> am f6bdc764: am 9d8bea11: Merge "Initial checkin for software AVC encoder" into gingerbread

Merge commit 'f6bdc764b7a21f8037504e1dc4f81227ea2bedea'

* commit 'f6bdc764b7a21f8037504e1dc4f81227ea2bedea':
Initial checkin for software AVC encoder
29a84457aed4c45bc900998b5e11c03023264208 03-Jul-2010 James Dong <jdong@google.com> Initial checkin for software AVC encoder

- Since the software encoder assumes the input is YUV420 planar,
color conversion needs to be added when the input color format
does not meet the requirement. With this patch, I only added
a single color conversion from YUV420 semi planar to YUV420
planar. We can add more as we go.

Change-Id: If8640c9e5a4f73d385ae9bb2022e57f7f62b91b9
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
004a77836d1963847acd20ea684e2ffe48aa3f19 09-Jul-2010 James Dong <jdong@google.com> am 4f440632: am 929642ee: Add runtime dumpsys support for media recorder client

Merge commit '4f4406322dafd6e128b437edbc541327f0b38d04'

* commit '4f4406322dafd6e128b437edbc541327f0b38d04':
Add runtime dumpsys support for media recorder client
b914122eb9cb54bbeae4ec03bfebb194aecdccbd 08-Jul-2010 James Dong <jdong@google.com> Add runtime dumpsys support for media recorder client

Change-Id: I4c8a81720f3be2db54678a7e84fe12849255046b
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
bf21177ccede8f01c0da0bd53392a289a5a84462 08-Jul-2010 James Dong <jdong@google.com> am b3598832: am c4243342: Merge "Allow application to set two more encoding paramters: video profile and level" into gingerbread

Merge commit 'b35988329ac1a574898db9226039e37e352c57a8'

* commit 'b35988329ac1a574898db9226039e37e352c57a8':
Allow application to set two more encoding paramters: video profile and level
145bfe5eb3e08c9689c28f6bf3287a979438b04b 02-Jul-2010 James Dong <jdong@google.com> Allow application to set two more encoding paramters: video profile and level

Change-Id: I673e681cefe184d5c556c612c54600a24a2143e5
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
fc20aab463f527ab3b0664986f0381a86b375884 01-Jul-2010 Nipun Kwatra <nkwatra@google.com> Adding timelapse capture from videocamera.

Current implementation looks at the timestamps of all incoming frames in
CameraSource::dataCallbackTimestamp().
It drops all frames until enough time has elapsed to get the next time lapse frame.
When enough time has passed to capture the next time lapse frame, the frame is no longer dropped
and the timestamp of this frame is modified to be one frame time (1/framerate) ahead of the
last encoded frame's time stamp.

Change-Id: I82b9d5e96113dffa6901aac3b8a8ef999ffc1d0b
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
934da11c4cc598d3dd3b53726c362bcdcc0fd37f 30-Jun-2010 James Dong <jdong@google.com> Refactor Stagefright::StartMPEG4Recording()

- Also, better error handling

Change-Id: Ic18d08dc6489adf92c6a588efa4baca66429b175
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
d329e21495eda9dbc531fdd0c26c77f1593ac3f4 30-Jun-2010 James Dong <jdong@google.com> Added encoding parameters set up for H263 video encoder

Also:
- Allowed start() call when encoder already starts and stop() call when encoder has not started yet
- Handled default value for audio/video sources/encoders and file output format

Change-Id: I03b2f7d3cf570baa0fd011a8c0ad200f2f2a5da1
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
37047fceba836f341d0108beed0991b0f8dfc543 26-Jun-2010 James Dong <jdong@google.com> Separate MediaRecorderClient with MediaPlayerClient

- An alternative would be to define a common base class that
both MediaRecorderClient and MediaPlayerClient can derive.
But since the common code, onTransact() and notify() uses
some Binder code, having a common base class may not gain
us too much in terms of code reuse.

Change-Id: Ibc06720278ad173fceacff3d267b7060856c6316
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
93d6b102a13afa23bfa80d74c399d93d542e6ad6 25-Jun-2010 James Dong <jdong@google.com> Provide progress status report during authoring

- Track either the number of A/V frames authored, or the time elapsed
- Track the completion of the authoring
- Add multiple camera support for authoring by accepting a camera id parameter
- Set file type based on the OUTPUT_FORMAT requested

Change-Id: I0f9d31b3b7a8fa43eb53f572410fb0ebd4fa0bb7
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
2dec2b5be2056c6d9428897dc672185872d30d17 20-Jun-2010 James Dong <jdong@google.com> Enable passing parameters to the MediaWriter at runtime (at start() call).

- estimate the moov box size for mp4 file writer based on the file
size/duration limit and target bit rate.
- can switch to use 64 bit file offset at runtime

rebased

Change-Id: Ibbe1f57e91ab2605820d5d96e8048d11e5559c53
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
d3d4e5069e1af0437c4f5a7b4ba344bda5b937af 25-Jun-2010 James Dong <jdong@google.com> Track maximum amplitude and fix getMaxAmplitude()

- only start to track the max amplitude after the first call to getMaxAmplitude()

Change-Id: I64d3d9ca0542202a8535a211425e8bccceca50fc
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
99c2a076b4a46762a22bbb4dfbd51d107e0532d9 17-Jun-2010 James Dong <jdong@google.com> Check and clip some video encoding parameters against media profiles before passing them to video encoder

Change-Id: I69e0e7411806a4ece6c0bf0e02c74eaaf48a17ac
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
be6ec71af2d12e2a55f2f0b1b77d3fa5d593a1c7 15-Jun-2010 James Dong <jdong@google.com> Remove hard-coded number of audio channels in AudioSource

Change-Id: I5f362252c25e2251bbfa9818b711ee23b4975248
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
a7d1a2dd776bf356c228785a94ba8e0ff6a2ec7f 10-Jun-2010 James Dong <jdong@google.com> Initial checkin for pause and resume control

Change-Id: Ibdcf7bea5fb66baa81878704ba4091dfcfe382ee
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
9d7f58a7da8502a4174a17ac49fcba6efa35a457 10-Jun-2010 James Dong <jdong@google.com> Remove the lock/unlock workaround from CameraService

bug - 2677772

Change-Id: I7c996daad8b3bfc89e9fa2d655dc18c9a5c68f2f
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
ddcc4a66d848deef6fb4689e64e30cd9bd2684fe 08-Jun-2010 James Dong <jdong@google.com> Remove some hard-coded encoding parameters

Change-Id: I7a8ccd5d57891a6a585c8da2ee53acb094955913
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
e136c3bb38e88315bf8797a464ebf2c788296b22 21-May-2010 James Dong <jdong@google.com> Properly handle start code in H264/AVC encoder output

- Some H264/AVC encoder output start code in each output buffer, and others don't.
This patch always strips the start code first so that the sample contains the correct size.
- Also properly initialize the interleave duration.

Change-Id: I692043ce7e38f0215e1097aad9e847a57907b6e4
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
7405500bb3b5f8e8e739e344bc9d036c2736fcdf 20-May-2010 James Dong <jdong@google.com> Workaround for preview frame rate setting and encoder profile and level settings on passion
1. QCOM camera HAL does not honor the preview frame rate set request. see bug - 2701282
2. QCOM video encoder has lots of 0-length output buffers if the default level setting is changed. see bug - 2660974

Change-Id: Id01d94bb77dc242c4712d56a91b0d69a96ba6c2f
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
f0ce2fb0c7bf3a414279e5aba61105f3d9025c0e 14-May-2010 James Dong <jdong@google.com> Detect and handle premature termination of a recording session

Change-Id: Ifb83b19f3e68580345b23efed5d5956fb81baeb8
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
d599cd4573b5a2d5914c5040e0565ef866749b77 11-May-2010 James Dong <jdong@google.com> Handle recording file size and/or duration limit

Change-Id: Ib9ed1f3ebd8fef550cc130a7ef11f2905fa9aedc
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
65ae665befd929efd1a7d1c9addac41c699f04b2 13-May-2010 James Dong <jdong@google.com> Remove dummy surface in CameraSource

bug - 2680919

Change-Id: Ia0308cf57fd67058b4dd0e042b3ce97f13df475f
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
ef9d0cd72e476a4b7556833fb09505a51b626797 11-May-2010 James Dong <jdong@google.com> Added initial validation on video/audio encoding parameters before/at start()

Change-Id: I1a40dd247202f70e3e5429d74533d349b88f1d54
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
13aec890216948b0c364f8f92792129d0335f506 22-Apr-2010 James Dong <jdong@google.com> Support audio and video track interleaving in the recorded mp4 file

Change-Id: Ifa27eb23ee265f84fe06773b29b0eb2b0b075b60
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
050b28a593350047845a45a14cc5026221ac1620 23-Apr-2010 James Dong <jdong@google.com> Support AAC recording

- Extend the audio recording to AAC format
- Add support for setting some recording parameters
- Add stss box to the meta data in the recorded file

Change-Id: I41167bfd9d70ef9cd33906f8437b39c232b6d3b7
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
c32cd79d9ad4aba7d959b5b3be7361b4715e6f18 27-Apr-2010 James Dong <jdong@google.com> Use timestamp from camera driver for CameraSource

Change-Id: I09ddec69997c43b8f17fdd21304c76cb4c5ab8cf
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
3cf613507f1e2f7bd932d921a6e222e426fd3be4 10-Feb-2010 Mathias Agopian <mathias@google.com> split libsurfaceflinger_client and libcamera_client out of libui
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
b45c62c8e9b05c2703bdae18cc298ae55550db8a 11-Feb-2010 Andreas Huber <andih@google.com> Fixing AMR recording code.
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
2dce41ad26cb3e9e15c9e456a84bcf5309548ca0 26-Jan-2010 Andreas Huber <andih@google.com> Support for audio recording into AMR NB/WB files as well as audio tracks in MPEG4 files.

related-to-bug: 2295449
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp
30ab66297501757d745b9ae10da61adcd891f497 17-Nov-2009 Andreas Huber <andih@google.com> Squashed commit of the following:

commit 333057b355f8c260c549553b9a0634755c838b6a
Author: Andreas Huber <andih@google.com>
Date: Fri Nov 13 15:35:48 2009 -0800

Some more tweaks to AVC encoding on sholes.

commit 9981d0ee52ec5b8b0182aae733d1571e3ebb8390
Author: Andreas Huber <andih@google.com>
Date: Thu Nov 12 16:36:57 2009 -0800

Support for avc encoding, including sholes specific tweaks to pick the right colorspace for the camera to not require transcoding.

commit 5ba0ebbbd4efca51f3ae1f60e2ca31e7d2cf136d
Author: Andreas Huber <andih@google.com>
Date: Wed Nov 11 09:50:03 2009 -0800

Enable actual (camera) video-only recording using h.263 or mpeg4 encoding.

commit 3fd59c3526a37fe7c696f4a978925d1831c09313
Author: Andreas Huber <andih@google.com>
Date: Tue Nov 10 14:57:48 2009 -0800

Allow switching between the PV recorder implementation and one supported by stagefright.

This is controlled through the property "media.stagefright.enable-record".
/frameworks/av/media/libmediaplayerservice/StagefrightRecorder.cpp