Commit Graph

7885 Commits

Author SHA1 Message Date
Kyeongkab.Nam
8bbcf8aae5 Add hearingImpaired information to TvTrackInfo
Add TIF API for getting hearing impaired attribute for audio and
subtitle tracks in order for TV App to use it.

Test: build
Bug: 112835103
Change-Id: I4046b5d49fcec2b944972bc532e844f0bdab9476
2020-01-08 17:51:27 +09:00
Treehugger Robot
f04ee52d5a Merge "Add audio description information to TvTrackInfo" 2020-01-08 02:43:24 +00:00
Nick Chalko
f26efab443 Mark DVB methods and classes as System APIs.
Guard with DVB_DEVICE permission.
Add @DvbDeviceType IntDef

Bug: 146385357
Test: m framework
Change-Id: Id6c77049e7338b6503adc12e14264fa4a892a65d
2020-01-02 13:19:43 -08:00
Treehugger Robot
dcb8aa7cba Merge "Refactor AudioPlaybackConfiguration to reduce usages of hidden APIs" 2019-12-23 18:03:35 +00:00
Rahul Sabnis
eeef865a2a Refactor AudioPlaybackConfiguration to reduce usages of hidden APIs
Bug: 141947725
Test: Manual
Change-Id: Ia95776cda3408c321d94494cb25b9cd85cb8662a
2019-12-20 14:48:57 -08:00
Kevin Rocard
3ae06329dc Add OPUS encoding to the framework
Audio offload support was added to AudioTrack in Q,
but only a few encoding were exposed (MP3 & AAC).

This patch adds only Opus support.
For R we probably want to expose all format that the framework supports.

Bug: 146540917
Test: AudioTrackOffloadTest AudioFormatTest
Change-Id: I2ca57d45081668f76f8d9e153f66d1fd41209685
Signed-off-by: Kevin Rocard <krocard@google.com>
2019-12-20 19:30:18 +00:00
Austin Wang
a63a2c0130 Revert "Use new UnsupportedAppUsage annotation."
This reverts commit a5264903e2.

Reason for revert: Droidcop-triggered revert due to breakage https://android-build.googleplex.com/builds/quarterdeck?branch=git_master&target=sdk_phone_armv7-sdk&lkgb=6083299&lkbb=6085371&fkbb=6083313, bug b/146533269

Change-Id: Ie5b031d7b277cf0e09b0a9776b26bf74f5f69e70
2019-12-19 06:38:19 +00:00
Artur Satayev
a5264903e2 Use new UnsupportedAppUsage annotation.
Existing annotations in libcore/ and frameworks/ will deleted after the migration. This also means that any java library that compiles @UnsupportedAppUsage requires a direct dependency on "unsupportedappusage" java_library.

Bug: 145132366
Test: m && diff unsupportedappusage_index.csv \
      git diff HEAD^ HEAD | grep '^[+-][^+-]' | grep -v '.import'
Change-Id: I087bb1cecbe59f1cf0c2e770c735d7a433722c6f
2019-12-18 12:07:36 +00:00
Jaewan Kim
7e8dffc582 Merge changes from topic "msm_callback"
* changes:
  MediaSessionManager: Split abstract class Callback into interfaces
  MediaSessionManager: Use Executor instead of Handler
  Allow to register multiple callbacks in MediaSessionManager
2019-12-17 02:29:33 +00:00
Treehugger Robot
c5480019ce Merge "Use TelephonyManager API to check if device is voice capable." 2019-12-13 23:26:40 +00:00
Michele
72d27bb104 Use TelephonyManager API to check if device is voice capable.
Bug: 146075164
Test: make
Change-Id: I3f19a65012ea355091bbbf22ee3c11054ed19e37
Merged-In: I3f19a65012ea355091bbbf22ee3c11054ed19e37
2019-12-13 14:46:37 +00:00
Kyeongkab.Nam
f6d1e09fd7 TIF: Add TvInputService#onHdmiDeviceUpdated()
Add API to update device infos to TvInputInfo.

Bug: 145047101
Test: Manual
Change-Id: I67438193cc00d3bf76b8ebaa02869b6ff4e04b77
2019-12-13 02:06:12 +00:00
Jaewan Kim
f5ff735fae MediaSessionManager: Split abstract class Callback into interfaces
This CL splits the MediaSessionManager.Callback (abstract class) with
OnMediaKeyEventDispatchedListener and
OnMediaKeyEventSessionChangedListener (interfaces with default methods).

It's to follow the API guideline and also to help the Bluetooth for
minally registering callbacks. (The Bluetooth currently only overrides
onAddressedPlayerChanged)

Bug: 138648566
Test: Build and run
Change-Id: I8607662b00db7fb32cf3f4ee527c52b9fd8a6d7c
2019-12-12 10:23:14 +09:00
Jaewan Kim
c37f70d6fe MediaSessionManager: Use Executor instead of Handler
Bug: 138648566
Test: Build
Change-Id: I89a612cb1408dfb2cc4f624c7e0f8c8a55e0a732
Merged-In: I89a612cb1408dfb2cc4f624c7e0f8c8a55e0a732
(cherry picked from commit 95c783e2d2)
2019-12-12 10:23:06 +09:00
Sungsoo Lim
5fe3d3ae41 Allow to register multiple callbacks in MediaSessionManager
Bug: 126758528
Test: manually
Change-Id: I613593a88c115a5ac694b8c984f3ae36e9cc1c78
Merged-In: I613593a88c115a5ac694b8c984f3ae36e9cc1c78
(cherry picked from commit 14ddf75c47)
2019-12-12 10:22:55 +09:00
Marco Nelissen
b002876a41 Merge "Fix bad javadoc link" 2019-12-06 22:30:15 +00:00
Marco Nelissen
738d5e11ce Fix bad javadoc link
Method link was referring to itself.

Bug: 144964777
Test: build offline-sdk-docs, open doc in browser
Change-Id: Ib373b16d36ee91ebe10f5c6c2a635c65480a48e0
2019-12-06 10:37:31 -08:00
jiabin
955b2132b1 Refactor audio device type in audio frameworks.
As audio device type can not be used as bit mask any more, refactoring
the code to use a set for a combination of audio device type instead.

Bug: 135621476
Test: atest AudioDeviceBrokerTest
Test: audio smoke test
Change-Id: I2c6fabfafcc6eaf607975076d9ee1a78887a2c85
Merged-In: I2c6fabfafcc6eaf607975076d9ee1a78887a2c85
2019-12-05 15:32:44 -08:00
Eric Laurent
a270b7c0e5 AudioService: communicate audio HAL process pids to native audioserver
Retrieve audio HAL processes pids from service manager and send them
to AudioFlinger native service. This is needed to dump audio HAL process tombstones
and because audioserver process does not have the SELinux permission to
list services.

Bug: 141528385
Test: Force watchdog and verify tombstone creation
Change-Id: I3e35b8040779e041b8d8c2e72d1e650d6f8fe818
Merged-In: I3e35b8040779e041b8d8c2e72d1e650d6f8fe818
2019-12-05 12:51:41 -08:00
Robert Horvath
16a5ce0026 Merge "Rename OWNER to OWNERS for media/tv"
am: a4ff2b159f

Change-Id: I6fb78bc065217e79f3425d999ee75e37fe2edc4c
2019-11-18 01:07:48 -08:00
Robert Horvath
e207293928 Merge "Add OWNERS for media TV"
am: 4776c31c22

Change-Id: I218c902b159ed68aa083130287d41fc7806bae5d
2019-11-18 01:05:37 -08:00
Robert Horvath
a4ff2b159f Merge "Rename OWNER to OWNERS for media/tv" 2019-11-18 08:13:40 +00:00
Robert Horvath
4776c31c22 Merge "Add OWNERS for media TV" 2019-11-18 08:10:47 +00:00
Kyeongkab.Nam
916e2747d0 Add audio description information to TvTrackInfo
Add TIF API for getting audio description attribute for audio tracks
in order for TV App to use it.

Test: build
Bug: 112835103
Change-Id: Ie2e0533718d5a814714a6b7209fb993c1c00794d
2019-11-13 11:59:14 +09:00
Robert Horvath
ff389051bf Rename OWNER to OWNERS for media/tv
OWNERS file was misspelled.

Test: n/a
Change-Id: If71bebd6a0a7c7e7242e485fc27da0fdb70a7e96
2019-11-12 15:47:01 +01:00
shubang
8da39947ad Add OWNERS for media TV
Nick is the TLM of media TV.
Adding OWNERS to avoid bugging people from other media teams

Test: n/a
Change-Id: I2c99a7a1ab78c634fc94dfe96b6617b0bde4efdf
Merged-In: I2c99a7a1ab78c634fc94dfe96b6617b0bde4efdf
2019-11-12 15:45:37 +01:00
Artur Satayev
7a565c45b1 Merge "Add @UnsupportedAppUsage annotations for greylist."
am: 423c3a32d6

Change-Id: I5387b4742fdaf67ad3189356f2361f73969b53a8
2019-11-11 09:13:24 -08:00
Artur Satayev
fc46be7dbd Add @UnsupportedAppUsage annotations for greylist.
go/cleanup-greylist-txt

These have already been greylisted, however due to bugs/omissions in the tooling have been kept in go/greylist-txt instead of being annotated in the code.

Bug: 137350495
Test: m

Change-Id: Id6c1f5e403a0e66edb1102ee45f3bf19f244fb09
Merged-In: Id6c1f5e403a0e66edb1102ee45f3bf19f244fb09
2019-11-08 16:17:13 +00:00
Pawin Vongmasa
23b72c725c Merge "MediaCodec: Release lock before calling onFrameRendered()"
am: c03b91a7ef

Change-Id: I362a0153d83363b0c2b419480dcbe01df6976a90
2019-11-08 06:00:38 -08:00
Pawin Vongmasa
5a07fb4e59 MediaCodec: Release lock before calling onFrameRendered()
Test: atest CtsMediaTestCases -- \
--module-arg CtsMediaTestCases:size:small

Bug: 143672592
Change-Id: I4fb55eb8a90913544a793097c977fee539e09776
2019-11-07 15:54:54 -08:00
Xin Li
6f48900f50 DO NOT MERGE - qt-qpr1-dev-plus-aosp-without-vendor@5915889 into stage-aosp-master
Bug: 142003500
Change-Id: If5056a73ede668b0048ca107b686413695e5b3b6
2019-10-30 14:33:01 -07:00
Treehugger Robot
c91c7ab339 Merge "Add OWNERS for media/tv files" 2019-10-29 22:31:08 +00:00
Treehugger Robot
0ac7e561e9 Merge "AudioService: handle errors when reconnecting mixes after server crash" 2019-10-23 16:40:09 +00:00
Jean-Michel Trivi
d497edd979 AudioService: handle errors when reconnecting mixes after server crash
Log errors when reconnecting dynamic policy mixes after an audio
server crash.
  Add IntDef for AudioSystem errors, and conversion to String.
  Add support for notifying an AudioPolicy user that it was
unregistered.

Bug: 133279309
Test: connect DAP, kill audio server, verify no errors reported
Change-Id: I1dbfdac1873ed9c44c20ca9d25bbe01ce9904ee5
Merged-In: I1dbfdac1873ed9c44c20ca9d25bbe01ce9904ee5
2019-10-23 08:22:00 -07:00
Marco Nelissen
eab83b8080 Move MidiDeviceInfo to libamidi, its only user
This removes the libmedia dependency from libamidi, and reduces
overall size.

Test: build
Change-Id: I16b62ef8288bc68a46ae9ac6318efb95fa469e4f
Merged-In: I16b62ef8288bc68a46ae9ac6318efb95fa469e4f
2019-10-23 07:58:56 -07:00
Marco Nelissen
f0ef85669c Move JetPlayer implemention and JNI
The JetPlayer implementation in libmedia was only used by the
JetPlayer JNI code in libandroid_runtime. This change moves
both implementation and JNI to libmedia_jni. This reduces
libandroid_runtime's dependency on libmedia, and results in
a net size reduction of the libraries involved.

Test: atest JetPlayerTest
Change-Id: I028c774fdea167924b064855267254c15f22fddb
Merged-In: I028c774fdea167924b064855267254c15f22fddb
2019-10-17 21:33:07 +00:00
Tobias Thierer
8edd837b79 Track MimeMap moving to libcore.content.type.
Another CL in this topic moves libcore.net.MimeMap to package
libcore.content.type. This CL updates associated references.

Bug: 136256059
Bug: 124232146
Test: Treehugger
Test: CtsMimeMapTestCases
Exempt-From-Owner-Approval: move affecting imports only
Change-Id: I30aac8b28a1740180ea01834a2bb66b61cb255d4
2019-10-04 12:52:38 +00:00
Dmitry Shmidt
567cb2b5cc Merge changes If9068025,I728e5bf9,I9d41169d am: 3b6a00ec3c am: 225b9d90c2
am: 3aadf0a4d9

Change-Id: I739f574365d36af6b37d47f5593b9ca14f26ef47
2019-10-02 15:21:10 -07:00
Nick Chalko
1f3ad554ad Add OWNERS for media/tv files
Change-Id: Ifeaed2ca3f6940541765ef1665aac23db7d358b5
Test: n/a
2019-09-27 14:42:40 -07:00
Dmitry Shmidt
3d23393159 AudioService: Add reporting of Mic Mute on start
Bug: 141192769
Test: Manual

Change-Id: I728e5bf9594622b7b80b640abd0f4938972d77ef
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
2019-09-27 13:33:08 -07:00
Eric Laurent
e07f956e87 Merge "AudioTrack: fix default low power mode selection" into qt-qpr1-dev
am: 38dceceaf2

Change-Id: Iff06ef6996eb8f410432272ea44c6aa118fd2aa0
2019-09-13 12:54:50 -07:00
Eric Laurent
40f7e04f74 AudioTrack: fix default low power mode selection
Fix AudioAttributes flags checking logic in
shouldEnablePowerSaving() to take into account
flags that are compatible with deep buffer.

Bug: 140899988
Test: check that playback with Spotify goes to deep buffer
Change-Id: I492410b7837b15e248d61ec50dbb468e78e04524
2019-09-13 09:23:54 -07:00
Aurimas Liutikas
00be951a08 Add missing nullability annotations.
To prepare for enabling MissingNullability Metalava check this CL
works on adding missing nullability issues that metalava flags if
we tell it to flag new things since API 29.

This is not a complete CL, mostly addresses public api and
toString/equals for @SystemApi

Exempt-From-Owner-Approval: Large scale nullability clean up
Bug: 124515653
Test: make -j checkapi
Merged-In: I109260842cfc25f06e40694997fcbb4afa02c867
Change-Id: I109260842cfc25f06e40694997fcbb4afa02c867
2019-08-30 00:14:44 +00:00
Xin Li
80860803a4 DO NOT MERGE - Merge qt-dev-plus-aosp-without-vendor (5713463) into stage-aosp-master
Bug: 134405016
Change-Id: I303c0268e8e454b0f0f460eb286812a50c9add88
2019-08-14 12:04:06 -07:00
Kyeongkab.Nam
41c9e7092e Merge "Fix a lock issue in AudioPortEventHandler"
am: 0985eea389

Change-Id: If2113f4150e35c7aeb1751181dab8aa2ea05dee4
2019-08-11 18:38:44 -07:00
Treehugger Robot
0985eea389 Merge "Fix a lock issue in AudioPortEventHandler" 2019-08-12 01:22:58 +00:00
Kyeongkab.Nam
6dbaaf2d8a Fix a lock issue in AudioPortEventHandler
It used "this" as a lock object to guard mListeners. but "this" is
pointing to mHandler in handler thread.
This causes the IndexOutOfBoundsException.

bug: 138951761
Test: manual
Change-Id: I826c7c68ecff4fc0d39addd3d56bc989e00848bc
2019-08-09 09:30:44 +09:00
Aurimas Liutikas
fbcbeec03c Merge "Fix broken Javadoc links in frameworks/base"
am: 4a532813df

Change-Id: I5a6152fa6baab86dde980af57b84167b154b44c7
2019-08-04 00:49:17 -07:00
Aurimas Liutikas
92ff83bddc Fix broken Javadoc links in frameworks/base
Test: running metalava with syntax check enabled.
Change-Id: I13ec355b591b0ae3cfb5009794b1ed844d27cba8
2019-08-02 15:40:29 -07:00
Marco Nelissen
292fdc1c93 Remove libexif usage from libmedia_jni.so
Test: manual, connect with MTP and PTP
Change-Id: I33128db25b8aae60df7854c61fc2a3873a1bced9
(cherry picked from commit f7ec16802c)
(cherry picked from commit efb865ace2)
(cherry picked from commit 5954d210d3)
2019-07-08 05:29:38 +00:00