Skip to content

Commit b3a6365

Browse files
committed
Merge remote-tracking branch 'origin/main' into consecutiveDroppedFrames
2 parents 57b1d27 + 9bb254f commit b3a6365

File tree

585 files changed

+41283
-9680
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

585 files changed

+41283
-9680
lines changed

.github/ISSUE_TEMPLATE/bug.yml

+1
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ body:
1919
options:
2020
- Media3 main branch
2121
- Media3 pre-release (alpha, beta or RC not in this list)
22+
- Media3 1.5.1
2223
- Media3 1.5.0
2324
- Media3 1.4.1
2425
- Media3 1.4.0

RELEASENOTES.md

+190-31
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,135 @@
33
### Unreleased changes
44

55
* Common Library:
6+
* Fix bug in `SimpleBasePlayer` where setting a new
7+
`currentMediaItemIndex` in `State` after `setPlaylist` with `null`
8+
`MediaMetadata` does not reevaluate the metadata
9+
([#1940](https://github.com/androidx/media/issues/1940)).
610
* ExoPlayer:
7-
* Consider language when selecting a video track. By default select a
11+
* Add experimental 'ExoPlayer' pre-warming support for playback using
12+
`MediaCodecVideoRenderer`. `DefaultRenderersFactory` can be configured
13+
through `experimentalSetEnableMediaCodecVideoRendererPrewarming` to
14+
provide a secondary `MediaCodecVideoRenderer` to `ExoPlayer`. If
15+
enabled, `ExoPlayer` will pre-process the video of consecutive media
16+
items during playback to reduce media item transition latency.
17+
* Fix issue where additional decode-only frames may be displayed in quick
18+
succession when transitioning to content media after a mid-roll ad.
19+
* Make `DefaultRenderersFactory` add two `MetadataRenderer` instances by
20+
default to enable apps to receive two different schemes of metadata by
21+
default.
22+
* Initialize `DeviceInfo` and device volume asynchronously (if enabled via
23+
`setDeviceVolumeControlEnabled`). These values won't be available
24+
instantly after the `ExoPlayer.Builder.build()` and are notified via
25+
`Player.Listener.onDeviceInfoChanged` and `onDeviceVolumeChanged`.
26+
* Transformer:
27+
* Enable support for Android platform diagnostics via
28+
`MediaMetricsManager`. Transformer will forward editing events and
29+
performance data to the platform, which helps to provide system
30+
performance and debugging information on the device. This data may also
31+
be collected by Google
32+
[if sharing usage and diagnostics data is enabled](https://support.google.com/accounts/answer/6078260)
33+
by the user of the device. Apps can opt-out of contributing to platform
34+
diagnostics for Transformer with
35+
`Transformer.Builder.setUsePlatformDiagnostics(false)`.
36+
* Split `InAppMuxer` into `InAppMp4Muxer` and `InAppFragmentedMp4Muxer`.
37+
`InAppMp4Muxer` is to be used for producing a non-fragmented MP4 file,
38+
while `InAppFragmentedMp4Muxer` is to be used for producing a fragmented
39+
MP4 file.
40+
* Move `Muxer` interface from `media3-muxer` to `media3-transformer`.
41+
* Track Selection:
42+
* Extractors:
43+
* Fix handling of NAL units with lengths expressed in 1 or 2 bytes (rather
44+
than 4).
45+
* DataSource:
46+
* Audio:
47+
* Do not bypass `SonicAudioProcessor` when `SpeedChangingAudioProcessor`
48+
is configured with default parameters.
49+
* Fix underflow in `Sonic#getOutputSize()` that could cause
50+
`DefaultAudioSink` to stall.
51+
* Fix `MediaCodecAudioRenderer.getDurationToProgressUs()` and
52+
`DecoderAudioRenderer.getDurationToProgressUs()` so that seeks will
53+
correctly reset the provided durations.
54+
* Video:
55+
* Text:
56+
* TTML: Add support for referencing `tts:origin` and `tts:extent` via
57+
`style` ([#2953](https://github.com/google/ExoPlayer/issues/2953)).
58+
* Restrict WebVTT and SubRip timestamps to exactly 3 decimal places.
59+
Previously we incorrectly parsed any number of decimal places but always
60+
assumed the value was in milliseconds, leading to incorrect timestamps
61+
([#1997](https://github.com/androidx/media/issues/1997)).
62+
* Add support for VobSub subtitles
63+
([#8260](https://github.com/google/ExoPlayer/issues/8260)).
64+
* Fix playback hanging when a playlist contains clipped items with CEA-608
65+
or CEA-708 captions.
66+
* Fix `IllegalStateException` when an SSA file contains a cue with zero
67+
duration (start and end time equal)
68+
([#2052](https://github.com/androidx/media/issues/2052)).
69+
* Metadata:
70+
* Image:
71+
* DataSource:
72+
* DRM:
73+
* Effect:
74+
* Muxers:
75+
* Renamed `setSampleCopyEnabled()` method to `setSampleCopyingEnabled()`
76+
in both `Mp4Muxer.Builder` and `FragmentedMp4Muxer.Builder`.
77+
* `Mp4Muxer.addTrack()` and `FragmentedMp4Muxer.addTrack()` now return an
78+
`int` track id instead of a `TrackToken`.
79+
* `Mp4Muxer` and `FragmentedMp4Muxer` no longer implement `Muxer`
80+
interface.
81+
* IMA extension:
82+
* Session:
83+
* Fix bug where calling a `Player` method on a `MediaController` connected
84+
to a legacy session dropped changes of a pending update coming from the
85+
legacy session.
86+
* UI:
87+
* Add `PresentationState` state holder class and the corresponding
88+
`rememberPresentationState` Composable to `media3-ui-compose`.
89+
* Downloads:
90+
* OkHttp Extension:
91+
* Cronet Extension:
92+
* RTMP Extension:
93+
* HLS Extension:
94+
* Parse `SUPPLEMENTAL-CODECS` tag from HLS playlist to detect Dolby Vision
95+
formats ([#1785](https://github.com/androidx/media/pull/1785)).
96+
* DASH Extension:
97+
* Fix issue when calculating the update interval for ad insertion in
98+
multi-period live streams
99+
([#1698](https://github.com/androidx/media/issues/1698)).
100+
* Parse `scte214:supplementalCodecs` attribute from DASH manifest to
101+
detect Dolby Vision formats
102+
([#1785](https://github.com/androidx/media/pull/1785)).
103+
* Improve handling of period transitions in live streams where the period
104+
contains media samples beyond the declared period duration
105+
([#1698](https://github.com/androidx/media/issues/1698)).
106+
* Smooth Streaming Extension:
107+
* RTSP Extension:
108+
* Decoder Extensions (FFmpeg, VP9, AV1, etc.):
109+
* MIDI extension:
110+
* Leanback extension:
111+
* Cast Extension:
112+
* Test Utilities:
113+
* Demo app:
114+
* Use `PresentationState` to control the aspect ratio of `PlayerSurface`
115+
Composable depending on the ContentScale type and cover it with a
116+
shutter-overlay before the first frame is rendered.
117+
* Remove deprecated symbols:
118+
* Removed `ExoPlayer.VideoComponent`, `ExoPlayer.AudioComponent`,
119+
`ExoPlayer.TextComponent` and `ExoPlayer.DeviceComponent`.
120+
121+
## 1.6
122+
123+
### 1.6.0-alpha01 (2024-12-20)
124+
125+
This release includes the following changes since the
126+
[1.5.1 release](#151-2024-12-19):
127+
128+
* Common Library:
129+
* Remove `Format.toBundle(boolean excludeMetadata)` method, use
130+
`Format.toBundle()` instead.
131+
* Add `AudioManagerCompat` and `AudioFocusRequestCompat` to replace the
132+
equivalent classes in `androidx.media`.
133+
* ExoPlayer:
134+
* Consider language when selecting a video track. By default, select a
8135
'main' video track that matches the language of the selected audio
9136
track, if available. Explicit video language preferences can be
10137
expressed with
@@ -21,45 +148,54 @@
21148
`bufferForPlaybackAfterRebufferMs` in `DefaultLoadControl` to 1000 and
22149
2000 ms respectively.
23150
* Add `MediaExtractorCompat`, a new class that provides equivalent
24-
functionality to platform `MediaExtractor`.
25-
* Move `BasePreloadManager.Listener` to a top level
151+
features to platform `MediaExtractor`.
152+
* Move `BasePreloadManager.Listener` to a top-level
26153
`PreloadManagerListener`.
154+
* `RenderersFactory.createSecondaryRenderer` can be implemented to provide
155+
secondary renderers for pre-warming. Pre-warming enables quicker media
156+
item transitions during playback.
157+
* Enable sending `CmcdData` for manifest requests in adaptive streaming
158+
formats DASH, HLS, and SmoothStreaming
159+
([#1951](https://github.com/androidx/media/issues/1951)).
160+
* Provide `MediaCodecInfo` of the codec that will be initialized in
161+
`MediaCodecRenderer.onReadyToInitializeCodec`
162+
([#1963](https://github.com/androidx/media/pull/1963)).
163+
* Change `AdsMediaSource` to allow the `AdPlaybackStates` to grow by
164+
appending ad groups. Invalid modifications are detected and throw an
165+
exception.
27166
* Transformer:
28167
* Update parameters of `VideoFrameProcessor.registerInputStream` and
29168
`VideoFrameProcessor.Listener.onInputStreamRegistered` to use `Format`.
30-
* Add support for transmuxing into alternative backwards compatible
169+
* Add support for transmuxing into alternative backward compatible
31170
formats.
32171
* Generate HDR static metadata when using `DefaultEncoderFactory`.
33172
* Extractors:
34-
* MP3: Don't stop playback early when a `VBRI` frame's table of contents
35-
doesn't cover all the MP3 data in a file
36-
([#1904](https://github.com/androidx/media/issues/1904)).
37-
* DataSource:
173+
* AVI: Fix handling of files with constant bitrate compressed audio where
174+
the stream header stores the number of bytes instead of the number of
175+
chunks.
38176
* Audio:
177+
* Fix `onAudioPositionAdvancing` to be called when playback resumes
178+
(previously it was called when playback was paused).
39179
* Video:
40-
* Rollback of using `MediaCodecAdapter` supplied pixel aspect ratio values
41-
when provided while processing `onOutputFormatChanged`
42-
([#1371](https://github.com/androidx/media/pull/1371)).
180+
* Fix `MediaCodecVideoRenderer` such that when without a `Surface`, the
181+
renderer skips just-early frames only if the
182+
`VideoFrameReleaseControl.getFrameReleaseAction` is not
183+
`FRAME_RELEASE_TRY_AGAIN_LATER`.
43184
* Text:
44185
* Stop eagerly loading all subtitle files configured with
45186
`MediaItem.Builder.setSubtitleConfigurations`, and instead only load one
46187
if it is selected by track selection
47188
([#1721](https://github.com/androidx/media/issues/1721)).
48-
* Fix bug in `ReplacingCuesResolver.discardCuesBeforeTimeUs` where the cue
49-
active at `timeUs` (started before but not yet ended) was incorrectly
50-
discarded ([#1939](https://github.com/androidx/media/issues/1939)).
51-
* Metadata:
52-
* Image:
53-
* DRM:
54189
* Effect:
55190
* Moved the functionality of `OverlaySettings` into
56191
`StaticOverlaySettings`. `OverlaySettings` can be subclassed to allow
57192
dynamic overlay settings.
58193
* Muxers:
59-
* IMA extension:
194+
* Moved `MuxerException` out of `Muxer` interface to avoid a very long
195+
fully qualified name.
60196
* Session:
61-
* Add 'Context' as a parameter to
62-
'MediaButtonReceiver.shouldStartForegroundService`
197+
* Add `Context` as a parameter to
198+
`MediaButtonReceiver.shouldStartForegroundService`
63199
([#1887](https://github.com/androidx/media/issues/1887)).
64200
* UI:
65201
* Add `PlayerSurface` Composable to `media3-ui-compose` module.
@@ -68,24 +204,21 @@
68204
`rememberPlayPauseButtonState`, `rememberNextButtonState`,
69205
`rememberPreviousButtonState`, `rememberRepeatButtonState`,
70206
`rememberShuffleButtonState` Composables to `media3-ui-compose` module.
71-
* Downloads:
72-
* OkHttp Extension:
73-
* Cronet Extension:
74-
* RTMP Extension:
75207
* HLS Extension:
208+
* Add a first version of `HlsInterstitialsAdsLoader`. The ads loader reads
209+
the HLS interstitials of an HLS media playlist and maps them to the
210+
`AdPlaybackState` that is passed to the `AdsMediaSource`. This initial
211+
version only supports HLS VOD streams with `X-ASSET-URI` attributes.
212+
* Add `HlsInterstitialsAdsLoader.AdsMediaSourceFactory`. Apps can use it
213+
to create `AdsMediaSource` instances that use an
214+
`HlsInterstitialsAdsLoader` in a convenient and safe way.
76215
* DASH Extension:
77216
* Add AC-4 Level-4 format support for DASH
78217
([#1898](https://github.com/androidx/media/pull/1898)).
79-
* Smooth Streaming Extension:
80-
* RTSP Extension:
81218
* Decoder Extensions (FFmpeg, VP9, AV1, etc.):
82219
* Add the MPEG-H decoder module which uses the native MPEG-H decoder
83220
module to decode MPEG-H audio
84221
([#1826](https://github.com/androidx/media/pull/1826)).
85-
* MIDI extension:
86-
* Leanback extension:
87-
* Cast Extension:
88-
* Test Utilities:
89222
* Demo app:
90223
* Add `MinimalControls` (`PlayPauseButton`, `NextButton`,
91224
`PreviousButton`) and `ExtraControls` (`RepeatButton`, `ShuffleButton`)
@@ -115,7 +248,7 @@
115248
`EditedMediaItem` passed to `Transformer.start()` instead.
116249
* `setListener()`, use `addListener()`, `removeListener()` or
117250
`removeAllListeners()` instead.
118-
* Remove the following deprecated `Tansformer.Listener` methods:
251+
* Remove the following deprecated `Transformer.Listener` methods:
119252
* `onTransformationCompleted(MediaItem)`, use
120253
`onCompleted(Composition, ExportResult)` instead.
121254
* `onTransformationCompleted(MediaItem, TransformationResult)`, use
@@ -148,6 +281,32 @@
148281

149282
## 1.5
150283

284+
### 1.5.1 (2024-12-19)
285+
286+
This release includes the following changes since the
287+
[1.5.0 release](#150-2024-11-27):
288+
289+
* ExoPlayer:
290+
* Disable use of asynchronous decryption in MediaCodec to avoid reported
291+
codec timeout issues with this platform API
292+
([#1641](https://github.com/androidx/media/issues/1641)).
293+
* Extractors:
294+
* MP3: Don't stop playback early when a `VBRI` frame's table of contents
295+
doesn't cover all the MP3 data in a file
296+
([#1904](https://github.com/androidx/media/issues/1904)).
297+
* Video:
298+
* Rollback of using `MediaCodecAdapter` supplied pixel aspect ratio values
299+
when provided while processing `onOutputFormatChanged`
300+
([#1371](https://github.com/androidx/media/pull/1371)).
301+
* Text:
302+
* Fix bug in `ReplacingCuesResolver.discardCuesBeforeTimeUs` where the cue
303+
active at `timeUs` (started before but not yet ended) was incorrectly
304+
discarded ([#1939](https://github.com/androidx/media/issues/1939)).
305+
* Metadata:
306+
* Extract disc/track numbering and genre from Vorbis comments into
307+
`MediaMetadata`
308+
([#1958](https://github.com/androidx/media/issues/1958)).
309+
151310
### 1.5.0 (2024-11-27)
152311

153312
This release includes the following changes since the

api.txt

+3
Original file line numberDiff line numberDiff line change
@@ -1599,6 +1599,7 @@ package androidx.media3.session {
15991599
method public final long getCurrentPosition();
16001600
method public final androidx.media3.common.Timeline getCurrentTimeline();
16011601
method public final androidx.media3.common.Tracks getCurrentTracks();
1602+
method public final com.google.common.collect.ImmutableList<androidx.media3.session.CommandButton> getCustomLayout();
16021603
method public final androidx.media3.common.DeviceInfo getDeviceInfo();
16031604
method @IntRange(from=0) public final int getDeviceVolume();
16041605
method public final long getDuration();
@@ -1701,6 +1702,7 @@ package androidx.media3.session {
17011702
public static interface MediaController.Listener {
17021703
method public default void onAvailableSessionCommandsChanged(androidx.media3.session.MediaController, androidx.media3.session.SessionCommands);
17031704
method public default com.google.common.util.concurrent.ListenableFuture<androidx.media3.session.SessionResult> onCustomCommand(androidx.media3.session.MediaController, androidx.media3.session.SessionCommand, android.os.Bundle);
1705+
method public default void onCustomLayoutChanged(androidx.media3.session.MediaController, java.util.List<androidx.media3.session.CommandButton>);
17041706
method public default void onDisconnected(androidx.media3.session.MediaController);
17051707
method public default void onExtrasChanged(androidx.media3.session.MediaController, android.os.Bundle);
17061708
method public default com.google.common.util.concurrent.ListenableFuture<androidx.media3.session.SessionResult> onSetCustomLayout(androidx.media3.session.MediaController, java.util.List<androidx.media3.session.CommandButton>);
@@ -1893,6 +1895,7 @@ package androidx.media3.session {
18931895

18941896
public final class SessionToken {
18951897
ctor public SessionToken(android.content.Context, android.content.ComponentName);
1898+
method public static com.google.common.util.concurrent.ListenableFuture<androidx.media3.session.SessionToken> createSessionToken(android.content.Context, android.media.session.MediaSession.Token);
18961899
method public static com.google.common.collect.ImmutableSet<androidx.media3.session.SessionToken> getAllServiceTokens(android.content.Context);
18971900
method public android.os.Bundle getExtras();
18981901
method public String getPackageName();

constants.gradle

+3-3
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@
1212
// See the License for the specific language governing permissions and
1313
// limitations under the License.
1414
project.ext {
15-
releaseVersion = '1.5.0'
16-
releaseVersionCode = 1_005_000_3_00
15+
releaseVersion = '1.6.0-alpha01'
16+
releaseVersionCode = 1_006_000_0_01
1717
minSdkVersion = 21
1818
// See https://developer.android.com/training/cars/media/automotive-os#automotive-module
1919
automotiveMinSdkVersion = 28
@@ -46,7 +46,7 @@ project.ext {
4646
androidxConstraintLayoutVersion = '2.1.4'
4747
androidxCoreVersion = '1.8.0'
4848
androidxExifInterfaceVersion = '1.3.6'
49-
androidxLifecycleVersion = '2.6.0'
49+
androidxLifecycleVersion = '2.8.7'
5050
androidxMediaVersion = '1.7.0'
5151
androidxRecyclerViewVersion = '1.3.0'
5252
androidxMaterialVersion = '1.8.0'

demos/compose/build.gradle

+2-1
Original file line numberDiff line numberDiff line change
@@ -66,14 +66,15 @@ android {
6666
}
6767

6868
dependencies {
69-
def composeBom = platform('androidx.compose:compose-bom:2024.05.00')
69+
def composeBom = platform('androidx.compose:compose-bom:2024.12.01')
7070
implementation composeBom
7171

7272
implementation 'androidx.activity:activity-compose:1.9.0'
7373
implementation 'androidx.compose.foundation:foundation'
7474
implementation 'androidx.compose.material3:material3'
7575
implementation 'androidx.compose.material:material-icons-extended'
7676
implementation 'androidx.compose.ui:ui-tooling-preview'
77+
implementation 'androidx.lifecycle:lifecycle-runtime-compose:' + androidxLifecycleVersion
7778
implementation 'com.google.android.material:material:' + androidxMaterialVersion
7879

7980
implementation project(modulePrefix + 'lib-exoplayer')

0 commit comments

Comments
 (0)