OSDN Git Service

android-x86/frameworks-av.git
13 years agoam e3fb1cb1: Merge "Fix a crash where the EOS was signalled but some output buffer...
James Dong [Wed, 31 Aug 2011 21:20:39 +0000 (14:20 -0700)]
am e3fb1cb1: Merge "Fix a crash where the EOS was signalled but some output buffer were still pending."

* commit 'e3fb1cb1b1f333aadc780c85de0735143ad864b4':
  Fix a crash where the EOS was signalled but some output buffer were still pending.

13 years agoMerge "Fix a crash where the EOS was signalled but some output buffer were still...
James Dong [Wed, 31 Aug 2011 21:17:18 +0000 (14:17 -0700)]
Merge "Fix a crash where the EOS was signalled but some output buffer were still pending."

13 years agoam b2c4f0bf: Merge "Fix SurfaceMediaSource timestamp handling."
Eino-Ville Talvala [Wed, 31 Aug 2011 20:43:05 +0000 (13:43 -0700)]
am b2c4f0bf: Merge "Fix SurfaceMediaSource timestamp handling."

* commit 'b2c4f0bf11f38fd31d80f1256c89b9db043a2929':
  Fix SurfaceMediaSource timestamp handling.

13 years agoMerge "Fix SurfaceMediaSource timestamp handling."
Eino-Ville Talvala [Wed, 31 Aug 2011 20:41:06 +0000 (13:41 -0700)]
Merge "Fix SurfaceMediaSource timestamp handling."

13 years agoam 3727e3d8: Merge "Stop the AudioSource in reset() of AwesomePlayer if AudioSource...
Gloria Wang [Wed, 31 Aug 2011 17:39:35 +0000 (10:39 -0700)]
am 3727e3d8: Merge "Stop the AudioSource in reset() of AwesomePlayer if AudioSource is not NULL and AudioPlayer was not started. Fix for 5236419."

* commit '3727e3d80d37fc8004ddaa4ec589bd8d9c304fad':
  Stop the AudioSource in reset() of AwesomePlayer if AudioSource is not NULL and AudioPlayer was not started. Fix for 5236419.

13 years agoMerge "Stop the AudioSource in reset() of AwesomePlayer if AudioSource is not NULL...
Gloria Wang [Wed, 31 Aug 2011 17:37:48 +0000 (10:37 -0700)]
Merge "Stop the AudioSource in reset() of AwesomePlayer if AudioSource is not NULL and AudioPlayer was not started. Fix for 5236419."

13 years agoStop the AudioSource in reset() of AwesomePlayer if AudioSource is not NULL
Gloria Wang [Wed, 31 Aug 2011 17:24:18 +0000 (10:24 -0700)]
Stop the AudioSource in reset() of AwesomePlayer if AudioSource is not NULL
and AudioPlayer was not started.
Fix for 5236419.

Change-Id: I5eadd069118c3533a19b5d6f6dca2ce16d8505fb

13 years agoMediaPlayer changes for Tungsten/Android@Home.
Mike J. Chen [Mon, 15 Aug 2011 20:24:13 +0000 (13:24 -0700)]
MediaPlayer changes for Tungsten/Android@Home.

Squashed merge from master-tungsten of the following changes:

commit e8b156c6b224f0fe5b6a81d5f92bade36275027c
Author: Jason Simmons <jsimmons@google.com>
Date:   Fri Aug 12 10:28:48 2011 -0700

    Add a null check to handle failure of android::createPlayer

    Change-Id: Iacbbc90369a825838d4374b1f774c8880b25753b

commit 43be3231034ff8537fdd84422a7954780038671f
Author: John Grossman <johngro@google.com>
Date:   Mon Jun 27 18:59:12 2011 -0700

    Move libaah_rtp over from the vendor directory.

    Also move factor PipeEvent out into utils.

    Change-Id: Id3877c66efe22d771cf3ef4877107e431b828e37

commit 17526eb3148c9c3d4365b6d5b47e8dc13bca71b6
Author: John Grossman <johngro@google.com>
Date:   Mon Jun 27 17:06:49 2011 -0700

    Name changes for the TRTP Players s/tungsten/aah/g

    Change-Id: I55e9ad13003f6aa6a36955b54426a7efbe31ac51

commit cbf2903ab6893b6e662514e2f6d670e268a419df
Author: John Grossman <johngro@google.com>
Date:   Fri Apr 15 09:27:54 2011 -0700

    Migrate Tungsten code from the HC-Tungsten to the Master-Tungsten branch.

    Change-Id: I95372d913a0761d90168edb4016f5ece0ea74502

Change-Id: Ic8fd28b1bbd85e86a325f99013e7aa0c763f5f05
Signed-off-by: Mike J. Chen <mjchen@google.com>
Signed-off-by: John Grossman <johngro@google.com>
13 years agoAdd media/libaah_rtp
Mike J. Chen [Mon, 15 Aug 2011 18:26:02 +0000 (11:26 -0700)]
Add media/libaah_rtp

RTP library used to broadcast media from one device to a collection
of listeners.  Handles failures/retries/etc.

This is a squashed merge from master-tungsten of the following changes:

commit e1a5101fe627d71739a7c4263bb3a65c7bc44385
Author: Jason Simmons <jsimmons@google.com>
Date:   Fri Aug 12 13:24:21 2011 -0700

    Hold ThreadWrapper in a ref-counting pointer

    Change-Id: Iaf3343182e37bcc0ca99fbaf8f9bbb8c4984072a

commit 89b90d62e164ff3db27c9cba85255fc476d2dd96
Author: Jason Simmons <jsimmons@google.com>
Date:   Wed Aug 10 13:08:25 2011 -0700

    Update the Tungsten TX player to use HTTPBase

    Change-Id: I9f7ecf1b4b496cec1815284dbcdb958a43284169

commit 43be3231034ff8537fdd84422a7954780038671f
Author: John Grossman <johngro@google.com>
Date:   Mon Jun 27 18:59:12 2011 -0700

    Move libaah_rtp over from the vendor directory.

    Also move factor PipeEvent out into utils.

    Change-Id: Id3877c66efe22d771cf3ef4877107e431b828e37

Change-Id: I190ecddf1dc919761c2e4ec740c2f3b2c9541156
Signed-off-by: Mike J. Chen <mjchen@google.com>
Signed-off-by: John Grossman <johngro@google.com>
Signed-off-by: Jason Simmons <jsimmons@google.com>
13 years agoam 49fb943d: Merge "ATSParser now supports a mode in which PTS is considered to be...
Andreas Huber [Wed, 31 Aug 2011 16:48:07 +0000 (09:48 -0700)]
am 49fb943d: Merge "ATSParser now supports a mode in which PTS is considered to be absolute time"

* commit '49fb943db85c748fc7dd4f5ee4a461d7489fb1b0':
  ATSParser now supports a mode in which PTS is considered to be absolute time

13 years agoMerge "ATSParser now supports a mode in which PTS is considered to be absolute time"
Andreas Huber [Wed, 31 Aug 2011 16:44:57 +0000 (09:44 -0700)]
Merge "ATSParser now supports a mode in which PTS is considered to be absolute time"

13 years agoam c21843a8: Merge "fix Surface positions are not floats"
Mathias Agopian [Wed, 31 Aug 2011 02:25:50 +0000 (19:25 -0700)]
am c21843a8: Merge "fix Surface positions are not floats"

* commit 'c21843a8b5c395cbaae6db0f786bdee556075f5d':
  fix Surface positions are not floats

13 years agoMerge "fix Surface positions are not floats"
Mathias Agopian [Wed, 31 Aug 2011 02:24:04 +0000 (19:24 -0700)]
Merge "fix Surface positions are not floats"

13 years agofix Surface positions are not floats
Mathias Agopian [Wed, 31 Aug 2011 01:51:54 +0000 (18:51 -0700)]
fix Surface positions are not floats

Added Surface.setPosition(float, float) which allows to set a surface's
position in float.

Bug: 5239859
Change-Id: I903aef4ad5b5999142202fb8ea30fe216d805711

13 years agoFix a crash where the EOS was signalled but some output buffer were still pending.
James Dong [Wed, 31 Aug 2011 00:06:10 +0000 (17:06 -0700)]
Fix a crash where the EOS was signalled but some output buffer were still pending.

Change-Id: Ide111264501441b51bb10629ae2021accf9e1fb5
related-to-bug: 5234126

13 years agoATSParser now supports a mode in which PTS is considered to be absolute time
Andreas Huber [Tue, 30 Aug 2011 23:06:28 +0000 (16:06 -0700)]
ATSParser now supports a mode in which PTS is considered to be absolute time

i.e. PTS 0 <=> media time 0

Change-Id: If10a0f98c129b95e8430dc419664b1def92e547e

13 years agoam 0e35c78d: Merge "226483: A2DP connected, but music out to speaker"
Eric Laurent [Tue, 30 Aug 2011 17:53:47 +0000 (10:53 -0700)]
am 0e35c78d: Merge "226483: A2DP connected, but music out to speaker"

* commit '0e35c78d25a8df8b3bde566ad6c474f9df242ea4':
  226483: A2DP connected, but music out to speaker

13 years agoMerge "226483: A2DP connected, but music out to speaker"
Eric Laurent [Tue, 30 Aug 2011 17:51:54 +0000 (10:51 -0700)]
Merge "226483: A2DP connected, but music out to speaker"

13 years agoFix SurfaceMediaSource timestamp handling.
Eino-Ville Talvala [Tue, 30 Aug 2011 01:16:03 +0000 (18:16 -0700)]
Fix SurfaceMediaSource timestamp handling.

Was not basing timestamps on startTimeUs.
Now synchronizes properly with audio.

Bug: 4510826
Change-Id: I613db0aa91e51fc75d120e65540e742d8ab2ae43

13 years ago226483: A2DP connected, but music out to speaker
Eric Laurent [Tue, 30 Aug 2011 17:18:54 +0000 (10:18 -0700)]
226483: A2DP connected, but music out to speaker

When the A2DP headset is connected, there is a possible
race condition when the audio tracks are moved from
the mixer thread attached to the speaker output to the thread
attached to A2DP output.
As the request to clear the stream type to output mapping cache in
the client process is asynchronous, it is possible that the flag
indicating to the client audio track to re-create the IAudioTrack
on the new thread is processed before the cache is invalidated.
In this case, the track will be attached to the old thread and
music will continue playing over the device speaker instead of being
redirected to A2DP headset.

Change-Id: Ib2ce1eb5320eaff83287b93779061bf4e7a330df

13 years agoam c5d0fac0: Merge "Bug 5156756 Fix AAC ADTS header size computation"
Jean-Michel Trivi [Tue, 30 Aug 2011 16:08:02 +0000 (09:08 -0700)]
am c5d0fac0: Merge "Bug 5156756 Fix AAC ADTS header size computation"

* commit 'c5d0fac081c4c496b29586bff79dfff05755b716':
  Bug 5156756 Fix AAC ADTS header size computation

13 years agoMerge "Bug 5156756 Fix AAC ADTS header size computation"
Jean-Michel Trivi [Tue, 30 Aug 2011 16:06:36 +0000 (09:06 -0700)]
Merge "Bug 5156756 Fix AAC ADTS header size computation"

13 years agoBug 5156756 Fix AAC ADTS header size computation
Jean-Michel Trivi [Mon, 29 Aug 2011 21:06:51 +0000 (14:06 -0700)]
Bug 5156756 Fix AAC ADTS header size computation

This previous frame size computation code had two incorrect
 assumptions:
 1/ the ADTS frame length value already contains the header size
 2/ the ADTS header is not of fixed size: it is 2 bytes bigger
  if it contains the CRC value.
For 1/, the code worked because when the header size was added
 to the frame size, the + operator is of stronger precedence
 than the ? operator, so the size added was always 0 (instead
 of ADTS_HEADER_LENGTH.
For 2/, the code worked as long as there was no CRC in the ADTS
 data.

The fix consists in:
 - documenting what the frame length computation code returns
 - fixing the frame length computation
 - when computing the frame length, also returning the header
  size so the correct data can be sent to the decoder.

Change-Id: I92df72a9e531f594f762e63d62f9dee7b0109904

13 years agoresolved conflicts for merge of 35c0bf31 to ics-aah
Jason Simmons [Mon, 29 Aug 2011 23:16:49 +0000 (16:16 -0700)]
resolved conflicts for merge of 35c0bf31 to ics-aah

Change-Id: If736c93821359a2f97a0670ad3be8ada5f398bd7

13 years agoam 499f3658: Merge "Return an error to the client instead of asserting if decoder...
Andreas Huber [Mon, 29 Aug 2011 22:18:26 +0000 (15:18 -0700)]
am 499f3658: Merge "Return an error to the client instead of asserting if decoder instantiation fails"

* commit '499f36581c63579f24c3d9bbf95c7f8677cd1191':
  Return an error to the client instead of asserting if decoder instantiation fails

13 years agoMerge "Audioflinger: reverse logic of BT NREC indication"
Eric Laurent [Mon, 29 Aug 2011 22:12:41 +0000 (15:12 -0700)]
Merge "Audioflinger: reverse logic of BT NREC indication"

13 years agoAudioflinger: reverse logic of BT NREC indication
Eric Laurent [Mon, 29 Aug 2011 19:42:48 +0000 (12:42 -0700)]
Audioflinger: reverse logic of BT NREC indication

The interpretation of BT NREC by AudioFlinger to enable
or disable AEC and NS was wrong: NREC to ON (default) means
the phone (Audio Gateway) must enable local AEC and NS.

Change-Id: I88a264e7fc9831c43bbace4f6b585baec73f2006

13 years agoReturn an error to the client instead of asserting if decoder instantiation fails
Andreas Huber [Mon, 29 Aug 2011 20:01:23 +0000 (13:01 -0700)]
Return an error to the client instead of asserting if decoder instantiation fails

after a surface change.

Change-Id: Ic7758cbeb107032db68a1c3b8e2984710a12dd8b
related-to-bug: 5212725

13 years agoAdd a missing NULL check.
John Grossman [Mon, 29 Aug 2011 17:26:47 +0000 (10:26 -0700)]
Add a missing NULL check.

The get_next_write_timestamp method introduced to the audio HAL is optional.
HALs which do not implement it leave it set to NULL.  Callers (there is
currently only one in the AudioMixer code) need to be certain to check for NULL
before invoking it.

Change-Id: I9e06d688311c388446bb53993291ebc0f98cff89

13 years agoam b3c084af: Merge "Signal errors to the client instead of asserting in ACodec."
Andreas Huber [Mon, 29 Aug 2011 15:13:47 +0000 (08:13 -0700)]
am b3c084af: Merge "Signal errors to the client instead of asserting in ACodec."

* commit 'b3c084af16dfd50c20c10320bf2b1e8d4d0cc5b8':
  Signal errors to the client instead of asserting in ACodec.

13 years agoMerge "Signal errors to the client instead of asserting in ACodec."
Andreas Huber [Mon, 29 Aug 2011 15:10:56 +0000 (08:10 -0700)]
Merge "Signal errors to the client instead of asserting in ACodec."

13 years agoam 3451df1a: Merge "Default W, H allowed in SurfaceMediaSource dequeue"
Pannag Sanketi [Sun, 28 Aug 2011 21:42:33 +0000 (14:42 -0700)]
am 3451df1a: Merge "Default W, H allowed in SurfaceMediaSource dequeue"

* commit '3451df1a5cc1547fe1061a482a50a639fcc0e8e4':
  Default W, H allowed in SurfaceMediaSource dequeue

13 years agoMerge "Default W, H allowed in SurfaceMediaSource dequeue"
Pannag Sanketi [Sun, 28 Aug 2011 21:40:26 +0000 (14:40 -0700)]
Merge "Default W, H allowed in SurfaceMediaSource dequeue"

13 years agoam b8a9e15c: Merge "Modify enum value of OMX_COLOR_FormatAndroidOpaque"
Pannag Sanketi [Sat, 27 Aug 2011 03:08:09 +0000 (20:08 -0700)]
am b8a9e15c: Merge "Modify enum value of OMX_COLOR_FormatAndroidOpaque"

* commit 'b8a9e15c2aa3d317834555244a90f184b46e1dcb':
  Modify enum value of OMX_COLOR_FormatAndroidOpaque

13 years agoMerge "Modify enum value of OMX_COLOR_FormatAndroidOpaque"
Pannag Sanketi [Sat, 27 Aug 2011 03:05:58 +0000 (20:05 -0700)]
Merge "Modify enum value of OMX_COLOR_FormatAndroidOpaque"

13 years agoam 2b9c5d8a: Merge "Fixing small syntax error in MPEG4 logging"
Pannag Sanketi [Sat, 27 Aug 2011 03:03:09 +0000 (20:03 -0700)]
am 2b9c5d8a: Merge "Fixing small syntax error in MPEG4 logging"

* commit '2b9c5d8a89065ab18e58d79ae65a81267b248e1c':
  Fixing small syntax error in MPEG4 logging

13 years agoMerge "Fixing small syntax error in MPEG4 logging"
Pannag Sanketi [Sat, 27 Aug 2011 03:01:46 +0000 (20:01 -0700)]
Merge "Fixing small syntax error in MPEG4 logging"

13 years agoModify enum value of OMX_COLOR_FormatAndroidOpaque
Pannag Sanketi [Sat, 27 Aug 2011 02:34:49 +0000 (19:34 -0700)]
Modify enum value of OMX_COLOR_FormatAndroidOpaque

The enum value chosen earlier had a conflict with one of the vendors.

Change-Id: I47832dd1157447f89324d56e8ab146260cd7927c

13 years agoFixing small syntax error in MPEG4 logging
Pannag Sanketi [Sat, 27 Aug 2011 02:17:20 +0000 (19:17 -0700)]
Fixing small syntax error in MPEG4 logging

Found that the build was breaking when the logging was enabled in
MPEG4Writer. Fixed.

Change-Id: I62c5e6d16b2ecf5644c8d46b9bbcca68a797b223

13 years agoSignal errors to the client instead of asserting in ACodec.
Andreas Huber [Fri, 26 Aug 2011 23:02:19 +0000 (16:02 -0700)]
Signal errors to the client instead of asserting in ACodec.

Also make sure NuPlayer can properly shutdown in certain edge cases.

Change-Id: Iceb16d600d87ba66c802e60e95bf62f66487a453

13 years agoMedia framework changes for Tungsten.
Mike J. Chen [Mon, 15 Aug 2011 20:28:26 +0000 (13:28 -0700)]
Media framework changes for Tungsten.

Squashed merge from master-tungsten of the following changes:

commit 73d09e18c4557e583a1684d44d598a1a02fd0cf2
Author: John Grossman <johngro@google.com>
Date:   Mon Jun 20 13:57:44 2011 -0700

    Remove TungstenMisc and rename LinearTransform

    Change-Id: Ie8aa3e24e09fdbf6ef8996c26deb9c5640e20d1b

commit 3114aabe76ad733b59929d87e49c68229f5ae2e8
Author: John Grossman <johngro@google.com>
Date:   Fri Jun 3 10:47:16 2011 -0700

    Name changes and spelling fixes.

    + Replace the term TungstenTime with the Eugene-approved term CommonTime.
    + Fix a spelling error in a comment I noticed.

    Change-Id: I8c10d618206826d16055f78c7724e24443bb03fd

commit cbf2903ab6893b6e662514e2f6d670e268a419df
Author: John Grossman <johngro@google.com>
Date:   Fri Apr 15 09:27:54 2011 -0700

    Migrate Tungsten code from the HC-Tungsten to the Master-Tungsten branch.

    Change-Id: I95372d913a0761d90168edb4016f5ece0ea74502

commit bc7c46aa629f9883e959ef23de8da297f9eb508b
Author: Jason Simmons <jsimmons@google.com>
Date:   Mon Jun 20 13:59:17 2011 -0700

    Create a separate class for timed AudioTracks

commit 43be3231034ff8537fdd84422a7954780038671f
Author: John Grossman <johngro@google.com>
Date:   Mon Jun 27 18:59:12 2011 -0700

    Move libaah_rtp over from the vendor directory.

    Also move factor PipeEvent out into utils.

    Change-Id: Id3877c66efe22d771cf3ef4877107e431b828e37

commit 17526eb3148c9c3d4365b6d5b47e8dc13bca71b6
Author: John Grossman <johngro@google.com>
Date:   Mon Jun 27 17:06:49 2011 -0700

    Name changes for the TRTP Players s/tungsten/aah/g

    Change-Id: I55e9ad13003f6aa6a36955b54426a7efbe31ac51

commit 423fc1bfc0fda799c421a650c83c4b9293b1a08c
Author: Jason Simmons <jsimmons@google.com>
Date:   Mon Jun 20 17:56:09 2011 -0700

    More timed AudioFlinger changes requested by code review:
    * change trimTimedBufferQueue to trimTimedBufferQueue_l
    * create one timed audio buffer heap per client process instead of one per track
    * grow the silence buffer on demand
    * some error handling fixes in timed getNextBuffer
    * calculate the next output PTS in all mixer and track hooks

    Change-Id: Ifc51a08b55029b7c48902ab2f22933ad7bafe1ad

commit a148e2674b1d3cb73289b82b85c333f0a66824a9
Author: John Grossman <johngro@google.com>
Date:   Mon Jun 20 17:02:24 2011 -0700

    Move the A@H time service into frameworks/base

    Change-Id: I5c570cde70e8931e205516cb33517585804ce841

commit dfa438fa49bdaeeb2ec5fd0d17b30d881608b6b1
Author: John Grossman <johngro@google.com>
Date:   Mon Jun 20 11:55:36 2011 -0700

    Fix the build after Mike's code moving.

    Change-Id: Ia883643ded252168bcc5a70584ab6ce97bb05266

commit 04489474ec8e73efe1bf52918831f41659033162
Author: John Grossman <johngro@google.com>
Date:   Fri Jun 17 14:19:50 2011 -0700

    Refactor the local/common clock services.

    This change is one of a set of 5 changes made to different repositories.  Look
    for this comment in all of them.

    Refactor the local/common clock services in tungsten to match android best
    practice.  Notable changes include

    + The kernel no longer knows anything about common time.  Common time has been
      moved completely up into user land.  This has an impact on the accuracy of the
      timesync debugging code, and the netfilter assisted approach to network based
      timesync is going to have to be modified.
    + The timesync driver used by A@H is now just local time driver.
    + The kernel no longer needs access to the linear transform math code, and it
      has been removed.
    + A new HAL has been introduced to expose the concept of local time to the
      system.
    + A non-slewable stub implementation of the local time HAL based on
      CLOCK_MONOTONIC has been added.
    + The TungstenTime library has been eliminated.  Its functionality has been
      distributed among the common time binder service, the local time hal and the
      linear transform utility code.
    + All clients of the old TungstenTime library have been changed to be clients of
      the binder service, the hal and the utility code.
    + The reset_tt utilities have been removed, they no longer have a purpose in the
      system.
    + more progress has been made in eliminating the word "tungsten" from the code.

    Things left to do include
    + Finish getting rid of tungsten from the time service.
    + Move the time service into the framework; AudioFlinger's new timed mode
      depends on it and the service cannot continue to live in vendor tungsten.

    Change-Id: I999b6cfb4a9d267818a86d747c35eecfc6693101

commit d48194545eed1116a84d81e2fb53315d2b0701a7
Author: Jason Simmons <jsimmons@google.com>
Date:   Thu Jun 16 14:22:46 2011 -0700

    Change the interface of the AudioMixer and AudioBufferProvider to accept a presentation timestamp

    Change-Id: Ice2df5628d45a7f77100e7008103b35b3d3160a4

commit 02561419db82b01ffb28df38000716c612988427
Author: John Grossman <johngro@google.com>
Date:   Tue May 10 14:00:21 2011 -0700

    Put in a hack for controling master volume in the policy manager.
    Fix initial master volume reporting.

    Change-Id: Ia6caf2bbc6083c5f99fab852baa40fff10fc5fc7

commit 549cdc3ba115dc654cdade261fb055c72c6cdb79
Author: John Grossman <johngro@google.com>
Date:   Wed May 4 11:46:17 2011 -0700

    Make certain the logic for computing the output stream mixing point is hardened
    against underflow and overflow when input and output sample rates don't match.

    Change-Id: I5ebea07c9938107b435bec7413418622767e4e16

commit 8043d8ed63f51e76d452d22be7d453d4a7794530
Author: Jason Simmons <jsimmons@google.com>
Date:   Wed Apr 27 18:06:27 2011 -0700

    Add the patch for timed audio support to the mono resampler

    Change-Id: I526f34ae9d1e8e3b0ed2fb05af3d024d5c5fe711

commit 2be89486ef23f0b0b0cc2dc25a4c0ee691043f00
Author: John Grossman <johngro@google.com>
Date:   Wed Apr 27 10:38:57 2011 -0700

    Extend the AudioHWInterface to allow it to specify the initial master volume used by AudioFlinger.

    Change-Id: I8823330801c927494cf7ca31a6b8f9264fbfbb26

commit ff89a4d5e37e6a05a2b03f79ab4e97833dd66393
Author: John Grossman <johngro@google.com>
Date:   Wed Apr 27 09:07:14 2011 -0700

    Fix an issue with inconsistent volume reporting.

    Changed masterVolume() to return the same value as the last call
    to setMasterVolume when the HW layer is implementing master
    volume control.  The masterVolume/setMasterVolume API seems to be
    an idea which was abandonded a long time ago; as of today the
    system only ever sets it to 1.0 at startup and then never changes
    it.  Until we can figure out how the concept of external
    amplifier gain control fits into the Android audio framework,
    Tungsten is exposing this API via a hack-tastic invoke back door
    in the TungstenRXPlayer and needs the getter/setter results to be
    consistent.

    Change-Id: I2ac730fa8fc9ee28c88f1a8e6f2e493eb5b65544

commit 086511b2d19cceb976747ac23e12b73fc7c28bea
Author: Jason Simmons <jsimmons@google.com>
Date:   Mon Apr 25 16:07:19 2011 -0700

    Add handling of timed audio tracks in the generic resampling mixer

    Change-Id: Ic3be1d21b1117f1b233808be543c28a0dcec4792

Change-Id: Id78bba8c002131d8b52b4170259a87fd94e63c73
Signed-off-by: Mike J. Chen <mjchen@google.com>
Signed-off-by: John Grossman <johngro@google.com>
Signed-off-by: Jason Simmons <jsimmons@google.com>
13 years agoMerge "Support for posting messages and synchronously waiting for a response."
Andreas Huber [Fri, 26 Aug 2011 20:47:26 +0000 (13:47 -0700)]
Merge "Support for posting messages and synchronously waiting for a response."

13 years agoProperly reset the number of frames we think we've written to the audio sink
Andreas Huber [Fri, 26 Aug 2011 18:26:25 +0000 (11:26 -0700)]
Properly reset the number of frames we think we've written to the audio sink

in order to compute the final delay before posting end-of-stream correctly.

Change-Id: I4ff6d7142fdf1ea2d19d12ec78c1e84322d22e5f
related-to-bug: 5216930

13 years agoMerge "Bug 4364249 Play position is 0 after flushing AudioTrack"
Jean-Michel Trivi [Fri, 26 Aug 2011 00:41:46 +0000 (17:41 -0700)]
Merge "Bug 4364249 Play position is 0 after flushing AudioTrack"

13 years agoBug 4364249 Play position is 0 after flushing AudioTrack
Jean-Michel Trivi [Thu, 25 Aug 2011 23:47:23 +0000 (16:47 -0700)]
Bug 4364249 Play position is 0 after flushing AudioTrack

AudioTrack::stop() is not synchronous, so a stop() followed
 by flush(), which is synchronous, will not always report
 a playhead position of 0 after being called.
This CL adds a flag to mark a track as flushed, and report the
 correct playhead position in this state.
Bug 5217011 has been created to address the real issue in the
 future, where flush could be made synchronous, to properly
 address bug 4364249.

Change-Id: Icf989d41a6bcd5985bb87764c287f3edb7e26d12

13 years agoSupport for posting messages and synchronously waiting for a response.
Andreas Huber [Thu, 25 Aug 2011 23:09:06 +0000 (16:09 -0700)]
Support for posting messages and synchronously waiting for a response.

Change-Id: Id6c7a08c34fd5cb6c4632f78ece9e7898b29e52c

13 years agoMerge "When encountering a discontinuity, flush(clear) all content enqueued up to...
Andreas Huber [Thu, 25 Aug 2011 20:40:16 +0000 (13:40 -0700)]
Merge "When encountering a discontinuity, flush(clear) all content enqueued up to that"

13 years agoWhen encountering a discontinuity, flush(clear) all content enqueued up to that
Andreas Huber [Thu, 25 Aug 2011 19:21:26 +0000 (12:21 -0700)]
When encountering a discontinuity, flush(clear) all content enqueued up to that

point except previously enqueued discontinuities.

Change-Id: Id04a559dc062fa4a5c80c599ad74bf81a543de01
related-to-bug: 5201378

13 years agoMerge "Set mSeekNotificationSent as false for RTSP seeking. Fix for bug 5208736."
Gloria Wang [Thu, 25 Aug 2011 17:28:50 +0000 (10:28 -0700)]
Merge "Set mSeekNotificationSent as false for RTSP seeking. Fix for bug 5208736."

13 years agoSet mSeekNotificationSent as false for RTSP seeking.
Gloria Wang [Thu, 25 Aug 2011 17:09:34 +0000 (10:09 -0700)]
Set mSeekNotificationSent as false for RTSP seeking.
Fix for bug 5208736.

Change-Id: Ib1d74608ec289509082d8dcad080769f48098853

13 years agoMerge "When Camera is launched by media recording framework, stagefright controls...
James Dong [Thu, 25 Aug 2011 15:12:11 +0000 (08:12 -0700)]
Merge "When Camera is launched by media recording framework, stagefright controls the stop and release."

13 years agoWhen Camera is launched by media recording framework, stagefright controls the stop...
James Dong [Thu, 25 Aug 2011 02:50:36 +0000 (19:50 -0700)]
When Camera is launched by media recording framework, stagefright controls the stop and release.

Change-Id: Ic79a60dad0f617a845211d3fbe146c1648a71da3
related-to-bug: 5205804

13 years agoMerge "Port setting change should happen before receiving any filled frame."
Chih-Chung Chang [Thu, 25 Aug 2011 01:57:35 +0000 (18:57 -0700)]
Merge "Port setting change should happen before receiving any filled frame."

13 years agoDefault W, H allowed in SurfaceMediaSource dequeue
Pannag Sanketi [Thu, 25 Aug 2011 00:39:09 +0000 (17:39 -0700)]
Default W, H allowed in SurfaceMediaSource dequeue

The client does not have to send (w, h) = (0,0) in dequeuebuffer. It can
set the same w, h as the default width and height.

Change-Id: I8202f90261ccaebbd35ea28c153a7472f01912f1

13 years agoMerge "Testing the GL/ CPU encoding w/ Gralloc buffers"
Pannag Sanketi [Wed, 24 Aug 2011 22:18:07 +0000 (15:18 -0700)]
Merge "Testing the GL/ CPU encoding w/ Gralloc buffers"

13 years agoTesting the GL/ CPU encoding w/ Gralloc buffers
Pannag Sanketi [Fri, 19 Aug 2011 04:53:02 +0000 (21:53 -0700)]
Testing the GL/ CPU encoding w/ Gralloc buffers

This is the test for Gralloc buffers based encoding.
contains a combination of two main changes:

1. GL based encoding tests added to SurfaceMediaSource_test

2. SurfaceMediaSource ::read() colorformat

The SurfaceMediaSource::getformat() sets it to OMX_COLOR_FormatAndroidOpaque.
The omx encoder needs to interpret that colorformat and reads the format
from the Gralloc buffers directly

Change-Id: Iee2fe8901384109a4952e1d6c528c59eb01eb5b1

13 years agoMerge "To make SniffMP3() more concrete so that we can remove false-positve responses...
James Dong [Wed, 24 Aug 2011 01:06:16 +0000 (18:06 -0700)]
Merge "To make SniffMP3() more concrete so that we can remove false-positve responses from MPEG-PS streams."

13 years agoMerge "We were accidentally sending out an output buffer before the final port settin...
Andreas Huber [Tue, 23 Aug 2011 17:32:35 +0000 (10:32 -0700)]
Merge "We were accidentally sending out an output buffer before the final port settings change"

13 years agoWe were accidentally sending out an output buffer before the final port settings...
Andreas Huber [Tue, 23 Aug 2011 17:21:34 +0000 (10:21 -0700)]
We were accidentally sending out an output buffer before the final port settings change

Change-Id: I4de0d3c377bb12e59524ed370ab3ed0b9a9b70a6
related-to-bug: 5122512

13 years agoMerge "AudioFlinger: add check for audio HAL init failure"
Eric Laurent [Tue, 23 Aug 2011 15:42:59 +0000 (08:42 -0700)]
Merge "AudioFlinger: add check for audio HAL init failure"

13 years agoAudioFlinger: add check for audio HAL init failure
Eric Laurent [Tue, 23 Aug 2011 15:25:03 +0000 (08:25 -0700)]
AudioFlinger: add check for audio HAL init failure

Do not call audio HAL functions on the primary HW interface
if it could not be initialized properly.

Change-Id: If54059c8fd188d6c1686f9e0439994fe9411478a

13 years agoPort setting change should happen before receiving any filled frame.
Chih-Chung Chang [Mon, 22 Aug 2011 12:11:31 +0000 (20:11 +0800)]
Port setting change should happen before receiving any filled frame.

Change-Id: I12a54b80e7ef958b6d451b7add110d38f05ec439

13 years agoThe MatroskaExtractor will now publish a different mime-type "video/webm" if
Andreas Huber [Mon, 22 Aug 2011 20:21:26 +0000 (13:21 -0700)]
The MatroskaExtractor will now publish a different mime-type "video/webm" if

the doctype of the matroska file indicates that it is a webm file.

Change-Id: I467f597690a841043ecd11d2a2cae93351820f1b
related-to-bug: 5042137

13 years agoMerge "Remove useAndroidNativeBuffer(2) warning message."
Chih-Chung Chang [Mon, 22 Aug 2011 02:19:01 +0000 (19:19 -0700)]
Merge "Remove useAndroidNativeBuffer(2) warning message."

13 years agoMerge "Fix for 4142219 Don't hard code platform-specific limitations (Jni/ Java)"
Rajneesh Chowdury [Fri, 19 Aug 2011 22:01:11 +0000 (15:01 -0700)]
Merge "Fix for 4142219 Don't hard code platform-specific limitations (Jni/ Java)"

13 years agoMerge "Stagefright: fix a compiler warning"
Jamie Gennis [Fri, 19 Aug 2011 21:36:10 +0000 (14:36 -0700)]
Merge "Stagefright: fix a compiler warning"

13 years agoFix for 4142219 Don't hard code platform-specific limitations (Jni/ Java)
Rajneesh Chowdury [Fri, 12 Aug 2011 23:43:37 +0000 (16:43 -0700)]
Fix for 4142219 Don't hard code platform-specific limitations (Jni/ Java)

Also fixes 5118207 add other video codec support for video editor export.

Change-Id: If72427173bd8ff684af07ba00f4425c1deef29c6

13 years agoRaise the maximum input buffer size for the vpx video decoder to 256KB
Andreas Huber [Fri, 19 Aug 2011 17:30:58 +0000 (10:30 -0700)]
Raise the maximum input buffer size for the vpx video decoder to 256KB

Change-Id: I0411763829bf186d1b3b679fa72c9051524506b4
related-to-bug: 5169641

13 years agoMerge "When switching surface, do not set mSeekNotificationSent as true, because...
Gloria Wang [Thu, 18 Aug 2011 22:14:36 +0000 (15:14 -0700)]
Merge "When switching surface, do not set mSeekNotificationSent as true, because there could be a previous uncompleted seeking which needs to send back MEDIA_SEEK_COMPLETE message. If we set mSeekNotificationSent as true here, then mediaplayer.cpp will be waiting for message MEDIA_SEEK_COMPLETE. The getCurrentPosition() will always return the seek time before MEDIA_SEEK_COMPLETE being received by mediaplayer.cpp. Fix for bug 5181272."

13 years agoWhen switching surface, do not set mSeekNotificationSent as true,
Gloria Wang [Thu, 18 Aug 2011 21:52:36 +0000 (14:52 -0700)]
When switching surface, do not set mSeekNotificationSent as true,
because there could be a previous uncompleted seeking which needs
to send back MEDIA_SEEK_COMPLETE message. If we set mSeekNotificationSent
as true here, then mediaplayer.cpp will be waiting for message
MEDIA_SEEK_COMPLETE. The getCurrentPosition() will always return
the seek time before MEDIA_SEEK_COMPLETE being received by mediaplayer.cpp.
Fix for bug 5181272.

Change-Id: I290aff29b6d9ec8db67c66abbe1f352a43f57073

13 years agoMerge "Some decoders require more gentle treatment"
Andreas Huber [Thu, 18 Aug 2011 18:46:18 +0000 (11:46 -0700)]
Merge "Some decoders require more gentle treatment"

13 years agoSome decoders require more gentle treatment
James Dong [Fri, 12 Aug 2011 00:38:35 +0000 (17:38 -0700)]
Some decoders require more gentle treatment

We sacrifice A/V sync to some extent to enable the decoder to recover from
temporary bottlenecks.

Change-Id: I16195091ad752bfad4c70869cdd7e9f28ca3a118
related-to-bug: 5180142

13 years agoDisable vorbis-auto-looping if the audio sink used is not realtime, i.e. recording.
Andreas Huber [Thu, 18 Aug 2011 17:53:23 +0000 (10:53 -0700)]
Disable vorbis-auto-looping if the audio sink used is not realtime, i.e. recording.

Change-Id: I982e740e8488ff8717ca5f081db9def55aabc9ec
related-to-bug: 5179033

13 years agoRemove useAndroidNativeBuffer(2) warning message.
Chih-Chung Chang [Thu, 18 Aug 2011 08:56:36 +0000 (16:56 +0800)]
Remove useAndroidNativeBuffer(2) warning message.

Change-Id: I3e9765e7271d80fda302e521501720bf8c13e5c7

13 years agoTo make SniffMP3() more concrete so that we can remove false-positve responses from...
Dongwon Kang [Thu, 18 Aug 2011 06:24:27 +0000 (15:24 +0900)]
To make SniffMP3() more concrete so that we can remove false-positve responses from MPEG-PS streams.

Note: current resync logic keeps searching mp3 frames until it meets a
valid one. This resync logic works well with seek() operation, but in
SniffMP3(), this may cause false-positive classification for the
following MPEG-PS file format.
  A possible MPEG-PS video file:
      [PS header]...[mp3 frame][mp3 frame] ...
  MP3 files:
      [ID3 tag][mp3 frame][mp3 frame] ...

BUG: 5104562
Change-Id: Idd5020723f7bdb2fefc2a63fc8651580fd644399

13 years agoMerge "Add new camera focus mode FOCUS_MODE_CONTINUOUS_PICTURE."
Wu-cheng Li [Thu, 18 Aug 2011 05:24:53 +0000 (22:24 -0700)]
Merge "Add new camera focus mode FOCUS_MODE_CONTINUOUS_PICTURE."

13 years agoMerge "Make sure we have all the sample table metadata before declaring a track valid."
Andreas Huber [Wed, 17 Aug 2011 20:21:40 +0000 (13:21 -0700)]
Merge "Make sure we have all the sample table metadata before declaring a track valid."

13 years agoMake sure we have all the sample table metadata before declaring a track valid.
Andreas Huber [Wed, 17 Aug 2011 20:03:51 +0000 (13:03 -0700)]
Make sure we have all the sample table metadata before declaring a track valid.

Change-Id: I2dfbc3e6017b5cd264e4cccfa47d19047b2e7f31
related-to-bug: 5178976

13 years agoMerge "Don't time out prematurely for video encoding waiting for output buffers"
James Dong [Wed, 17 Aug 2011 18:14:49 +0000 (11:14 -0700)]
Merge "Don't time out prematurely for video encoding waiting for output buffers"

13 years agoAdd new camera focus mode FOCUS_MODE_CONTINUOUS_PICTURE.
Wu-cheng Li [Tue, 16 Aug 2011 13:14:16 +0000 (21:14 +0800)]
Add new camera focus mode FOCUS_MODE_CONTINUOUS_PICTURE.

The API is still hidden.

bug:5086125
Change-Id: I69268a95ad6aae249771d3a8dfb423ffe2d87081

13 years agoMerge "Testing for bug 5122864 libwebcore related libraries increased by 3MB in ICS...
Kristian Monsen [Wed, 17 Aug 2011 09:41:00 +0000 (02:41 -0700)]
Merge "Testing for bug 5122864 libwebcore related libraries increased by 3MB in ICS vs HCMR2"

13 years agoMerge "Error handling in ACodec and Nuplayer."
Andreas Huber [Tue, 16 Aug 2011 21:37:51 +0000 (14:37 -0700)]
Merge "Error handling in ACodec and Nuplayer."

13 years agoError handling in ACodec and Nuplayer.
Andreas Huber [Tue, 16 Aug 2011 20:48:44 +0000 (13:48 -0700)]
Error handling in ACodec and Nuplayer.

Codec errors (and codec not found errors) now trigger a controlled shutdown
of playback and signal errors to the MediaPlayer client.

Change-Id: I2ee23ff2a1422d05a1a21e50ecb87d7c7ab958cc

13 years agoProperly initialize some instance variables.
Andreas Huber [Tue, 16 Aug 2011 19:41:41 +0000 (12:41 -0700)]
Properly initialize some instance variables.

Change-Id: I190b889be343dca14fe8109528be14cc3cdd4c34

13 years agoDon't time out prematurely for video encoding waiting for output buffers
James Dong [Sun, 14 Aug 2011 23:14:12 +0000 (16:14 -0700)]
Don't time out prematurely for video encoding waiting for output buffers

o For timelapse video encoding, the timelapse between two neighoring
  input frames could be very long

Change-Id: I2b6f9c392f2237deae71c894efc7fc3692431796
related-to-bug: 5160548

13 years agoTesting for bug 5122864 libwebcore related libraries increased by 3MB in ICS vs HCMR2
Kristian Monsen [Tue, 16 Aug 2011 15:31:05 +0000 (16:31 +0100)]
Testing for bug 5122864 libwebcore related libraries increased by 3MB in ICS vs HCMR2

Reenabling chromium as a shread lib

Change-Id: I5f7abe61624d812c5781c4a453f587e744bc082d

13 years agoIssue 5081351: isWiredHeadsetOn() permission.
Eric Laurent [Wed, 3 Aug 2011 00:41:11 +0000 (17:41 -0700)]
Issue 5081351: isWiredHeadsetOn() permission.

AudioManager.isWiredHeadsetOn() should not require permission MODIFY_AUDIO_SETTINGS.
Remove permission checks on all getters in audio policy manager as permission enforcement
is really usefull for setters.
Also deprecate AudioManager.isWiredHeadsetOn() which name and implementation are deceptive.

Change-Id: I38f8df7c26c0d417bf0e2b74e4c11c2d143f2ecd

13 years agoDon't remove effects on session 0
Marco Nelissen [Fri, 12 Aug 2011 21:14:39 +0000 (14:14 -0700)]
Don't remove effects on session 0

b/5159902
Change-Id: Id6f29fb1c687069f7480dd81d4745a558f202226

13 years agoAdd a null check to handle failure of android::createPlayer
Jason Simmons [Fri, 12 Aug 2011 20:46:55 +0000 (13:46 -0700)]
Add a null check to handle failure of android::createPlayer

Change-Id: Id56bd0c16104e46d8dc71f13d8a44aefe251fad4

13 years agoFix the software AAC decoder's AAC+ detection to ignore malformed frames
Andreas Huber [Fri, 12 Aug 2011 18:38:24 +0000 (11:38 -0700)]
Fix the software AAC decoder's AAC+ detection to ignore malformed frames

at the beginning of the stream.

Change-Id: Ib990848c696896e7d43c80dec8119dec35704b74
related-to-bug: 5122512

13 years agoStagefright: fix a compiler warning
Jamie Gennis [Fri, 12 Aug 2011 00:59:24 +0000 (17:59 -0700)]
Stagefright: fix a compiler warning

Change-Id: Ia6b2027dfe80960450156d918bdd7fe1567cafea

13 years agoMerge "Audio effects: track CPU and memory use separately"
Eric Laurent [Thu, 11 Aug 2011 21:40:04 +0000 (14:40 -0700)]
Merge "Audio effects: track CPU and memory use separately"

13 years agoAudio effects: track CPU and memory use separately
Eric Laurent [Wed, 10 Aug 2011 17:37:50 +0000 (10:37 -0700)]
Audio effects: track CPU and memory use separately

Before this change, CPU and memory usage for an audio effect were
registered and checked against the limit by audio policy manager
upon effect instantiation. Even if an effect was not enabled
it would prevent another effect to be created if the CPU load budget
was exceeded, which was too restrictive.

This change adds a method to register/unregister CPU load only when
an effect is enabled or disabled.
It also adds a mechanism to place all effects on the global output mix
in suspend state (disabled) when an effect is enabled on a specific session.
This will allow applications using session effects to have the priority
over others using global effects.

Also fixes some issues with suspend/restore mechanism:
- avoid taking actions when an effect is disconnected and was not enabled.
- do not remove a session from the suspended sessions list when corresponding
effect chain is destroyed.

Change-Id: I5225278aba1ae13d0d0997bfe26a0c9fb46b17d3

13 years agoMerge "Testing for bug 5122864 libwebcore related libraries increased by 3MB in ICS...
Kristian Monsen [Thu, 11 Aug 2011 10:02:29 +0000 (03:02 -0700)]
Merge "Testing for bug 5122864 libwebcore related libraries increased by 3MB in ICS vs HCMR2"

13 years agoMerge "To reduce the bytes need to be buffered before start playing the streaming...
Gloria Wang [Wed, 10 Aug 2011 21:52:36 +0000 (14:52 -0700)]
Merge "To reduce the bytes need to be buffered before start playing the streaming video. We might revert this change if too many spinnings were introduced. For bug 4448008."

13 years agoTo reduce the bytes need to be buffered before start playing the streaming video.
Gloria Wang [Wed, 10 Aug 2011 21:19:05 +0000 (14:19 -0700)]
To reduce the bytes need to be buffered before start playing the streaming video.
We might revert this change if too many spinnings were introduced.
For bug 4448008.

Change-Id: I3248bba9237d71c2bd99feebc9c73f7bd45260de

13 years agoMerge "When using "secure input buffer mode" we instantiate a different OMX component"
Andreas Huber [Wed, 10 Aug 2011 20:03:29 +0000 (13:03 -0700)]
Merge "When using "secure input buffer mode" we instantiate a different OMX component"

13 years agoMerge "Revert "Notify the OMX component that it's going to be used in "secure" mode.""
Andreas Huber [Wed, 10 Aug 2011 20:03:24 +0000 (13:03 -0700)]
Merge "Revert "Notify the OMX component that it's going to be used in "secure" mode.""

13 years agoWhen using "secure input buffer mode" we instantiate a different OMX component
Andreas Huber [Wed, 10 Aug 2011 19:53:59 +0000 (12:53 -0700)]
When using "secure input buffer mode" we instantiate a different OMX component

We form the new component name by appending the suffix ".secure".

Change-Id: I509848b50ae92edb179a941493ca611f923213ec

13 years agoRevert "Notify the OMX component that it's going to be used in "secure" mode."
Andreas Huber [Wed, 10 Aug 2011 19:45:24 +0000 (12:45 -0700)]
Revert "Notify the OMX component that it's going to be used in "secure" mode."

This reverts commit 7616178271e95f009452a21ea45e7225997dc27a.