4230 Commits

Author SHA1 Message Date
Lorenzo Colitti
d6aaec0ce7 am e4a02b61: am b9da16a1: Support IPv6 in HTTP streaming.
* commit 'e4a02b61290fa61955c979cfd1afc17a92bba481':
  Support IPv6 in HTTP streaming.
2011-03-09 15:17:12 -08:00
Lorenzo Colitti
8df2477c4e am bd0e806a: Support IPv6->IPv4 fallback in HTTP streaming.
* commit 'bd0e806a61df9b67890dc3b1390db554e7468b4a':
  Support IPv6->IPv4 fallback in HTTP streaming.
2011-03-09 15:09:20 -08:00
Lorenzo Colitti
e4a02b6129 am b9da16a1: Support IPv6 in HTTP streaming.
* commit 'b9da16a1e36fcf4e38a50adcf10ea59c12dea254':
  Support IPv6 in HTTP streaming.
2011-03-09 15:09:04 -08:00
Andreas Huber
20660eeb4d Support http authentication ala http://foo:bar@host.org in stagefright.
Change-Id: I0b20077ad540ec8aa11adf0ca9f4142ea8b8ae98
2011-03-09 14:47:20 -08:00
Mike Lockwood
b966b9d9e8 MTP: Convert date created and modified values from seconds to milliseconds
BUG: 4026365

Change-Id: Ifd78cca305299ed1cedd6595609d9bf8d520cd8e
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-03-09 17:28:33 -05:00
Andreas Huber
db7dc9cc89 Use the same http proxy mechanism that webkit uses instead of bypassing proxies.
Change-Id: Ifd64664d3052fbfa715c2920984170c2a6190f6b
related-to-bug: 3440271
2011-03-09 13:36:15 -08:00
Eric Laurent
18632db49a am 2dc78477: am cc34967f: Merge "Fix issue 3439872: video chat and bluetooth SCO" into honeycomb-mr1
* commit '2dc78477364bd4accb9a603baaafca9a5523dcec':
  Fix issue 3439872: video chat and bluetooth SCO
2011-03-09 11:00:22 -08:00
Eric Laurent
cc34967fdc Merge "Fix issue 3439872: video chat and bluetooth SCO" into honeycomb-mr1 2011-03-09 10:56:01 -08:00
Andreas Huber
f9f6087915 Merge "An HTTP datasource for stagefright using the chromium code." 2011-03-09 10:37:20 -08:00
Jean-Michel Trivi
0984ba25db am 8d0e2b98: am 5fa7aac8: Merge "Fix bug 4064086 Use a death handler on audio focus changes from mode" into honeycomb-mr1
* commit '8d0e2b9857e5f77ced233dc408a7acd9e8ab2e8c':
  Fix bug 4064086 Use a death handler on audio focus changes from mode
2011-03-09 10:22:56 -08:00
Jean-Michel Trivi
5fa7aac81b Merge "Fix bug 4064086 Use a death handler on audio focus changes from mode" into honeycomb-mr1 2011-03-09 10:18:31 -08:00
Andreas Huber
5f5719e45b An HTTP datasource for stagefright using the chromium code.
Use of this new datasource is now the default unless overwritten by

adb shell setprop media.stagefright.use-chromium false

Change-Id: I156a8eb9a1fff1cb537b4aec6cf3e8e6052be81e
2011-03-09 10:14:46 -08:00
Mike Lockwood
77e1a4c57e am 093cf07f: am 9e8e4ea0: Merge changes Ib517e5e4,I93be7695,I49bf22a4 into honeycomb-mr1
* commit '093cf07f3c58a6553c415d750edba1a75b269f05':
  Close USB dialogs if their corresponding accessory or device has disconnected
  USB: Add API and dialog for apps to request permissions for USB devices and accessories
  UsbService: Automatically use system apps by default if it is the only choice
2011-03-09 03:57:14 -08:00
Mike Lockwood
3a68b8338b USB: Add API and dialog for apps to request permissions for USB devices and accessories
New APIs:

UsbManager.hasPermission returns true if the caller has permission
for the given device or accessory

UsbManager.requestPermission poses a dialog to allow the user to give the caller
permission for the device or accessory.
Result is returned via a PendingIntent.
No dialog is displayed if the caller already has permission.

Also moved UsbResolverActivity to SystemUI package

BUG: 4069037

Change-Id: I93be769501a8776b49ac26e468af19f8fa2114c9
2011-03-08 21:22:19 -05:00
Eric Laurent
421ddc014b Fix issue 3439872: video chat and bluetooth SCO
This change fixes the stability problems experienced when using
a bluetooth headset supporting both A2DP and SCO. Problems occur
when starting the video chat at which time the A2DP output is being
stopped to start SCO. At that time, active AudioTracks are invalidated
by AudioFlinger so that a new AudioTrack binder interface can be
recreated by the client process on the new mixer thread with correct parameters.
The problem was that the process to restore the binder interface was not
protected against concurrent requests which caused 2 binder interfaces
to be created sometimes. This could lead to permanent client deadlock
if one of the client threads was waiting for a condition of the first
created binder interface while the second one was created (as the AudioFlinger
would only signal conditions on the last one created).
This concurrent request situation is more likely to happen when a client
uses the JAVA AudioTrack as the JNI implementation uses simultaneously the
native AudioTrack callback and write push mechanisms. By doing so, the code
that checks if the binder interface should be restored (in obtainBuffer()) is
much more likely to be called concurrently from two different threads.

The fix consists in protecting the critical binder interface restore phase
with a flag in the AudioTrack control block. The first thread acting upon the binder
interface restore request will raise the flag and the second thread will just wait for
a condition to be signaled when the restore process is complete.

Also protected all accesses to the AudioTrack control block by a mutex to prevent
access while the track is being destroyed and restored. If a mutex cannot be held
(e.g because we call a callback function), acquire a strong reference on the IAudioTrack
to prevent its destruction while the cblk is being accessed.

Modified AudioTrack JNI to use GetByteArrayElements() instead of
GetPrimitiveArrayCritical() when writing audio buffers. Entering a critical section would
cause the JNI to abort if a mediaserver crash occurs during a write due to the AudioSystem
callback being called during the critical section when media server process restarts.
Anyway with current JNI implementation, either versions do not copy data most of the times
and the criticial version does not guaranty no data copy.

The same modifications have been made to AudioRecord.

Change-Id: Idc5aa711a04c3eee180cdd03f44fe17f3c4dcb52
2011-03-08 16:33:15 -08:00
Jean-Michel Trivi
382f4e6ea4 Fix bug 4064086 Use a death handler on audio focus changes from mode
Use a death handler when audio focus changes are caused by audio
 mode changes.

The bug comes from the fact that audio focus clients that use the
 audio mode for automatic focus handling didn't register a death
 handler, which was set to null. When such a client died, this
 handler was compared against the one to remove from the
 audio focus stack, which resulted in an NPE.
The fix consists in registering a valid IBinder object in the
 audio focus stack, even for clients whose focus requests originate
 from a change in audio mode, as implemented in the
 handleFocusForCalls() method.

Change-Id: Id9e1d3d10afcd99969285f6d60fc4d7dde1e4a10
2011-03-08 15:12:26 -08:00
Lorenzo Colitti
bd0e806a61 Support IPv6->IPv4 fallback in HTTP streaming.
Bug: 4068057
Change-Id: I425f65a99eb9e0986d9e9c0e264c3c8f61fcfdbd
2011-03-08 15:01:15 -08:00
Lorenzo Colitti
b9da16a1e3 Support IPv6 in HTTP streaming.
Bug: 4068057
Change-Id: I1e141ec99fbfa43722eeb2e4161d56548ffc0640
2011-03-08 15:01:15 -08:00
Mike Lockwood
8b4a4207f6 am bd3d019c: am 823f5bf3: Merge "MTP: Use SharedPreferences for MTP device properties rather than sqlite3" into honeycomb-mr1
* commit 'bd3d019cc66237c23ab0658ff80aa7923e84b239':
  MTP: Use SharedPreferences for MTP device properties rather than sqlite3
2011-03-07 20:08:58 -08:00
Mike Lockwood
823f5bf3db Merge "MTP: Use SharedPreferences for MTP device properties rather than sqlite3" into honeycomb-mr1 2011-03-07 20:04:23 -08:00
Santosh Madhava
165c77b9e4 am 5893b453: am 0e8dc72d: Merge "Fix for issue 3453519: (Java/JNI) do not allow editing of DRM protected contents" into honeycomb-mr1
* commit '5893b453fc762d18e759a391a442600be4924489':
  Fix for issue 3453519: (Java/JNI) do not allow editing of DRM protected contents
2011-03-07 19:47:26 -08:00
Santosh Madhava
0e8dc72db3 Merge "Fix for issue 3453519: (Java/JNI) do not allow editing of DRM protected contents" into honeycomb-mr1 2011-03-07 19:42:16 -08:00
James Dong
2df32f92cf Merge "Add the default back-facing camera to the MediaProfile camera vector As a result, missing media_profiles.xml will be still allowed." 2011-03-07 17:24:02 -08:00
James Dong
d21668768a Add the default back-facing camera to the MediaProfile camera vector
As a result, missing media_profiles.xml will be still allowed.

Change-Id: Ie6c1bbfdfd4e971f1d5d0e031a913e757f3863a7
2011-03-07 17:06:58 -08:00
James Dong
b1be086e1d am d581c047: Add missing copyright headers for a couple of files. DO NOT MERGE Cherry-picked from other branch...
* commit 'd581c04722e2610ca5471b9c3d1881043b1205b1':
  Add missing copyright headers for a couple of files. DO NOT MERGE Cherry-picked from other branch...
2011-03-07 15:10:26 -08:00
James Dong
d581c04722 Add missing copyright headers for a couple of files. DO NOT MERGE
Cherry-picked from other branch...

bug - 4025673

Change-Id: I6fd1baaf5625297fb1e358de3a3a632a7f5deb90
2011-03-07 14:50:40 -08:00
James Dong
6f3489caf2 am a7c9dffd: am 4ed072f9: Merge "Add missing copyright headers to a couple of files" into honeycomb-mr1
* commit 'a7c9dffdb8097105482ce976ba0a51baa76d8806':
  Add missing copyright headers to a couple of files
2011-03-07 14:45:51 -08:00
James Dong
4ed072f904 Merge "Add missing copyright headers to a couple of files" into honeycomb-mr1 2011-03-07 14:41:50 -08:00
James Dong
e2693e5d62 Add missing copyright headers to a couple of files
bug - 4025673

Change-Id: Ie1c4cf18c06032f9b89cc08e5be25d38c0f76aa1
2011-03-07 14:34:05 -08:00
Mike Lockwood
2d5bb293a4 am 1cdb2929: am 11cb5cb9: Merge "MtpClient: Fix problem with getDeviceList() returning empty result in some cases" into honeycomb-mr1
* commit '1cdb2929f368a1ab1c30e89200e585fcb1278492':
  MtpClient: Fix problem with getDeviceList() returning empty result in some cases
2011-03-07 13:36:20 -08:00
Mike Lockwood
2b8a1ee057 MtpClient: Fix problem with getDeviceList() returning empty result in some cases
BUG: 3503128

Change-Id: I2263437d6018848e316ae4096eb07305fc4dc486
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-03-07 14:19:06 -05:00
Andreas Huber
bfa40efc9b Merge "Added more metadata published by the MediaMetaDataRetriever" 2011-03-07 11:03:28 -08:00
Mike Lockwood
775de951a8 MTP: Use SharedPreferences for MTP device properties rather than sqlite3
sqlite3 is overkill for what we are doing here, and more fragile.

BUG: 3512856

Change-Id: I83d86127949d894a3887db3456d91b013060e852
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-03-05 17:34:11 -05:00
Santosh Madhava
895a28e14e Fix for issue 3453519: (Java/JNI) do not allow editing of DRM protected contents
Change-Id: I376483c42b5bed8d2a1765804c2261c18d720a0c
2011-03-04 18:37:51 -08:00
James Dong
6f4d877bbf am 0b7912d3: am 99b86247: Fix a leak from AACEncoder.cpp
* commit '0b7912d32848e123e3356d6452895f734b5dda7e':
  Fix a leak from AACEncoder.cpp
2011-03-04 17:15:53 -08:00
James Dong
99b862476d Fix a leak from AACEncoder.cpp
bug - 3470617

Change-Id: I328e92bc1b2aca72e5856703dae00f957f40bc27
2011-03-04 16:30:37 -08:00
James Dong
f7748f40a6 am 70d7522e: am 865448a0: Merge "Do not enforce the rule in MP3Extractor that all audio frames in an mp3 file must have the same mode" into honeycomb-mr1
* commit '70d7522e9f25f80f528d9737fa67976eacb24afd':
  Do not enforce the rule in MP3Extractor that all audio frames in an mp3 file must have the same mode
2011-03-04 11:42:41 -08:00
James Dong
858b673a35 Do not enforce the rule in MP3Extractor that all audio frames in an mp3 file must have the same mode
For some mp3 files, the mode can be changed from one audio frame to another. Without
the capability to switch modes, the decoded audio may have lots of artifacts.

bug - 3253310

Change-Id: Id57bb1f204642d15e38a800c72214f6794cfaa37
2011-03-04 11:28:50 -08:00
Andreas Huber
c4c38fc1ea Added more metadata published by the MediaMetaDataRetriever
- presence of audio/video content
- video dimensions
- avg. bitrate

Change-Id: Ie6d478a3c2d0bb6bebaea99ac0a20a4c17808934
related-to-bug: 3506316
2011-03-04 10:32:36 -08:00
Andreas Huber
f80e45a60a Reject streaming .mp4 files over http that are not muxed reasonably.
Audio and video samples must be reasonably close by at any given timestamp,
for now we define "reasonably" as "their offsets must not be more than 1MB apart".

related-to-bug: 3509977
Change-Id: I4c3a2a239bf911306833f3b17b73c9e2f76ab901
2011-03-03 14:32:05 -08:00
Ray Chen
a2c322f599 3406494 Gallery photos in nonsensical order
Change-Id: Ic992465a6683179bff280753dcaf9aa6372424e6
2011-03-03 15:04:57 +08:00
Gloria Wang
396f6de660 Merge "- To track the usage of all audio output devices - To track the currently used audio device - The devices are separated as speaker and other audio devices - Provide the collected data to battery application through pullBatteryData()" 2011-03-02 19:51:04 -08:00
Mike Lockwood
37b05d7d61 Merge "MtpClient: remove finalize override to avoid multiple calls to unregisterReceiver" 2011-03-02 17:14:57 -08:00
Mike Lockwood
1bdeef34ef MtpClient: remove finalize override to avoid multiple calls to unregisterReceiver
BUG: 3497801

Change-Id: I4ed0166efcc509a18361287c5816bc4844089025
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-03-02 16:59:53 -08:00
Gloria Wang
9b3f1521b5 - To track the usage of all audio output devices
- To track the currently used audio device
- The devices are separated as speaker and other audio devices
- Provide the collected data to battery application through pullBatteryData()

Change-Id: I374c755266b5ac6b1c6c630400f4daf901ea8acc
2011-03-02 16:53:24 -08:00
Jamie Gennis
28a8cb75e8 Merge "Stagefright: Use the ANW min undequeued bufs query." 2011-03-02 16:44:51 -08:00
Andreas Huber
ce80b0ca33 Merge "Resize internal PES buffers dynamically instead of relying on a fixed maximum size." 2011-03-02 16:22:20 -08:00
Andreas Huber
56e84ba150 Resize internal PES buffers dynamically instead of relying on a fixed maximum size.
Change-Id: Ibe720e6148799e32d039ccdb4b269659bc779952
2011-03-02 16:18:33 -08:00
Andreas Huber
00fa3a729c Merge "Allow optional specification of a PTS timestamp when signalling a discontinuity." 2011-03-02 16:11:01 -08:00
Andreas Huber
669ad13de9 Allow optional specification of a PTS timestamp when signalling a discontinuity.
If present, rendering will be suppressed until reaching the timestamp.

Change-Id: Ic64bdf4225063c5a4d042ea9809960b843a46d19
related-to-bug: 3489454
2011-03-02 15:38:32 -08:00