19477 Commits

Author SHA1 Message Date
christosts
61770f8a61 Publish MIDI decoder module on Maven repository
Issue: androidx/media#734

#minor-release

PiperOrigin-RevId: 574182702
2023-10-17 09:59:44 -07:00
andrewlewis
680eed52f3 Add support for flattening SEF files with H.265
PiperOrigin-RevId: 574173120
2023-10-17 09:26:14 -07:00
Copybara-Service
009d48a75e Merge pull request #491 from v-novaltd:dsparano-exo128
PiperOrigin-RevId: 574129451
2023-10-17 06:35:19 -07:00
microkatz
716240776e Updated golden file tests and readded constructor 2023-10-17 11:42:33 +00:00
microkatz
e28288f9c5 Updated golden file tests and removed deprecated ColorInfo constructor usage 2023-10-17 11:42:33 +00:00
microkatz
212e138bcf Removed deprecated ColorInfo constructor call and fixed formatting 2023-10-17 11:42:33 +00:00
microkatz
d206be74ef Updated to use ColorInfo.Builder() and formatting issues 2023-10-17 11:42:33 +00:00
microkatz
bbcf37dc9e Format with google-java-format 2023-10-17 11:42:33 +00:00
Daniele Sparano
f14732873f Change isColorValid with isDataSpaceValid 2023-10-17 11:42:33 +00:00
Daniele Sparano
1fe9c3303e Resume toLogString() in ColorInfo; revert DebugTextViewHelper 2023-10-17 11:42:33 +00:00
microkatz
c72ec74e11 Format with google-java-format 2023-10-17 11:42:33 +00:00
microkatz
ee1b1500e2 Format with google-java-format 2023-10-17 11:42:33 +00:00
Daniele Sparano
f8d98861ea Move luma and chroma bitdepths to ColorInfo class 2023-10-17 11:42:33 +00:00
Daniele Sparano
59ff0dbb85 Improve isobmff atom parsing changes 2023-10-17 11:42:33 +00:00
Daniele Sparano
d454bd0601 Set luma and chroma bit depths in Format from Rtsp 2023-10-17 11:42:33 +00:00
Daniele Sparano
fc61d96d5c Replace literal with constant variable 2023-10-17 11:42:32 +00:00
Daniele Sparano
c7fe0662ce Set bitdepths in test Format 2023-10-17 11:42:32 +00:00
Daniele Sparano
e71ca5a740 Add luma and chroma bit depths to Format, set them as signalled in containers and parameter sets 2023-10-17 11:42:32 +00:00
claincly
dc0bee9307 Perform case insensitive comparison in tests
The model is "Redmi 6A" on the device

PiperOrigin-RevId: 574103629
2023-10-17 04:37:21 -07:00
ibaker
df19097e22 Move DASH subtitle parsing release note to correct section
#minor-release

PiperOrigin-RevId: 574090381
2023-10-17 03:42:04 -07:00
bachinger
64bd3bcad3 Send media button events from service directly using MediaSessionImpl
Media button event coming from the `MediaSessionService` are delegated
to the `MediaSessionImpl` and then sent to the session by using the
`MediaSessionStub` directly instead of using the `MediaController`
API.

Splitting the `MediaController.Listener` and `Player.Listener` in
`MediaNotificationManager` got reverted, and both listener are set to the
controller as before. This reverts the change that introduced a
different timing behaviour. It still holds, that a listener
registered on a `MediaController` that calls a method like `play()` is
called immediately and before the call has arrived at the player. This
change works around this behaviour from the library side by calling
`MediaSessionStub` directly with a `ControllerInfo`.

#minor-release

PiperOrigin-RevId: 573918850
2023-10-16 13:52:30 -07:00
bachinger
d5f093f43c Send ConnectionState as in-process bundle if possible
#minor-release

PiperOrigin-RevId: 573849858
2023-10-16 10:15:34 -07:00
ibaker
681eadeb85 Test overriding resource type in RawResourceDataSource
I couldn't work out a good way to set up a test environment with
an asset in a different package, so I'm not adding a test for the
package overriding.

PiperOrigin-RevId: 573843326
2023-10-16 09:58:00 -07:00
samrobinson
fe1144487a Parse metadata from srfr atom in SMTA.
PiperOrigin-RevId: 573829216
2023-10-16 09:11:53 -07:00
bachinger
f53e1bc6f6 Only set the queue when COMMAND_GET_TIMELINE is available
Android Auto shows a queue button when the queue is not empty.
Apps were able to remove this queue button with the legacy API
by not setting the queue of the session.

After this change, removing `COMMAND_GET_TIMELINE` from the commands
of the media notification controller or the session player sets the
queue in the platform session to null.

#minor-release
Issue: androidx/media#339
PiperOrigin-RevId: 573813558
2023-10-16 08:14:38 -07:00
tonihei
00425dbe80 Expand MediaItems in session demo instead of just replacing them
When MediaItems are added from the controller, we currently completely
replace the item with the one from our database, overriding any
potential additional information the controller may have set.

Also forward the onAddMediaItems/onSetMediaItems callbacks to common
helper methods instead of redirecting them through super methods

#minor-release
Issue: androidx/media#706
PiperOrigin-RevId: 573799351
2023-10-16 07:05:28 -07:00
claincly
37c86f3c15 Enable per-mediaItem effect in CompositionPlayer
Currently the effects are applied one frame too early. This will be fixed in
a later CL.

PiperOrigin-RevId: 573773074
2023-10-16 04:41:22 -07:00
ibaker
35121a2d3d Add RawResourceDataSource test for android.resource:///id URI
This is the documented format of this URI. The previous test was
exercising an undocumented format. Support for the previous format is
kept (and documented) because it seems to be relatively common (despite
the package name not being needed or used).

PiperOrigin-RevId: 573756190
2023-10-16 03:06:25 -07:00
tianyifeng
58a63c82aa Calculate HLS live playlist refresh interval accurately
Previously, we calculated the next playlist reload time by adding the target duration (or half of it, depending on whether there is a real update in the new playlist snapshot) from the last load completion time, which makes the reload interval as long as `targetDuration(or half of it) + lastLoadDuration`. While still complying to the standard that "the client MUST wait for at least the target duration before attempting to reload the Playlist file again", this could cause buffering when the playback position is close to the end of live window. This change is to calculate the reload interval accurately by not adding the term `lastLoadDuration`.

Issue: androidx/media#663

#minor-release

PiperOrigin-RevId: 573300009
2023-10-13 13:06:46 -07:00
Googler
8b7ebc7032 Remove deprecated DownloadNotificationHelper.buildProgressNotification
Use a non deprecated method that takes a `notMetRequirements` parameter
instead.

#minor-release

PiperOrigin-RevId: 573252909
2023-10-13 10:17:57 -07:00
ibaker
40459f7212 Test more URI forms in RawResourceDataSourceContractTest
PiperOrigin-RevId: 573220915
2023-10-13 07:57:58 -07:00
ibaker
ecd24646cb Migrate SubtitleParser implementations to incremental parse()
All production and test callers of the non-incremental methods are
already migrated, so we can remove them in this change too.

#minor-release

PiperOrigin-RevId: 573207318
2023-10-13 06:52:40 -07:00
ibaker
a19f577976 Remove the 'super speed' SmoothStreaming PlayReady stream from demo
This content is no longer available, the manifest is returning a 404.

Issue: google/ExoPlayer#11309

#minor-release

PiperOrigin-RevId: 573202175
2023-10-13 06:31:39 -07:00
ibaker
f9ece88a25 Change LegacySubtitleUtil handling of SubtitleParser.OutputOptions
If the `Subtitle` has 'active' cues at `OutputOptions.startTimeUs`, this
change ensures these are emitted in a `CuesWithTiming` with
`CuesWithTiming.startTimeUs = OutputOptions.startTimeUs`. If
`OutputOptions.outputAllCues` is also set, then another `CuesWithTiming`
is emitted at the end that covers the 'first part' of the active cues,
and  ends at `OutputOptions.startTimeUs`.

As well as adding some more tests to `LegacySubtitleUtilWebvttTest`,
this change also adds more tests for `TtmlParser` handling of
`OutputOptions`, which transitively tests the behaviour of
`LegacySubtitleUtil`.

#minor-release

PiperOrigin-RevId: 573151016
2023-10-13 02:21:22 -07:00
Copybara-Service
2421ba4d8f Merge pull request #650 from cedricxperi:dts-lbr-buffer-underflow-fix
PiperOrigin-RevId: 572864175
2023-10-12 04:50:32 -07:00
Tianyi Feng
492048c00b Modify the comment lines 2023-10-12 09:56:28 +00:00
Tianyi Feng
834b61d1b7 Update the year in the copyright 2023-10-12 09:56:28 +00:00
Tianyi Feng
49f45c45d1 Rebase and resolve conflict in the release notes 2023-10-12 09:56:28 +00:00
Tianyi Feng
215f663019 Format with google-java-format 2023-10-12 09:56:28 +00:00
Cedric T
0f200ba5d1 Update nits 2023-10-12 09:56:28 +00:00
Cedric T
24d03b0625 Rename DTSE to DTSHD 2023-10-12 09:56:28 +00:00
Cedric T
7edfe58283 Remove current mimetype state and add DTSHD test cases 2023-10-12 09:56:28 +00:00
Cedric T
25acaa1c81 Fix DTS Express Audio Buffer Underflow Issue. 2023-10-12 09:56:28 +00:00
ibaker
a12bde4f57 Migrate SubtitleParser tests to incremental parse() methods
All the production code is already calling these new incremental
methods, migrating the tests allows us to remove the old
`List`-returning methods in a follow-up change.

#minor-release

PiperOrigin-RevId: 572822828
2023-10-12 01:42:28 -07:00
tonihei
d1fc15f207 Avoid bundling PlayerInfo for in-process calls
PlayerInfo bundling is costly and we can add a shortcut for
in-process binder calls where we store the direct object
reference in a live Binder object that can be written to the
Bundle instead of the individual data fields.

#minor-release

PiperOrigin-RevId: 572816784
2023-10-12 01:16:27 -07:00
tonihei
4ebe630a80 Split available command filtering and bundling
A few methods in PlayerInfo and related classes combine filtering
information with bundling in one method. This makes it impossible
to use just the filtering for example and it's also easier to reason
about than two dedicated methods. This change splits these methods
into two parts accordingly.

PiperOrigin-RevId: 572592458
2023-10-11 09:09:11 -07:00
bachinger
7fdc5b22ba Check whether a session is still managed before removing
When the controller of the `MediaNotificationManager` is disconnected,
the session is removed from the service without checking whether the
session hasn't already been removed. This caused flakiness in `MediaSessionServiceTest.addSession()`.

Because there is a public API `MediaSessionService.removeSession()`,
the controller can't make an assumption whether the session is still
contained in the service when being disconnected.

#minor-release

PiperOrigin-RevId: 572568350
2023-10-11 07:27:50 -07:00
michaelkatz
cef85be40f Update release notes to mention AudioOffloadPreference class changes
Issue: androidx/media#721
PiperOrigin-RevId: 572565009
2023-10-11 07:12:37 -07:00
ibaker
c7a091a973 Request notification permission when starting session demo app
#minor-release

PiperOrigin-RevId: 572556101
2023-10-11 06:27:59 -07:00
bachinger
4dc3db4da3 Add MediaSession.Builder().setPeriodicPositionUpdateEnabled()
This allows to disable periodic position updates when building
the session.

#minor-release

PiperOrigin-RevId: 572531837
2023-10-11 04:10:03 -07:00