aquilescanta
5bb2d0386f
Remove createRendererException which doesn't take errorCode
...
And assign error codes to all callers.
PiperOrigin-RevId: 383118513
2021-07-09 08:59:47 +01:00
ibaker
0df0df9aee
Remove @DoNotInstrument from test classes
...
This isn't needed now we've updated to Robolectric 4.6
PiperOrigin-RevId: 383109343
2021-07-09 08:58:38 +01:00
ibaker
a14739acdd
Bump Robolectric to 4.6.1
...
The bug fix seems potentially serious and worth having:
https://github.com/robolectric/robolectric/releases/tag/robolectric-4.6.1
PiperOrigin-RevId: 383096745
2021-07-09 08:57:39 +01:00
aquilescanta
d7bb6e7235
Fix typo in internal class name
...
PiperOrigin-RevId: 382766969
2021-07-09 08:56:25 +01:00
ibaker
227ac89eff
Change TestPlayerRunHelper to fail-fast on playback error
...
If a test expects an error they can use runUntilError()
PiperOrigin-RevId: 382765060
2021-07-09 08:55:22 +01:00
ibaker
ee488e6625
Clarify the thread requirements of a SurfaceView or SurfaceHolder
...
Issue: #9005
PiperOrigin-RevId: 382765045
2021-07-09 08:54:07 +01:00
ibaker
22247d65c7
Use the content URI as well as mediaId for the auto-generated ad ID
...
MediaItem.mediaId used to default to the content URI, but this changed:
cc26a92e07
Before the mediaId change linked above, a playlist of different content
all with the same ad URI would play the ads for every item. After the
change the ad would only play once (because mediaId == "" for every
item, so they're all the same). This change restores roughly the
original behaviour by always considering both mediaId and the content
URI.
#minor-release
Issue: #9106
PiperOrigin-RevId: 382763618
2021-07-09 08:52:51 +01:00
ibaker
3bd662eb9a
Don't propagate attrs into child SubtitleOutput from SubtitleView
...
#minor-release
PiperOrigin-RevId: 382763308
2021-07-09 08:51:39 +01:00
ibaker
5e4056eb4c
Encode emsg duration & ID as int64 instead of uint32
...
The serialization scheme used here is custom, it doesn't need
to be compatible with emsg-v0 or emsg-v1 (since
97183ef558 ).
This means that C.TIME_UNSET will propagate correctly through the
serialization.
#minor-release
Issue: #9123
PiperOrigin-RevId: 382762873
2021-07-09 08:49:27 +01:00
ibaker
ef61d81d8d
Upgrade to Robolectric 4.6
...
The tests now pass without @DoNotInstrument
I had to tweak the jetification settings due to a bug in the jetifier
shipped with the Android Gradle Plugin. More details:
https://github.com/robolectric/robolectric/issues/6521#issuecomment-851736355
PiperOrigin-RevId: 382757006
2021-07-09 08:48:13 +01:00
ibaker
ee426822ee
Mark BasePlayer constructor as protected
...
This is an abstract class so it can only be constructed from the context
of a subclass anyway.
PiperOrigin-RevId: 382756293
2021-07-09 08:46:58 +01:00
ibaker
6e43ea97e7
Add @Deprecated to SEP methods that override deprecated methods
...
Without this annotation it seems that `SimpleExoPlayer` effectively
'un-deprecates' the method, specifically:
* A usage of these methods isn't flagged by Android Studio if the
declared type is `SimpleExoPlayer` (up-casting to e.g.
`ExoPlayer.VideoComponent` results in the warning showing up).
* The `SimpleExoPlayer` javadoc doesn't mention this method is
deprecated:
https://exoplayer.dev/doc/reference/com/google/android/exoplayer2/SimpleExoPlayer.html#addVideoListener(com.google.android.exoplayer2.video.VideoListener)
* The Metalava API output for `SimpleExoPlayer` doesn't show these
methods as deprecated.
PiperOrigin-RevId: 382756174
2021-07-09 08:45:51 +01:00
claincly
6035932fa3
Make HttpDataSourceException use PlaybackException error codes.
...
PiperOrigin-RevId: 382710409
2021-07-09 08:44:36 +01:00
claincly
747b0f057b
Make DataSourceException use PlaybackException error codes.
...
- Use `PlaybackException.ErrorCode` IntDef for `DataSourceException` error code
- Deprecate `DataSourceException.POSITION_OUT_OF_RANGE`
- All other changes are related to replacing the deprecated constant and
constructor
PiperOrigin-RevId: 382683522
2021-07-09 08:43:22 +01:00
claincly
ee0d905eed
Add ERROR_CODE_TIMEOUT.
...
Also remove the method for creating a TYPE_RENDERER ExoPlaybackException
with unknown renderer name and index.
PiperOrigin-RevId: 382589655
2021-07-09 08:40:38 +01:00
claincly
dda1d37368
Make HttpDataSourceException subclass DataSourceException.
...
PiperOrigin-RevId: 382551642
2021-07-09 08:39:26 +01:00
aquilescanta
b0ddef5bcf
Assign DRM error codes
...
PiperOrigin-RevId: 382527115
2021-07-09 08:38:13 +01:00
aquilescanta
c1995745e7
Move platform error mapping to common
...
In order to use it for error code assignment. Note that these DRM errors
could be thrown on API < 18 (from MediaCodec.CryptoException), which is
the reason we can't put the mapping in FrameworkMediaDrm.
PiperOrigin-RevId: 382512414
2021-07-09 08:36:53 +01:00
christosts
db454973f2
Rename packages for HLS module
...
PiperOrigin-RevId: 382508442
2021-07-09 08:35:49 +01:00
aquilescanta
124a6aea50
Remove unused method Log.getLogStackTraces
...
It was impossible to call because it was a non-static method in a class
with a private constructor.
PiperOrigin-RevId: 382504128
2021-07-09 08:34:38 +01:00
krocard
4de4f85739
Document threading guarantee of Player.addListener
...
These guarantees were documented for `EventListener` and
hold as well for Listener but were not documented.
PiperOrigin-RevId: 382498188
2021-07-09 08:33:26 +01:00
aquilescanta
a24bbbdd5e
Reimplement getErrorCodeFromPlatformDiagnosticsInfo to save the pattern
...
PiperOrigin-RevId: 382494191
2021-07-09 08:31:10 +01:00
olly
91cb54b84e
Make SkipAndContinueIfSampleTooLarge as default behavior.
...
Remove experimentalSetSkipAndContinueIfSampleTooLarge() api
PiperOrigin-RevId: 382383498
2021-07-09 08:29:58 +01:00
klhyun
3c97815d55
PlayerView sets aspect ratio when setting a new player
...
PlayerView and StyledPlayerView handled this in
onVideoSizeChanged but it can be omitted.
(e.g. if the player is MediaController)
PiperOrigin-RevId: 382340927
2021-07-09 08:28:37 +01:00
aquilescanta
d9d02710c0
Add tests for Util.getErrorCodeFromPlatformDiagnosticsInfo
...
PiperOrigin-RevId: 382311518
2021-07-09 08:27:17 +01:00
aquilescanta
2ca7432bf6
Move Util.getErrorCodeFromPlatformDiagnosticsInfo into common
...
Will be needed for error code assignment.
PiperOrigin-RevId: 382305328
2021-07-09 08:26:03 +01:00
olly
7b0a7f1295
Remove stray space
...
PiperOrigin-RevId: 382297051
2021-07-09 08:24:44 +01:00
Scott
83d2c39a36
Updated MediaCodecInfo with correct channel adjustments for DTS codecs
2021-07-08 11:17:24 +01:00
Scott
dffcf258ee
Updated mimetypes to support DTSX and to correct assign dtse to DTS Express
2021-07-08 11:11:26 +01:00
Scott
716cbceaa4
Updates to mp4 atom extractor/parser for dtsx support.
2021-07-08 11:07:56 +01:00
olly
a55c0654fb
Improve Cronet and OkHttp READMEs
...
PiperOrigin-RevId: 382279955
2021-06-30 13:54:16 +01:00
olly
dea52048cb
Bump dependency versions
...
PiperOrigin-RevId: 382277352
2021-06-30 13:53:01 +01:00
samrobinson
9013facdd7
Rename PlaylistMediaMetadata to PlaylistMetadata in Player.
...
This affects the setter, getter and callback, as well as various
media 3 methods.
PiperOrigin-RevId: 382275672
2021-06-30 13:51:51 +01:00
aquilescanta
764f9f20d6
Add info about trick-playness to the Format log string
...
PiperOrigin-RevId: 382139109
2021-06-30 13:50:32 +01:00
kimvde
6e4508daec
Improve support for Ogg truncated content
...
#minor-release
Issue:#7608
PiperOrigin-RevId: 382081687
2021-06-30 13:49:15 +01:00
aquilescanta
155e27ec7c
Move ExoPlaybackException back into core
...
PiperOrigin-RevId: 381941053
2021-06-30 13:47:30 +01:00
claincly
02db70bdd0
Amend RTSP dev guide to match the current code status.
...
PiperOrigin-RevId: 381852972
2021-06-30 13:46:13 +01:00
claincly
ffbec2234d
Assign PlaybackException.ErrorCode to renderer failures.
...
PiperOrigin-RevId: 381852092
2021-06-30 13:45:02 +01:00
olly
7aaba1ffe5
Migrate usage of Player.EventListener to Player.Listener
...
PiperOrigin-RevId: 381837274
2021-06-30 13:43:51 +01:00
olly
ea99c3fa94
Add ability to set Cronet request priority
...
PiperOrigin-RevId: 381833403
2021-06-30 13:42:42 +01:00
Oliver Woodman
8588bdb02a
Merge pull request #9119 from chvp:media2-dispatch-previous-next
...
PiperOrigin-RevId: 381833313
2021-06-30 13:41:35 +01:00
olly
bb82e7df9d
Cronet: Align terminology with documentation
...
PiperOrigin-RevId: 381472436
2021-06-30 13:40:24 +01:00
olly
6fe2f25fe9
Update DataSource extension documentation
...
Also upgrade the RTMP extension to use an inner class
for its factory.
PiperOrigin-RevId: 381469114
2021-06-30 13:39:09 +01:00
olly
ec9f512fee
OkHttp: Upgrade to 4.9.1 (minSdkVersion 21)
...
Until now, we have stuck with the 3.12 long-term branch so as
to keep support for older API levels. However, this means that
the version we're using is 2.5 years old at this point. The
3.12 branch will stop receiving critical updates in December
2021.
Since use of the OkHttp extension is optional anyway, it seems
preferable to move to a modern version of OkHttp at this point.
PiperOrigin-RevId: 381465269
2021-06-30 13:37:58 +01:00
olly
c9193fdcf7
Fix release notes
...
PiperOrigin-RevId: 381443205
2021-06-30 13:36:52 +01:00
aquilescanta
b58fce1bd9
Assign some more IO error codes
...
Specifically:
- ERROR_CODE_IO_NETWORK_CONNECTION_TIMEOUT
- ERROR_CODE_IO_NETWORK_CONNECTION_FAILED
- ERROR_CODE_IO_NETWORK_CONNECTION_CLOSED
PiperOrigin-RevId: 381441329
2021-06-30 13:35:37 +01:00
aquilescanta
465f7c06d8
Add ERROR_CODE_IO_CLEARTEXT_NOT_PERMITTED
...
And assign it to CleartextNotPermittedException.
PiperOrigin-RevId: 381247430
2021-06-30 13:34:31 +01:00
olly
bcd4bb87e5
Deprecate CronetEngineWrapper
...
PiperOrigin-RevId: 381239971
2021-06-30 13:32:43 +01:00
aquilescanta
1cc62c65a7
Add @ErrorCode to local variables in ExoPlayerImplInternal
...
PiperOrigin-RevId: 381236418
2021-06-30 13:30:58 +01:00
aquilescanta
cca4ac73ca
Assign ERROR_CODE_IO_DNS_FAILED to UnknownHostException
...
PiperOrigin-RevId: 381235721
2021-06-30 13:29:53 +01:00