2198 Commits

Author SHA1 Message Date
Andreas Huber
b6c2e2b46c DO NOT MERGE: More robust parsing of NPT time ranges in RTSP.
Change-Id: If5a00f1e29dbc12956e1fb000dac859706d19791
related-to-bug: 3217210
2011-01-28 09:58:11 -08:00
Andreas Huber
2dce338e01 DO NOT MERGE: This particular RTSP server streams MPEG4-LATM audio with extra trailing bytes.
And now we're just ignoring them. Yay standards.

Change-Id: Ia8c0b9161e606152fb681f0dda3ba901954dc749
related-to-bug: 3353752
2011-01-26 16:03:33 -08:00
Jean-Michel Trivi
2ba92c71b5 do not merge bug 3370834 Cherrypick from master
Cherripick from master CL 79833, 79417, 78864, 80332, 87500

Add new audio mode and recording source for audio communications
 other than telelphony.

The audio mode MODE_IN_CALL signals the system the device a phone
 call is currently underway. There was no way for audio video
 chat or VoIP applications to signal a call is underway, but not
 using the telephony resources. This change introduces a new mode
 to address this. Changes in other parts of the system (java
 and native) are required to take this new mode into account.
The generic AudioPolicyManager is updated to not use its phone
 state variable directly, but to use two new convenience methods,
 isInCall() and isStateInCall(int) instead.

Add a recording source used to designate a recording stream for
voice communications such as VoIP.

Update the platform-independent audio policy manager to pass the
 nature of the audio recording source to the audio policy client
 interface through the AudioPolicyClientInterface::setParameters()
 method.

SIP calls should set the audio mode to MODE_IN_COMMUNICATION,
 Audio mode MODE_IN_CALL is reserved for telephony.

SIP: Enable built-in echo canceler if available.
1. Always initialize AudioRecord with VOICE_COMMUNICATION.
2. If echo canceler is available, disable our echo suppressor.

Note that this CL is intentionally not correcting the
 getAudioSourceMax() return value in MediaRecorder.java as the
 new source is hidden here.

Change-Id: Ie68cd03c50553101aa2ad838fe9459b2cf151bc8
2011-01-26 11:20:01 -08:00
Marco Nelissen
c929677e01 Merge "Increase the number of useful bits in the spectrum." into gingerbread 2011-01-25 10:06:16 -08:00
Andreas Huber
efebdf4bd4 DO NOT MERGE: Support non-multiple-of-16 dimensions in MPEG4/H.263 software decoder
Change-Id: I6c27c00a6e13cb3635e61089c0db0989f5810c37
related-to-bug: 3384367
2011-01-24 15:59:14 -08:00
Marco Nelissen
dbc0fe985f Increase the number of useful bits in the spectrum.
Change-Id: I3efc2ac8db689285566df35cb6f594aab41141db
2011-01-24 08:47:55 -08:00
Andreas Huber
a2ab9aace3 DO NOT MERGE: Prefill the cache before trying to instantiate the media extractor.
The latter is an operation that otherwise could block on the datasource
for a significant amount of time. During that time we'd be unable to
abort the preparation phase without this prefill.

Change-Id: I3bc889b264f599bfd5c2bbdf48b88ccb55d86172
related-to-bug: 3362836
2011-01-19 15:44:23 -08:00
Andreas Huber
0e49d20107 DO NOT MERGE: Apparently our native TCP sockets do not return an error from blocking "connect"
if the network interface is shutdown while connecting.

Change-Id: I168c6026de24812efa9b7e607a9eb83efded8c1f
related-to-bug: 3362836
2011-01-18 15:52:31 -08:00
James Dong
9efe47374b Squash commits of the following patches, cherry-picked from other branch - do not merge.
o Prepare for publishing MediaMetadataRetriever as public API
  step one:
  o replaced captureFrame with getFrameAtTime
  o removed getMode

o Replace MediaMetadataRetriever.captureFrame() with MediaMetadataRetriever.getFrameAtTime()
  as part of the preparation for publishing MediaMetadataRetriever as public Java API

o Remove captureFrame from MediaMetadataRetriever.java class
  It has been replaced by getFrameAtTime() method

o Replace extractAlbumArt() with getEmbeddedPicture() in MediaMetadataRetriever.java

o Publish MediaMetadataRetriever.java as public API
  o Removed setMode() methods and related mode constants
  o Removed some of the unused the metadata keys
  o Updated the javadoc
  o part of a multi-project change.

bug - 3309041

Change-Id: I2efb6e8b8d52897186b016cb4efda6862f5584c4
2011-01-12 17:12:46 -08:00
Andreas Huber
7c6153606c Fail to parse duration instead of asserting, if the server response cannot be parsed.
Change-Id: I95c61ed83800db82e99c0023b942fb8ae05ed3cf
related-to-bug: 3338518
2011-01-12 09:57:23 -08:00
Andreas Huber
7e2f9cc81d DO NOT MERGE: Fix Matroska issues
related-to-bug: 3331623

Squashed commit of the following:

commit 8484811f3784564ce962ec1b6311bac532d73ffc
Author: Andreas Huber <andih@google.com>
Date:   Tue Jan 11 11:56:06 2011 -0800

    Properly parse Matroska lacing flags and extract all frames contained in a block.

    related-to-bug: 3331623

commit 38f1f39381a01659577461b3d35bd22db45ba317
Author: Andreas Huber <andih@google.com>
Date:   Mon Nov 15 15:10:34 2010 -0800

    Proper support for variable NALsize lengths of AVC content in .mkv files.

    related-to-bug: 3197442

Change-Id: I4b404f3c3d0a2a2fa336b9edff75eb25ffc66a2f
2011-01-11 16:02:31 -08:00
Andreas Huber
549f12ad04 DO NOT MERGE: Fix parsing of ntp= PLAY response.
related-to-bug: 3340186

Squashed commit of the following:

commit b61c36b7228aec9f5360883b1e1c1e0530488974
Author: Andreas Huber <andih@google.com>
Date:   Wed Oct 27 13:59:59 2010 -0700

    Better support for MP4A-LATM RTP disassembly. This used to fail if mNumSubFrames > 1 and the sub frames did not align with RTP packet boundaries.

commit b10f322c07e5bebcaf032e8624cb4a5d733dfc15
Author: Andreas Huber <andih@google.com>
Date:   Mon Oct 25 09:40:52 2010 -0700

    We don't have access to the md5 implementation on the simulator, let's disable digest authentication in rtsp for simulator targets.

commit 0aa83cf9e4637adf9501708fcdf7d0d6d4dc4fe1
Author: Andreas Huber <andih@google.com>
Date:   Wed Oct 20 15:00:34 2010 -0700

    Support for BASIC and DIGEST authentication schemes in RTSP. Support for malformed packet descriptions that end lines in LF only, instead of CRLF.

    related-to-bug: 3084183

Change-Id: I6e512cb73cc8d5624a83f7154aa5699f7fef7534
2011-01-11 09:53:30 -08:00
James Dong
6328185b6c Avoid deadlock in OMX::freeNode by making sure OMXCodecObserver does not hold the last reference of OMXCodec object - do not merge
cherry-picked from: I4c79b66a900c527e3ae6a833f76d5da1b75c5a89

bug - 3336424

Change-Id: I2d8ecb79a5422342988c195c012c9e6327ac457a
2011-01-10 10:27:02 -08:00
Yu Shan Emily Lau
2af4e71dd4 Merge "Fix the test application orientation. Bug# 3205196" into gingerbread 2011-01-07 09:38:24 -08:00
Marco Nelissen
f13d450139 Send "compilation" tag when inserting into the database.
It's not actually inserted into the database, but the media provider uses it
for disambiguating albums.
b/3311831

Change-Id: Idb630866e960338ce2795dcc128cafaf6c9c27f2
2011-01-06 16:37:03 -08:00
Marco Nelissen
ba77a3f9cb Add support for the "compilation" tag in mp3, mp4 and ogg, and also add
support for two common ways of specifying album artist in ogg files.
b/3311831

Change-Id: Iba1152013b7577168af71f947d7249560419fa05
2011-01-06 15:05:06 -08:00
Yu Shan Emily Lau
d97943d5d0 Fix the test application orientation. Bug# 3205196
Change-Id: I57085d6507482ce15dbf3b167965be4af43b3d88
2011-01-04 20:57:09 -08:00
James Dong
d609ca7f6a Expose AMRNB/WB and AAC encoder and related file output formats - do not merge
bug - 3305667

Change-Id: I8f137af7f87cb010f75cae1777b9ec6b6af8214f
2010-12-22 12:12:12 -08:00
Eric Laurent
36d41b8103 Fix issue 2712130: Sholes: problem when playing audio while recording over bluetooth SCO.
The problem is that when an input stream is opened for record over bluetooth SCO, the kernel
mono audio device should be opened in RW mode to allow further use of this same device by an output stream
also routed to bluetooth SCO.
This does not happen because of a bug in AudioSystem::isBluetoothScoDevice() that does not return true
when the device is DEVICE_IN_BLUETOOTH_SCO_HEADSET (input device for blurtooth SCO).

Change-Id: Ic78bf324b4a68e65721d763dc7682ce7a8f14f75
2010-12-15 19:09:42 -08:00
James Dong
da1b16ad41 When INFO_FORMAT_CHANGED event comes in before the renderer was initialized, go back to read from source again
bug - 3264094

Change-Id: I291a9b09b335d0eb4acf91f992e59fc44bc57d01
2010-12-08 15:37:14 -08:00
James Dong
5cdcf16ec7 Be conservative in estimating the file size limit.
bug - 3045580

Change-Id: Ifdffa354b9433639c3f246a0eb581ef14af1e797
2010-11-30 18:18:08 -08:00
Andreas Huber
30c818444d Merge "DO NOT MERGE Support for "chunked" HTTP transfer encoding." into gingerbread 2010-11-30 14:30:00 -08:00
Andreas Huber
a41c1e1de0 Merge "DO NOT MERGE Upgrade to the latest version of libwebm to fix YouTube webm playback." into gingerbread 2010-11-30 14:06:26 -08:00
Andreas Huber
d208a2c7b0 DO NOT MERGE Upgrade to the latest version of libwebm to fix YouTube webm playback.
DO NOT MERGE
related-to-bug: 3141937

Change-Id: Iaf1b0c5d45a6b5bb7624a59747041c27b4dde83b
2010-11-30 13:42:50 -08:00
Andreas Huber
8d023ddcd4 DO NOT MERGE Support for "chunked" HTTP transfer encoding.
DO NOT MERGE

Change-Id: I253d48ea69f239a6d3d0bb7e0d31eef5c773a9d6
related-to-bug: 3205131
2010-11-30 13:37:01 -08:00
Andreas Huber
567b2bd146 Merge "After seeking display the first new video frame right away without concern for A/V sync. This looks much more responsive to the user." into gingerbread 2010-11-30 13:00:14 -08:00
Eric Laurent
688f4c58d4 Merge "Update java doc for visualizer FFT capture." into gingerbread 2010-11-30 11:50:25 -08:00
Andreas Huber
0fb258d6c3 After seeking display the first new video frame right away without concern for A/V sync. This looks much more responsive to the user.
Change-Id: Ifb1f8c91e95a5cafe30ae1035973316c210b98a5
related-to-bug: 3152363
2010-11-30 11:46:38 -08:00
Andreas Huber
122a9ccbcd DO NOT MERGE - Instead of asserting that ISurface successfully registered buffers, report an error and propagate it up to the java client.
Change-Id: Ibb14e5aff20920da4917d85de38ba3a8ee71d0bd
related-to-bug: 3188835
2010-11-30 10:50:25 -08:00
Chia-chi Yeh
683a7ff922 Merge "Visualizer: Fix the conversion from 8-bit sample to 16-bit sample." into gingerbread 2010-11-29 22:56:56 -08:00
Wu-cheng Li
f6bd761f94 Use back-facing camera as default in camera/camcorder profile.do not merge
bug:3173302
Change-Id: I11eaed32bb393206b560834d52c412f3e5a1a7d9
2010-11-09 14:11:45 +08:00
James Dong
1b2efbca71 Merge "Update a comment about when setOrientationHint() should be called" into gingerbread 2010-11-08 19:59:16 -08:00
James Dong
53ebc72fd8 Support extracting thumbnail from rotated video tracks
Change-Id: Ife0a2536aaac5ff1efdf1035b9d2c892773ee16c
2010-11-08 16:52:59 -08:00
James Dong
5aa95dd36c Update a comment about when setOrientationHint() should be called
Change-Id: I389089390a552ee7a86823c050048dcec0a0eb2a
2010-11-08 10:36:53 -08:00
Andreas Huber
31dc911aee Support post-decode video rotation.
Change-Id: Ia371316e73a57e44610de86adce3eaa560afbf84
2010-11-05 17:03:17 -07:00
James Dong
1653e261e8 Merge "Rotation support" into gingerbread 2010-11-05 16:58:51 -07:00
James Dong
ad8f19c6b3 Add a new public API to support recording rotated videos
o changed a comment about the rotation orientation from counter-clockwise
  to clockwise.

Change-Id: I16ad73ce1a55cc627d9a516e23d1325753b3037e
2010-11-05 15:53:00 -07:00
James Dong
65a73f4e8c 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
2010-11-05 15:47:52 -07:00
James Dong
c80c28801d Revert "Support rotation in media recorder"
This reverts commit f1febe470ac30f8992066cb263c10f58493c4c34.
2010-11-03 19:22:47 -07:00
James Dong
f1febe470a Support rotation in media recorder
o needs to be tested with camera hal and camcorder application

Change-Id: Ie343185c8ad3ec55da8850efbdcf19cf98993232
2010-11-03 17:49:55 -07:00
James Dong
6786fccf5a DO NOT MERGE
Fix premature release of recording frames when physical address or metadata is stored in input video buffers

- bug 3158459

Change-Id: If297189d2a87fc3abfda68c29ac75b490b30a902
2010-11-02 19:30:01 -07:00
Chia-chi Yeh
67f41771d5 Visualizer: Fix the conversion from 8-bit sample to 16-bit sample.
Change-Id: Ie6d77b0f61a37333e05cdcdb6ef29d6f6c345a9d
2010-11-01 10:56:45 +08:00
Eric Laurent
03a4090b4d Update java doc for visualizer FFT capture.
The java doc for visualizer FFT capture was not describing
correctly the layout of the data returned by getFft() method.

Change-Id: Idec09538490ea73b211db253b1b8b733ca4d4a72
2010-10-28 10:14:07 -07:00
Yu Shan Emily Lau
8b023a2ea2 Merge "Add the mediaplayer release in the test validation. This is to ensure the media player release properly." into gingerbread 2010-10-27 11:12:58 -07:00
Marco Nelissen
f514bdc964 Fix off-by-two and other bugs in the visualization code.
b/3137511

Change-Id: Ic431701e93c025bc417c9742e9af6bb2350c7dd6
2010-10-27 10:23:59 -07:00
Andreas Huber
0a612889b5 Assume that all of the decoded vorbis audio data is valid unless the source indicates otherwise.
Change-Id: Iea88e3f09955d82a9a11fbcc075db8d9c4007490
2010-10-26 15:06:44 -07:00
Yu Shan Emily Lau
93aa00c664 Add the mediaplayer release in the test validation. This is to ensure the media player release properly.
Change-Id: Ia4758a3c549b64b6efead18e7538d977dee2be76
2010-10-26 14:36:09 -07:00
Eric Laurent
cc02ac54ac Fix issue 3126094.
android_media_Visualizer.cpp:
Delete local reference to jArray in captureCallback() in
the case of waveform capture.

Change-Id: Ia822ab6d9945fff93605f7732e56120c19fd42a5
2010-10-22 18:08:13 -07:00
James Dong
89a0104c7c Turn the media time adjustment in file writer back on
o This was turned off to unblock the tests on some device
o The adjustment duration is increased to suppress fluctuations observed on some device

bug - 3058745

Change-Id: Iaeeb1c1c52783f5c679305645c995e57b4b2a573
2010-10-21 18:41:31 -07:00
James Dong
22b37fa6e0 File writer size estimation improvement
o Do not count the reserved space for moov if the meta data size is small
o Do not count the extra 1KB disturbing small file estimation.
o Reduce the default minimum reserved space from 4 KB to 3 KB.
o Estimate the moov size based on both duration AND file size limit is set
  and set it to the smaller estimated value.

low risk change

bug - 3111983

Change-Id: I6ac2adb979d8cc12d6b4f1813d000c989add0199
2010-10-19 22:59:22 -07:00