11273 Commits

Author SHA1 Message Date
olly
d53d2ca07d Fix search links in generated Javadoc
#minor-release

PiperOrigin-RevId: 373351014
2021-05-12 13:55:08 +01:00
Oliver Woodman
e20ea797ef Merge pull request #8767 from uvjustin:hls-start-from-independent-part
PiperOrigin-RevId: 373343326
2021-05-12 13:54:44 +01:00
claincly
497eb72c35 Remove RTSP message logging.
#minor-release

PiperOrigin-RevId: 373336127
2021-05-12 11:53:55 +01:00
claincly
fe74f690ec Allow RTSP streaming using TCP.
NAT will block off incoming UDP connection because the router has no knowledge
of the necessary port mapping (the mapping is never set up because UDP is
connectionless).

The end result is, the UDP socket to receive RTP data will timeout. After the
`SocketTimeoutException` is caught, the following takes place to try streaming
with TCP (or, RTP over RTSP).

- `RtspClient` sends TEARDOWN to tear down the current session.
- `RtspClient` re-connect to the RTSP server.
- `RtspMediaPeriod` cancels all loading `RtpDataLoadables` (that are using UDP)
- `RtspMediaPeriod` constructs new `RtpDataLoadables` that use
    `TransferRtpDataChannel`, and starts loading.
- Once the `RtpDataLoadables` are up and running, we are ready to receive.
  `RtspClient` sends the SETUP requests.

- The rest of the flow is unchanged.

#minor-release

PiperOrigin-RevId: 373310774
2021-05-12 11:53:14 +01:00
jaewan
43da862780 Add copy constructor and remove APIs for Commands builder
It helps to change allowed commands from session.

PiperOrigin-RevId: 373302990
2021-05-12 11:52:49 +01:00
jaewan
b2b6e0ecb5 Implements Player.Events#equals()
It's convenient for testing.

PiperOrigin-RevId: 373280130
2021-05-12 11:52:25 +01:00
olly
1da25f5979 Remove deprecated MediaSource.getTag
PiperOrigin-RevId: 373222158
2021-05-12 11:52:03 +01:00
aquilescanta
ad46b90918 Use Truth convenience methods for Exception-related assertions
PiperOrigin-RevId: 373180764
2021-05-12 11:51:40 +01:00
claincly
2a2d6f667d Move misplaced RTSP doc.
#minor-release

PiperOrigin-RevId: 373175041
2021-05-12 11:50:55 +01:00
claincly
4dd383565a Add dev guide for RTSP.
#minor-release

PiperOrigin-RevId: 373173075
2021-05-12 11:50:31 +01:00
aquilescanta
094f4a8436 Add notice about backwards compatibility in PlaybackException
PiperOrigin-RevId: 373172693
2021-05-11 17:47:26 +01:00
aquilescanta
d54168ae30 Make ExoPlaybackException extend PlaybackException
PiperOrigin-RevId: 373170792
2021-05-11 17:39:52 +01:00
tonihei
74b126dfc4 Don't wrap FileDataSourceException in FileDataSourceException.
Instead just forward the existing exception.

PiperOrigin-RevId: 373145328
2021-05-11 16:02:28 +01:00
olly
0c19506d7d Remove deprecated Format.create methods
PiperOrigin-RevId: 373144415
2021-05-11 16:02:08 +01:00
kim-vde
eb93e5c0b5 Merge pull request #8860 from KeiMurayamaS:dev-v2-add-mpegh-parser
PiperOrigin-RevId: 373142159
2021-05-11 16:01:46 +01:00
tonihei
08fb7bd65f Support changing ad break positions.
The player already supports changing durations of periods and ads.
The only thing not yet supported is a change in ad break positions
which changes the duration of clipped content ending in an ad break.

Adding support for this requires updating the end position in
MediaPeriodInfo and changing the clip end position of the respective
ClippingMediaPeriod.

Issue: #5067
PiperOrigin-RevId: 373139724
2021-05-11 16:01:25 +01:00
kim-vde
0a93cc23f0 Merge pull request #8894 from cdongieux:fix/issue-8847
PiperOrigin-RevId: 373128118
2021-05-11 16:01:03 +01:00
olly
b95fba2cb7 Remove deprecated Timeline.getWindow method
PiperOrigin-RevId: 373126944
2021-05-11 16:00:40 +01:00
aquilescanta
508c6652ba Add test for PlaybackException
PiperOrigin-RevId: 373026239
2021-05-10 23:42:51 +01:00
claincly
beeb6e829d Enable reading interleaved message in RtspMessageChannel.
RTSP interleaving enables RTP packets to be sent using RTSP's TCP connection.
The interleaving RTSP messages contain binary data only and always start with a
'$'. Normal RTSP messages contain line breaks (CRLFs) that indicate complete
lines.

#minor-release

PiperOrigin-RevId: 372990181
2021-05-10 23:42:31 +01:00
olly
89cfa4df32 Remove some deprecated Player methods
PiperOrigin-RevId: 372981744
2021-05-10 23:42:10 +01:00
olly
d282ad25c1 Include RTSP module in gradle project
#minor-release

PiperOrigin-RevId: 372981022
2021-05-10 23:41:50 +01:00
olly
9a2ebbb72e Minor guide cleanup for 2.14
#minor-release

PiperOrigin-RevId: 372980349
2021-05-10 23:41:29 +01:00
aquilescanta
763ef2b911 Avoid type-ambiguous overloads in ExoPlaybackExceptionTest
PiperOrigin-RevId: 372942778
2021-05-10 23:41:09 +01:00
tonihei
5167ca65fb Fix bug where content position of ads in moving live windows is updated
The method to handle Timeline updates currently uses
 isAd() || isPlaceholder()
to trigger two things:
 1. Using the existing requested content position as the content
    position.
 2. Re-resolving the content position from window to period in case
    it changed since the last update.

The condition is correct for case (1) because ads must use the content
position (and not the position in the ad) and a placeholder period must
keep using the requested content position as well until the media
information is no longer a placeholder.

However, case (2) only needs to be done if the content position is
C.TIME_UNSET (to start at the default position) OR if the period is
still a placeholder and we want to re-resolve the position.

The case where re-resolution shouldn't be done is for ads with a non-
placeholder period and a concrete content position. This likely only
affects ads in live stream where the content position is currently
moving with the live stream instead of staying where it is.

PiperOrigin-RevId: 372929439
2021-05-10 23:40:47 +01:00
tonihei
8a5d21adef Remove reference to deprecated Player.EventListener.
#minor-release

PiperOrigin-RevId: 372925409
2021-05-10 23:40:26 +01:00
olly
3c64bc1b49 Fix Javadoc references to deprecated EventListener
#minor-release

PiperOrigin-RevId: 372919342
2021-05-10 23:40:05 +01:00
olly
01f85394d2 Clean up RtspMediaSource.Factory
- Don't deprecate methods not deprecated in the base class and that
  could one day be useful.
- Better document deprecation of other methods.

#minor-release

PiperOrigin-RevId: 372919080
2021-05-10 23:39:45 +01:00
olly
e908750336 Bump version to 2.14.0 and tidy release notes
#minor-release

PiperOrigin-RevId: 372910834
2021-05-10 23:39:25 +01:00
ibaker
7a3d8b5ef0 Swallow exceptions in TestContentProvider when writing to a pipe fails
The existing code results in flaky tests, where sometimes the write
fails (with "EPIPE (broken pipe)") and the exception propagates out
and causes the test to never complete and time out.

Swallowing the exception resolves this flakiness.

#minor-release

PiperOrigin-RevId: 372909415
2021-05-10 23:39:03 +01:00
andrewlewis
5517fd7936 Remove Mercurial configuration intended for internal use
PiperOrigin-RevId: 372893564
2021-05-10 23:38:38 +01:00
Christophe Dongieux
928537182b Make DASH segment available at full network speed if index is marked as explicit 2021-05-10 17:34:29 +02:00
Kei Murayama
f05197c4d5 Support parsing MPEG-H 3D Audio
First intention to support parsing MPEG-H 3D Audio in ExoPlayer is to
take advantage of parsing capability from MediaParser API in AOSP.
Just with this change ExoPlayer does't support decoding MPEG-H 3D Audio
but can support decoding either by adding decoder with an extension or
by using Android OS which has decoder capability with MediaCodec API.
2021-05-10 17:55:03 +09:00
kimvde
7f2922d6f2 Deprecate ExoPlayer.Builder.
Apps should migrate from ExoPlayerImpl to SimpleExoPlayer.

#minor-release

PiperOrigin-RevId: 372562923
2021-05-10 09:38:08 +01:00
aquilescanta
f415ea2372 Make PlaybackException's Bundleable implementation subclass friendly
PiperOrigin-RevId: 372552003
2021-05-10 09:37:51 +01:00
samrobinson
1a6984fbe0 Add javadoc to the MediaMetadata setters.
#minor-release

PiperOrigin-RevId: 372549185
2021-05-10 09:37:33 +01:00
aquilescanta
e96fde5fe4 Add an IntDef for PlaybackException's Bundle key fields
PiperOrigin-RevId: 372548259
2021-05-10 09:37:14 +01:00
samrobinson
2914e574e6 Rename MediaMetadata trackTitle and trackArtist to title and artist.
#minor-release

PiperOrigin-RevId: 372537414
2021-05-07 14:58:03 +01:00
samrobinson
09a8993b56 Add fields to MediaMetadata requested by MediaAPIs
#minor-release

PiperOrigin-RevId: 372448985
2021-05-07 10:22:27 +01:00
bachinger
15ce148877 Avoid media item transitions for auto discontinuities when ads involved
#minor-release

PiperOrigin-RevId: 372433555
2021-05-07 10:22:08 +01:00
samrobinson
bbeedd5e76 Use getters in Rating subclasses rather than direct field access.
#minor-release

PiperOrigin-RevId: 372368685
2021-05-07 10:21:50 +01:00
aquilescanta
1408fe0403 Remove ExoPlaybackException's cause field
It was originally introduced because it was guaranteed to be non-null
unlike the inherited field. But ExoPlaybackException.cause has been
nullable for some time, so there's no gain in not using the inherited
field.

PiperOrigin-RevId: 372329740
2021-05-07 10:21:28 +01:00
bachinger
a9fc3185fe Do not mock NetworkException
PiperOrigin-RevId: 372321626
2021-05-06 13:36:00 +01:00
olly
782c1739c8 Use correct Log class
#minor-release

PiperOrigin-RevId: 372314890
2021-05-06 13:35:40 +01:00
jinpark
d388ab25cc Make Player.Commands Bundleable
PiperOrigin-RevId: 372266634
2021-05-06 13:34:04 +01:00
bachinger
5595c48739 Optionally deduplicate updating MediaMetadataCompat
PiperOrigin-RevId: 372146631
2021-05-06 13:33:44 +01:00
aquilescanta
1f83926d2f Reserve x000 error codes for the UNSPECIFIED error codes
PiperOrigin-RevId: 372146069
2021-05-06 13:33:25 +01:00
tonihei
61bbdb3794 Add missing isPlaceholder forwarding in SinglePeriodAdTimeline
Also make future similar issues less likely by adding isPlaceholder
to the set method of Period (in case forwarding Timeline
implementations use this instead of just updating values selectively)

#minor-release

PiperOrigin-RevId: 372138523
2021-05-06 13:33:06 +01:00
bachinger
4c1a294b2e Format Java source files
PiperOrigin-RevId: 372127633
2021-05-06 13:32:25 +01:00
bachinger
39ac09e7c6 Add @DoNotInstrument for unit test classes of extensions
PiperOrigin-RevId: 372101509
2021-05-06 13:32:05 +01:00