10237 Commits

Author SHA1 Message Date
aquilescanta
270e274ef3 Treat -1000 duration as unknown duration for live streams in Cast
Issue: #7983
#minor-release
PiperOrigin-RevId: 339016928
2020-11-02 22:55:52 +00:00
samrobinson
1fcfef5cde Add readDelimiterTerminatedString to ParsableByteArray.
PiperOrigin-RevId: 338718776
2020-11-02 22:55:43 +00:00
samrobinson
7ccbf572c7 Add a Metadata Entry class for SEF Slow motion data.
PiperOrigin-RevId: 338695793
2020-11-02 22:55:34 +00:00
christosts
1887983a22 Minor Javadoc fix.
Issue: #4904
PiperOrigin-RevId: 338669087
2020-11-02 22:55:24 +00:00
andrewlewis
160ee9d890 Handle stream volume register/unregister errors
Issue: #8106
Issue: #8087
PiperOrigin-RevId: 338664455
2020-11-02 22:55:14 +00:00
aquilescanta
a184924322 Avoid chunkless preparation if the codec mapping is ambiguous
Issue: #7877
PiperOrigin-RevId: 338659937
2020-11-02 22:55:03 +00:00
xufuji456
4bc392a8ef fix the end point of span exceeds the length of SpannableStringBuilder 2020-10-29 15:12:49 +08:00
olly
5b1514e933 Fix release note
PiperOrigin-RevId: 338657613
2020-10-23 13:55:19 +01:00
olly
e5434ff4d3 Add plumbing for decoderReleased analytics events
A subsequent CL will plumb a release reason through these
event paths.

PiperOrigin-RevId: 338655603
2020-10-23 13:55:09 +01:00
christosts
485949b56c Refactor AsynchronousMediaCoderAdapter
Refactor the AsynchronousMediaCoderAdapter and move the callback thread
out of the adapter so that implementation of async callback and and
async queueing are consistent design-wise.

PiperOrigin-RevId: 338637837
2020-10-23 13:55:00 +01:00
aquilescanta
4783c329cc Map HLS sample formats to the correct codec string
This change fixes format creation for traditional preparation of streams
where the master playlist contains more than one codec string per track
type.

Issue: #7877
PiperOrigin-RevId: 338538693
2020-10-23 13:54:50 +01:00
aquilescanta
ccf78f99c4 Allow multiple codecs with same type in DefaultHlsExtractorFactory
When disabling a TsExtractor track type because of a missing codec
in the master playlist, look through the entire codecs string
instead of checking the first codec with matching type.

Issue: #7877
PiperOrigin-RevId: 338530046
2020-10-23 13:54:40 +01:00
kimvde
521a220728 Avoid throwing for still photo metadata retrieval
PiperOrigin-RevId: 338497163
2020-10-23 13:54:31 +01:00
samrobinson
1191820429 Allow additional entries in MetadataUtil.setFormatMetadata.
The primary use of this currently will be for appending SEF metadata.

PiperOrigin-RevId: 338475948
2020-10-23 13:54:21 +01:00
ibaker
18c6b16f91 Switch playback tests to single-parameter parameterized syntax
This is simpler than instantiating a single-element string array for
every parameter.

PiperOrigin-RevId: 338469324
2020-10-23 13:54:11 +01:00
olly
09b4a473ff Add missing release note
PiperOrigin-RevId: 338446775
2020-10-22 12:37:51 +01:00
kimvde
175b8eb69e Read Google Photos motion photo metadata
PiperOrigin-RevId: 338436906
2020-10-22 12:37:41 +01:00
olly
9bde5d0351 [nullness] The nullness checking fixes of the media related files
We rolled back the previous <unknown commit> because some of the nullness checking fixes broke the exoplayer2 tests. We submit this CL into the TAP Global Presubmit train (https://test.corp.google.com/OCL:337620582:BASE:338201100:1603283151742:36afd5a5) and make sure that this CL wouldn't break any other tests on google3.

PiperOrigin-RevId: 338267548
2020-10-21 22:26:48 +01:00
olly
563767d5e9 Bump version to 2.12.1
PiperOrigin-RevId: 338261975
2020-10-21 22:26:34 +01:00
christosts
a21eb772b1 HlsMediaSourceTest: rename dashMediaItem to hlsMediaItem
Issue: #4904
PiperOrigin-RevId: 338249499
2020-10-21 22:26:25 +01:00
tonihei
057771aeec Fix calculation for isSegmentAvailableAtFullNetworkSpeed.
The current caluclation was comparing Unix time with period time.
Fix it by always comparing against period time.

Issue: #4904
PiperOrigin-RevId: 338235754
2020-10-21 22:26:15 +01:00
christosts
e52a044ec5 Parse #EXT-X-SERVER-CONTROL and #EXT-X-PART-INF in HLS media playlists.
PiperOrigin-RevId: 338232910
2020-10-21 22:26:05 +01:00
bachinger
1051580a63 Improve naming of the methods of LivePlaybackSpeedControl
PiperOrigin-RevId: 338232327
2020-10-21 22:25:54 +01:00
tonihei
54506b506b Explicitly prevent callbacks after player is released
We currently implicitly rely on the internal playback thread to not send
new updates after the player got released. This may not always be ensured
since we let the release call timeout. For the timeout case, there may
still be a pending operation returning much later when it unstuck itself.

Fix this and potential other edge cases by explicitly removing all listeners
and preventing new listeners from being added after the release.

PiperOrigin-RevId: 338217220
2020-10-21 10:24:24 +01:00
insun
6abee66504 Fix bottom area to have even paddings and make seekbar slimmer.
Also removed unused thumb resources.

PiperOrigin-RevId: 338184661
2020-10-21 10:24:14 +01:00
olly
0ad33116b6 Simplify artwork selection in PlayerView
PiperOrigin-RevId: 338056357
2020-10-21 10:24:04 +01:00
Oliver Woodman
f1c3928bc9 Merge pull request #7867 from GeneticGenesis:pc/update-expected-http-statuses-for-failover
PiperOrigin-RevId: 338051017
2020-10-20 14:52:14 +01:00
Oliver Woodman
3abaef5593 Merge pull request #8088 from xufuji456:dev-v2
PiperOrigin-RevId: 338024866
2020-10-20 14:52:01 +01:00
ibaker
7ea1201bc2 Add playback tests for existing MP4 assets
Skip assets with >2 audio channels - this isn't
currently supported by ShadowAudioSystem. I'll add these when support is
available.

Also skip sample_ac4_protected.mp4 because DRM isn't supported in this
test environment either.

PiperOrigin-RevId: 338023738
2020-10-20 14:51:50 +01:00
ibaker
57e884b671 Add support for AC-3, AC-4, E-AC-3 and E-AC-3-JOC to playback tests
I added the TS playback tests for these assets without adding support
for the relevant MIME types to ShadowMediaCodec.

Also remove test assets with more than 2 audio channels - this isn't
currently supported by ShadowAudioSystem. I'll re-add these when support
is available.

PiperOrigin-RevId: 338023290
2020-10-20 14:51:41 +01:00
krocard
f54f763db5 AudioSink: Remove comment about unconfirmed crash
Consensus is that the NoClassDefFoundError does not
causes a crash but only a warning.

PiperOrigin-RevId: 338022354
2020-10-20 14:51:32 +01:00
Oliver Woodman
2f3fdf7c5b Merge pull request #8030 from yqritc:add-output-surface-workaround
PiperOrigin-RevId: 338016707
2020-10-20 14:51:20 +01:00
kimvde
021d725c0a Add motion photo metadata entry
PiperOrigin-RevId: 337863184
2020-10-20 14:51:09 +01:00
andrewlewis
2ada01c1e7 Allow enabling IMA ext debug mode programmatically
PiperOrigin-RevId: 337824945
2020-10-20 14:50:59 +01:00
tonihei
febf5d2031 Use ListenerSet in AnalyticsCollector.
This ensures recursively sent events arrive in the correct order.

Issue: #8048
PiperOrigin-RevId: 337812882
2020-10-20 14:50:50 +01:00
tonihei
3c682610cf Fix calculation of available duration in DefaultDashChunkSource
The available duration used a "live edge" that was calculated in
the previous iteration and was thus quite old. Also it also used
the end of the last available segment, but the actually available
duration for buffering needs to be clamped to the current live edge
for low-latency streams.

Issue: #4904
PiperOrigin-RevId: 337812621
2020-10-20 14:50:40 +01:00
tonihei
68cbf6ddf3 Move listener handling to common util class.
ExoPlayerImpl and CastPlayer repeat the same logic. Moving the listener
and event handling to a common util class allows to reuse the same code
and add unit tests for this logic.

The change is a functional no-op.

PiperOrigin-RevId: 337812358
2020-10-20 14:50:30 +01:00
tonihei
9398f4db03 Fix ABR tests gradle build.
The build needs to remove some duplicate dependencies to work again.

Also replace a deprecated API usage with the non-deprecated equivalent
and merge the two Blaze target into one to simplify Gradle file.

PiperOrigin-RevId: 337812099
2020-10-20 14:50:20 +01:00
xufuji456
af4028f30e Fix MOV with pcm_alaw/pcm_mulaw which is fixedSampleSize 2020-10-19 20:49:29 +08:00
aquilescanta
a3a5760757 Remove references to the default Cast receiver
The ExoPlayer receiver app id is a thin wrapper around the default receiver, so
there are no reasons for users not to depend on it. By having ExoPlayer users
refer to the ExoPlayer app id we can collect usage metrics.

PiperOrigin-RevId: 337516767
2020-10-17 01:35:29 +01:00
krocard
e589d7238a Add a getter for sleeping for offload
This allows wakelock releases to be state based
instead of transition based.

#exo-offload

PiperOrigin-RevId: 337286501
2020-10-17 01:35:20 +01:00
ibaker
d97dd8d5eb Add playback tests for existing FLAC assets
PiperOrigin-RevId: 337280116
2020-10-17 01:35:11 +01:00
ibaker
74ac915124 Add playback tests for existing MP3 assets
PiperOrigin-RevId: 337279583
2020-10-17 01:35:01 +01:00
andrewlewis
35f7e7f609 Upgrade IMA SDK dependency to 3.20.1
This brings in a fix for companion ads rendering when targeting API 29.

Issue: #6432
PiperOrigin-RevId: 337279054
2020-10-17 01:34:52 +01:00
krocard
230f4e5bb5 Do not inherit directly from AudioTrack.StreamEventCallback
This was causing issues old devices where the class
inheriting StreamEventCallback was loaded even though
it was not used.

Instead use an anonymous class that seem to be loaded
more lazily.

PiperOrigin-RevId: 337252687
2020-10-17 01:34:43 +01:00
krocard
bb851c99b9 Add MiTV devices requiring the output surface workaround
Issue: #8014
PiperOrigin-RevId: 337142176
2020-10-17 01:34:33 +01:00
bachinger
75513e581f Use Math.round(double) to avoid result being limited to Integer.MAX_INT
Issue: #8067
PiperOrigin-RevId: 337122011
2020-10-17 01:34:24 +01:00
ibaker
2371b024dd Switch to an 'api' dependency on Guava
The 'implementation' dependency causes problems when resolving
ListenableFuture in contexts that also include the
com.google.guava:listenablefuture:1.0 dependency.

Issue: #7905
Issue: #7997
Issue: #7993
PiperOrigin-RevId: 337093024
2020-10-17 01:34:15 +01:00
andrewlewis
eccc00bca8 Add a way to override ad media MIME types
Issue: #7961
PiperOrigin-RevId: 337069152
2020-10-17 01:34:06 +01:00
andrewlewis
cfe267a568 Encapsulate ImaAdsLoader configuration in a class
This will reduce the amount of boilerplate required to pass the configuration
values around (especially in a planned future change when logic is factored out
of ImaAdsLoader).

PiperOrigin-RevId: 337058355
2020-10-17 01:33:56 +01:00