Commit Graph

6863 Commits

Author SHA1 Message Date
Jean-Michel Trivi
1b926e7ece AudioPolicy: fix typos
Test: build
Change-Id: I6f99fcf23d7d154280b86c93892e0d0f9d856702
2018-01-29 16:24:27 -08:00
Jin Seok Park
0719db7681 Update MediaControlView2/Provider
This CL does the following 5 things:

1) REMOVE setPrevNextListener API
2) REMOVE show/hideSubtitle API
3) EXPOSE Command related strings as public
4) CHANGE time parameter in show(timeout) from integer to long
5) CHANGE setButtonVisibility(visible) parameter from boolean to int

All changes are based on API review.

Test: build
Change-Id: Ia6ffb454100be6a2f75a145e9d6a87bd88faac0c
2018-01-29 22:53:09 +00:00
TreeHugger Robot
4705e590a1 Merge "MediaPlayer2: allow multiple EventCallback's" 2018-01-29 22:22:30 +00:00
Jean-Michel Trivi
975f900f22 Merge "Add support for external volume handler of volume adjustements" 2018-01-29 21:58:51 +00:00
Wei Jia
63f793f0f3 MediaPlayer2: allow multiple EventCallback's
Test: MediaPlayer2 plays
Bug: 63934228
Change-Id: Ie1be29c10d73126d9ebdad8358110ba507a034d5
2018-01-29 11:20:03 -08:00
Jean-Michel Trivi
610aa9b416 Add support for external volume handler of volume adjustements
For devices that use the config_handleVolumeKeysInWindowManager
  configuration, add API to receive volume key-related events
  directly, without them being processed by the framework
  (already not received by apps).

Bug: b/63906162
Test: set config_handleVolumeKeysInWindowManager, use
    "adb shell dumpsys audio" to verify adjustVolume methods aren't
    logged

Change-Id: I432b14fa9980764d69077b9f1b23b8c95f30814d
2018-01-29 09:39:10 -08:00
Hyundo Moon
15fe634246 MediaSession2/Controller2: Add playlist support
This CL does the following:
 - Removes PlaylistParams argument from all playlist related methods.
   (i.e. setPlaylist(List, PlaylistParams) becomes setPlaylist(List))
 - Adds methods (to/fromBundle, to/fromBundleList) into MediaItem2.

Bug: 72537268
Test: Passed MediaSession2Test
Change-Id: I48ef69ad2728fb7de7efab10f4e077aec552dd0b
2018-01-29 22:51:56 +09:00
Jaewan Kim
44fec2d66c MediaSession2: Simplify constructor of SessionToken2
Test: Run all MediaComponents tests once
Change-Id: Ic99d5916d354815a57fe37d04dfeb625c493076d
2018-01-29 22:43:13 +09:00
Jaewan Kim
c599ba36e3 MediaSession2: Move binder interfaces into the updatable
Test: Run all MediaComponents tests once
Change-Id: I29a7aa9d649ea212ad4728ebabff40ec0d47ecb1
2018-01-29 22:43:06 +09:00
Jaewan Kim
6d959eaaf0 MediaSession2: Move MediaItem2 to updatable
Bug: 72627815
Test: Run all MediaComponents test once
Change-Id: Iced94541233145b928e480f3d062a64cc0814a26
2018-01-29 22:43:02 +09:00
Jaewan Kim
a70b3e570c MediaSession2: Implements sendCustomCommand()
Bug: 72543316
Test: Run all MediaComponents tests once
Change-Id: Iad4fff6d6d41fb39f632735244cc7ecbec93fa0f
2018-01-29 22:42:43 +09:00
TreeHugger Robot
650fa8579e Merge "MediaController2: Implement get/setPlaylistParams" 2018-01-29 09:53:07 +00:00
Hyundo Moon
f6a39e4906 MediaController2: Implement get/setPlaylistParams
Bug: 72537520
Test: Passed MediaController2Test
Change-Id: If9b3107084f3f4b063967f079bf229bb43b95cbd
2018-01-29 16:45:02 +09:00
TreeHugger Robot
00715bc435 Merge changes from topic "session2_playlist_add_remove"
* changes:
  MediaSession2: Add listeners for change in session token
  MediaSession2: Add from add/remove an item from playlist
2018-01-29 07:16:34 +00:00
Insun Kang
7933daec0a Merge "VideoView2: Adds Executor paramter to setFooListener methods" 2018-01-29 05:10:12 +00:00
Insun Kang
620b7f328f VideoView2: Adds Executor paramter to setFooListener methods
- Added Executor parameter to setFooListeners
- Removed setFullScreen()
- Renamed OnFullScreenChangedListener --> OnFullScreenRequestListener

Test: build
Change-Id: I1822876ecf55566182281a76ea7919d7c0112146
2018-01-29 04:00:23 +00:00
Jaewan Kim
379e30d90d MediaSession2: Add listeners for change in session token
Test: Run all MediaComponents tests once
Change-Id: Ic46ad9e4e4c9e1ce43b3dbad904eae7fc30d52a0
2018-01-29 11:57:04 +09:00
Sungsoo Lim
d58f145726 VideoView2: MediaRouter integration with MediaSession
Bug: 72526814
Test: build
Change-Id: Iace25522b433152022bdd3458b6791a89618464b
2018-01-29 11:15:40 +09:00
Jaewan Kim
543566fed3 MediaSession2: Add from add/remove an item from playlist
Bug: 72527248, Bug: 72527150
Test: Run all MediaComponents test once
Change-Id: Ie75e1a7fa3cd3bea786445aab827afc62cf189b5
2018-01-28 23:32:26 +09:00
jiabin
589f6a299e Support query active microphones in MediaRecorder.
This is part of device enumeration. With the new add API, developer
could get the active microphones information for each channel.

Bug: 64038649
Test: Run cts and check the print log.
Change-Id: I6de3339add858cb1f6b7f948995bd013570d4260
2018-01-26 17:53:43 -08:00
jiabin
23675f6c79 Support query active microphones information in AudioRecord.
This is part of device enumeration. With the new add API, developer
could get the active microphones information for each channel.

Bug: 64038649
Test: Run cts and check the print log.
Change-Id: I8dd77d0bf3024d5ecb552e099c313fb62f1fda54
2018-01-26 17:47:03 -08:00
jiabin
c0f4944038 Add support for getting all available microphones characteristics.
Add MicrophoneInfo to represent the microphone characteristics which
including location, orientation, frequency response, sensitivity,
channel mapping and other useful information.
Add a new API in AudioManager to query all current available
microphones.

Bug: 64038649
Test: Run test and check the print log.
Change-Id: Ie0dbfeeb84b88db426518b93c7bb83c8913bca85
2018-01-26 17:16:45 -08:00
Previr Rangroo
58822bec4e Add audio presentation interface to Java API
In order to enable applications to query audio sub-selection
information of one audio programme delivered by Next Generation Audio
streams, implement presentation API in MediaExtractor.

Bug: 63901775
Test: make
Change-Id: I2b0bfc5d1089614aa93d58fec99324d7a0ed464b
Signed-off-by: Previr Rangroo <prang@dolby.com>
2018-01-26 15:49:57 -08:00
Jaewan Kim
6a13e1b483 MediaSession2: Initial commit of SessionPlayer2
Bug: 72537268, 72527248
Test: Run MediaComponents test once
Change-Id: I6d8239bbf90ca34b0a8a0d3d0270a06999bb3fe8
2018-01-27 03:39:51 +09:00
Jeff Tinker
1bfb3d2160 Add new secure stop methods
Methods are needed to release a secure stop by ID and
return a list of secure stops.

Test: gts media tests

bug:67361434
bug:64001680
Change-Id: Id35fb082175a0b152e7a6032b147f1d3b221719b
2018-01-26 10:39:17 -08:00
Insun Kang
ecdf034b87 MediaSession2 API set for audio focus handling
MediaPlayerInterface has:
- setAudioAttributes
- getAudioAttributes

MediaSession2 has:
- setAudioFocusRequest

Test: build
Bug: 72529899
Change-Id: I3b200198bc44c568d3c06583c23d9918c6380e32
2018-01-27 03:17:32 +09:00
Jaewan Kim
0d61a00cf5 MediaSession2: Add/remove playback listeners
Test: Run all MediaComponents test once
Change-Id: If88fa492d40f9d202e8bdfcebd06cd9b82554041
2018-01-27 03:17:32 +09:00
Jaewan Kim
f7a7706d14 MediaSession2: Fix timing issue
Session/Controller needs mProvider. However, if the createProvider()
interacts with other components, than other components may use session
/controller object before mProvider is set.

This CL prevents such issues by calling initialize() to communicate
with other components after the provider is set.

Test: Run all MediaComponents test once
Change-Id: I7f4c52136038a0522471015344881552b678a2ab
2018-01-27 03:17:32 +09:00
Insun Kang
0d2f3a4ab7 Merge "Revert "MediaSession2 API set for audio focus handling"" 2018-01-26 16:31:31 +00:00
Insun Kang
8b8dc9a114 Revert "MediaSession2 API set for audio focus handling"
This reverts commit b4689ed97f.

Reason for revert: <INSERT REASONING HERE>

Change-Id: I76f1318941466c10fe08a49a87e4d529aa96391a
2018-01-26 16:28:40 +00:00
Jaewan Kim
81fc632569 Merge "MediaSession2 API set for audio focus handling" 2018-01-26 15:18:10 +00:00
Jaewan Kim
b228cc67cc Merge "MediaSession2: Add playlist parameter supports" 2018-01-26 15:09:31 +00:00
Hyundo Moon
80652ddb91 Merge "MediaSession2: Complete transport control commands" 2018-01-26 14:48:11 +00:00
Hyundo Moon
661433de8f MediaSession2: Add playlist parameter supports
This CL adds following APIs:
 - MediaPlayerInterface.set/getPlaylistParams()
 - MediaSession2.set/getPlaylistParams()
 - MediaController2.setPlaylistParams()
 - ControllerCallback.onPlaylistParamsChanged()

Bug: 72537520
Test: Passed MediaSession2Test
Change-Id: I84ea00ee0876725af1c0e01ad50da15fdb222418
2018-01-26 23:39:33 +09:00
Insun Kang
b4689ed97f MediaSession2 API set for audio focus handling
MediaPlayerInterface has:
- setAudioAttributes
- getAudioAttributes

MediaSession2 has:
- setAudioFocusRequest

Test: build
Bug: 72529899
Change-Id: I64b0238791f25bfd07138686166521a76bc36230
2018-01-26 23:33:15 +09:00
Insun Kang
0a16f268f5 VideoView2/MediaControlView2: Remove overriden onKeyDown/dispatchKeyEvent
Test: build
Change-Id: I4f3a397001e771eac1d1f0208d4e2f262c76b44c
2018-01-26 19:32:34 +09:00
Hyundo Moon
150cca8777 Merge "Add fromBundle/toBundle to PlaybackState2/PlaylistParams" 2018-01-26 09:44:47 +00:00
Hyundo Moon
6cb0712c53 Merge "VideoView2: Add custom actions API" 2018-01-26 09:42:02 +00:00
Hyundo Moon
78600c1a86 MediaSession2: Complete transport control commands
Bug: 72531854
Test: Builds successfully
Change-Id: I1d52580bd9c95e08561905aba19205caee649de1
2018-01-26 16:36:23 +09:00
Hyundo Moon
5b2e35ad09 Add fromBundle/toBundle to PlaybackState2/PlaylistParams
Bug: 72531009
Test: Builds successfully
Change-Id: I71ba2d59793620f7d5757f21e6a075f75bbdef05
2018-01-26 07:10:00 +00:00
Insun Kang
51e8d0a050 Merge "VideoView2: Apply API review comment" 2018-01-26 06:55:13 +00:00
TreeHugger Robot
6e2da09ab8 Merge "Add TYPE_BUS to isValidAudioDeviceTypeOut" 2018-01-26 05:39:27 +00:00
Jaewan Kim
1a2c263c7a MediaSession2: Change MediaPlayerBase to MediaPlayerInterface
Test: Run all MediaComponents tests once
Bug: 72527150
Change-Id: Ifd384ea274ec949caa767210b07e558844552077
2018-01-26 13:28:27 +09:00
Jaewan Kim
33573461df MediaSession2: Use Executor for callback handling
This also simplifies future work for adding more functions
Test: Run all MediaComponents test once

Change-Id: I37f1e205f95bcf506df5550c1e65a864e8a9028c
2018-01-26 13:27:17 +09:00
Hyundo Moon
46377a9aae VideoView2: Add custom actions API
Test: Using VideoViewTest application
Change-Id: I941bf0f9605918b0e0f9e4684327eee9ffe24e11
2018-01-26 12:58:55 +09:00
Insun Kang
df0728c15a VideoView2: Apply API review comment
- Lint error: setVideoURI --> setVideoUri
- Adds 'View' parameter to the listener methods
- Adds missing documents for constants
- Removes getAudioSessionId()
- Typos

Test: build
Change-Id: I217c7608a8b9fed4111d0c928a270784307bf378
2018-01-26 11:23:04 +09:00
TreeHugger Robot
ce6b2d6bb9 Merge changes from topic "product_partition"
* changes:
  Read media files from /product/media/audio
  Support /product partition
2018-01-26 01:10:16 +00:00
TreeHugger Robot
ae30c68489 Merge "VideoView2: Remove APIs supported by MediaSession" 2018-01-25 21:53:12 +00:00
Robert Shih
54573c5971 Merge "MediaExtractor: getSampleSize API" 2018-01-25 21:27:39 +00:00
TreeHugger Robot
4b7abff005 Merge "add getMetrics() apis for AudioTrack and AudioRecord" 2018-01-25 20:31:07 +00:00