3011 Commits

Author SHA1 Message Date
Jean-Michel Trivi
fb52139bd8 Unhide SoundPool builder with AudioAttributes
Change-Id: I9ec6ca310a342f72cc1a0de5d93fe650b0ca2125
2014-07-21 16:00:43 -07:00
Jean-Michel Trivi
a8a3f55865 New MediaFormat keys for AAC
Decoder:
    KEY_AAC_DRC_ATTENUATION_FACTOR
    KEY_AAC_DRC_BOOST_FACTOR
    KEY_AAC_DRC_HEAVY_COMPRESSION
    KEY_AAC_DRC_TARGET_REFERENCE_LEVEL
    KEY_AAC_ENCODED_TARGET_LEVEL
    KEY_AAC_MAX_OUTPUT_CHANNEL_COUNT
Encoder:
    KEY_AAC_SBR_MODE

Change-Id: I69abe01add135875446914134d93a58815992e07
2014-07-21 16:47:34 -07:00
RoboErik
edb158f55f Deprecate apis that were replaced by sessions
These classes all have new components in the session APIs.

bug:16218444
Change-Id: Ib64ff0e23503e4c9eb2fd9162a878e1eaba7c4df
2014-07-21 18:26:42 +00:00
Jean-Michel Trivi
122f599bb4 Merge "AudioAttributes for SoundPool" into lmp-dev 2014-07-19 22:40:06 +00:00
Jean-Michel Trivi
55a30c41b6 AudioAttributes for SoundPool
Add support for building a SoundPool instance and specify
 the AudioAttributes.
Remove SRC quality which was never implemented, while leaving
 room for supporting it later through the Builder pattern.
Remove stream types.
Update AudioService's use of SoundPool to the new scheme.

Change-Id: Ie51e4008684e5ba25f9b7368098e4f20266a15c7
2014-07-20 18:12:00 -07:00
Jean-Michel Trivi
e9111d3067 Merge "API for audio session ID generation" into lmp-dev 2014-07-19 22:40:06 +00:00
Jean-Michel Trivi
289cc8e887 API for audio session ID generation
Expose the value used by the framework to generate an audio
 session ID when a value isn't known.
Rename allocateAudioSessionId() to generateAudioSessionId()
 as this operation doesn't "allocate" anything, and there is
 no allocated resource to free after this operation.

Bug 16401631

Change-Id: I7a7bc05b39ea0b024ff225254eb755a9c85a2ad9
2014-07-20 11:25:48 -07:00
Alan Viverette
bfe76f4547 Fix docs build error in MediaFormat
Change-Id: I5faf72efa1a792f9a500eb4abc76d4e4cda5516d
2014-07-21 19:37:17 -07:00
Ji-Hwan Lee
4f9f57cede TIF: Extend multiple TV input per service for HDMI logical devices
Remove ITvInputManager.registerTvInputInfo() and let addTvInputInfo*()
cover the registration.

Bug: 15570939
Change-Id: Ic36701de96696e7fe32fc1faa0d5f6fde53f6666
2014-07-21 17:04:04 +09:00
Jae Seo
a759b111a1 TIF: Add sendAppPrivateCommand()
Added a way to send a private command from the application to the TV
input. This can be used to provide domain-specific features that are
only known between certain TV inputs and their clients.

Change-Id: I7548311a64147b8ff27562ec680b941e2ec10bc0
2014-07-20 19:16:15 -07:00
Jean-Michel Trivi
dfa871620c Merge "Remove obsolete USAGE_NOTIFICATION_TELEPHONY_RINGTONE definition" into lmp-dev 2014-07-18 18:24:25 +00:00
Jean-Michel Trivi
9b9d72fd11 Remove obsolete USAGE_NOTIFICATION_TELEPHONY_RINGTONE definition
Bug 16401631

Change-Id: I522e7c7030a71b528a484d4d8ae517b4b09460bf
2014-07-20 16:53:27 -07:00
Jean-Michel Trivi
3d63a9c7cd Merge "Add AudioAttributes to stream type conversion" into lmp-dev 2014-07-17 17:59:02 +00:00
Jean-Michel Trivi
09818c1550 Add AudioAttributes to stream type conversion
Framework internal conversion for going from an AudioAttributes
 instance to a legacy stream type.

Change-Id: Ic3b7d2cf4aa0ac5255aa5897a25c78c940af9f77
2014-07-18 17:55:00 -07:00
Jean-Michel Trivi
7cdc0b58d6 Merge "Unhide AudioTrack constructor with AudioAttributes, AudioFormat" into lmp-dev 2014-07-18 18:24:25 +00:00
Jean-Michel Trivi
7f6ee760b0 Unhide AudioTrack constructor with AudioAttributes, AudioFormat
Unhide AudioFormat.Builder
Unhide AudioTrack constructor with AudioAttributes, AudioFormat
Unhide the missing two channels that enable a 7.1 configuration

Change-Id: I60899548da1c688ebe561c25212877e0f3eedb34
2014-07-18 17:07:04 -07:00
Jean-Michel Trivi
0daab220b2 Hide AudioManager.startBluetoothScoVirtualCall()
Not intended for public consumption.

Bug 16401631

Change-Id: I299a4719fef57a66a428ccf1902aefaf59d7e064
2014-07-18 16:47:25 -07:00
Jean-Michel Trivi
a3ee6642d8 Unhide Virtualizer.getVirtualizationMode()
Unhide Virtualizer.getVirtualizationMode() method.
Added note in javadoc about the returned value.
Declared exceptions that can be thrown by the checkStatus(int)
  helper function.

Change-Id: I4da82d1db1e39ca9dae489559bf1fb5de112c26a
2014-07-18 21:34:39 +00:00
Jean-Michel Trivi
89435ce612 Merge "Rename USAGE_NOTIFICATION_TELEPHONY_RINGTONE" into lmp-dev 2014-07-17 17:59:02 +00:00
Jean-Michel Trivi
89c3b29a9b Rename USAGE_NOTIFICATION_TELEPHONY_RINGTONE
AudioAttributes: rename USAGE_NOTIFICATION_TELEPHONY_RINGTONE to
  USAGE_NOTIFICATION_RINGTONE in the list of usage values.
Temporarily keep the old definition to prevent transient build
  breakages, will be removed after telephony packages have been
  updated.

Bug 16401631

Change-Id: I9398443fd7ba3c30e9d371c5c5a2934b9ea6f30a
2014-07-20 20:58:47 +00:00
Wonsik Kim
7f4342e5b8 audio: fix too early connection to HdmiControlService
Connect to HdmiControlService on systemReady(), not on constructor.

Change-Id: Ic91467f040fbffa48393e876997bd320ae9500db
2014-07-20 22:13:54 +00:00
Wonsik Kim
61acf46d6a Merge "TIF: revise API names" into lmp-dev 2014-07-17 21:07:39 +00:00
Sungsoo Lim
9bf671f8ee TIF: revise API names
- TvInputManager: TvInputCallback -> TvInputListenter
- TvParentalControlManager: ParentalControlCallback -> ParentalControlListener
- TvView: unblockContent -> requestUnblockContent

Change-Id: I58220e86a4e59ee7d8f28fab833f09cd603b1e38
2014-07-19 21:22:16 +09:00
Wonsik Kim
6b11ea1ab1 Merge "TIF: Reorder TvInputInfo types from old to new." into lmp-dev 2014-07-17 21:07:39 +00:00
Dongwon Kang
1034df8c63 TIF: Reorder TvInputInfo types from old to new.
This change is internal cleanup change. The purpose of this change is
to reorder the types so that new types can be added at the end of the
type list later.

Change-Id: I377c98dc397ef75c3473ee5133b2ffb49d278a50
2014-07-19 18:48:32 +09:00
Lajos Molnar
b58dc31322 Extend MediaCodecInfo to describe usable codec limits and features
Bug: 11990470
Bug: 12065651
Bug: 16131974
Change-Id: I841b8507e823f1ddf14754e34029a9bed4f402d8
2014-07-19 02:14:00 -07:00
Dongwon Kang
4b662d1b98 TIF: introduce TvInputPassthroughWrapperService class to support 2-way pairing use-case.
This change adds a class which will be used for the TV input which controls an external device
which is connected to the pass-through TV input.

Bug: 15496325
Change-Id: I52d48c45570c2d62d759a9da2ab96ec8461c13f7
2014-07-19 13:36:07 +09:00
Jae Seo
31380e8424 Merge "TIF: Add a way to notify whether the current program content is allowed" into lmp-dev 2014-07-18 18:24:25 +00:00
Jae Seo
bbcd206a79 TIF: Add a way to notify whether the current program content is allowed
Now we have a complete set of API to tell the entire cases (allowed and
blocked), which makes possible for the application to rely more on
actions taken by TV input services transferring the responsibility for
parental control.

Bug: 13172379
Change-Id: I7b0dcf16b870782c76a428a1dac6ef1a528b7d40
2014-07-18 17:13:07 -07:00
Youngsang Cho
6f306e21f4 Merge "TIF: Add unblock content" into lmp-dev 2014-07-17 21:58:28 +00:00
Youngsang Cho
427f74293b Merge "TIF: Add onInputAdded and onInputRemoved" into lmp-dev 2014-07-18 18:24:25 +00:00
Jaewan Kim
903d6b72cd TIF: Add unblock content
When a TV content is blocked by the parental control settings,
TV input service will notify TV to request user's PIN code verification.

If the verification succeeds, TV input service will be notified back
that content is unblocked so it can keep playing the content.

Bug: 13172379
Change-Id: I7b31d762eb54612c4d8779ee133211f32fb73b05
2014-07-18 11:11:38 -07:00
Jaewan Kim
8e6b51b0fb TIF: Add onInputAdded and onInputRemoved
Bug: 16166859
Change-Id: I51bd87aded3e8619e36be200009e924e73cd348e
2014-07-18 15:35:25 +09:00
Wonsik Kim
5b2295a521 Merge "TIF: change onCreateSession() method signature" into lmp-dev 2014-07-17 21:07:39 +00:00
Wonsik Kim
1032f034ff TIF: change onCreateSession() method signature
Bug: 16138420
Change-Id: I73f4992bd76b888c7e5bc6260b3ed849760ee707
2014-07-18 12:00:20 +09:00
Youngsang Cho
2b8aa9903a Merge "TIF: Change the parameter of TvInputInfo.loadLabel/Icon" into lmp-dev 2014-07-17 21:58:28 +00:00
Youngsang Cho
abebf6df87 TIF: Change the parameter of TvInputInfo.loadLabel/Icon
Labels and icons will be extracted from URI in the future.
To acheive it, we need Context rather than PackageManager.

Bug: 16166859
Change-Id: I20f0506fba5876a6cf21b70e44bb3a2265f723d7
2014-07-17 17:49:29 -07:00
Wonsik Kim
61635036ac Merge "TIF: one-to-many relationship for TvInputService to TvInputInfo" into lmp-dev 2014-07-17 21:11:29 +00:00
RoboErik
ca58ddf7c8 Fix crash when calling MediaSession callback
bug:16311395
Change-Id: Ice52d2da63933af881dd95fa8c6f59a6fe27e0df
2014-07-18 01:40:09 +00:00
Wonsik Kim
187423c0bc TIF: one-to-many relationship for TvInputService to TvInputInfo
The scope of this change is to provide a skeleton code for supporting
multiple TV input per service.

Bug: 16138420
Change-Id: Ic51355902d5e0424b8fc8a75c495d4781a7ed744
2014-07-18 09:38:59 +09:00
Youngsang Cho
cdc4e42265 Merge "TIF: Hide TvContract.Channels.COLUMN_BROWSABLE" into lmp-dev 2014-07-17 18:11:21 +00:00
Youngsang Cho
6440db358c TIF: Hide TvContract.Channels.COLUMN_BROWSABLE
TODO: Remove BROWSABLE in TvContract, TvProvider and TV app.

Bug: 16195951
Change-Id: I20e8e1e2f93e0133eba3694e0c1724d443250e59
2014-07-17 20:27:46 -07:00
Youngsang Cho
c66ca1267c Merge "TIF: Add a notification for surface change from TvView to TvInputService" into lmp-dev 2014-07-17 21:58:28 +00:00
Jae Seo
b375805f3b TIF: Add a method to get TvInputInfo for a given TV input
This is going to be needed by applications to get information about the
inputs that are just added thus not included in the previously retrieved
input list.

Bug: 16166859, Bug: 15838097
Change-Id: Icecd03fcea208a0c4d41caab1eec64e574f40877
2014-07-17 20:25:01 -07:00
Youngsang Cho
e821d711db TIF: Add a notification for surface change from TvView to TvInputService
Bug: 15447352
Change-Id: I3e91609c5eb03be84cc7c88507457b9e74750de8
2014-07-17 17:30:36 -07:00
Jae Seo
5507bd7688 TIF: Add buildInputId()
A recent change mandated that we should provide "input ID" instead of
ComponentName when building URIs for channels/programs while there is no
direct way to get one to use with. This CL added a method to build an ID
from a ComponentName.

Change-Id: Ia7f868cf241bb44ca0d4f689dc15326ce6944468
2014-07-17 20:23:52 -07:00
Michael Wright
c39d47a8e7 Add MediaProjection APIs.
The new MediaProjection infrastructure allows the system to hand out
tokens granting the ability to capture the screen's contents, audio,
etc. at a granular level. It's intended to be used both for screen
casting, via the cast APIs, as well as screen sharing via third party
applications.

The screen sharing case is implemented, but all of audio capturing
is still forthcoming.

Change-Id: I4b24669bed7083e11413c10ed8d6b025f5375316
2014-07-17 14:30:19 -07:00
Jae Seo
54a4634983 Merge "TIF: Add TvParentalControlManager" into lmp-dev 2014-07-17 18:11:21 +00:00
Jae Seo
6057102dbb TIF: Add TvParentalControlManager
Each TV input service is now required to query the system whether the
user is allowed to watch the current program before showing it to the
user if the parental control is turned on, which can be checked by
calling TvParentalControlManager.isEnabled(). Whether the TV input
service should block the content or not is determined by invoking
TvParentalControlManager.isRatingBlocked() with the content rating for
the current program. Then the TvParentalControlManager makes a judgment
based on the user blocked ratings stored in the secure settings and
returns the result. If the rating in question turns out to be blocked,
the TV input service must immediately block the content and call this
method with the content rating of the current program to prompt the PIN
verification screen.

Each TV input service also needs to continuously listen to any changes
made to the parental control settings by registering a
TvParentalControlManager.ParentalControlCallback() to the manager and
immediately reevaluate the current program with the new parental control
settings.

Bug: 13172379
Change-Id: I8e1900d4b8d28c56798986d5c3906bd418ab97ac
2014-07-17 16:29:36 -07:00
John Spurlock
6a6641cc4f getMasterStreamType from MUSIC -> NOTIFICATION
For non-voice-capable devices to follow suit with the new policy.

Bug:15592574
Change-Id: I5de36de5cfe157702bbdf6918df51a98f3f0051a
2014-07-19 16:21:17 -04:00