465 Commits

Author SHA1 Message Date
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
ac782235ca Fix miscellaneous nits/typos
PiperOrigin-RevId: 335642909
2020-10-06 16:57:31 +00:00
andrewlewis
39277ebe95 Pass ad tags via AdsMediaSource
This is in preparation for supporting playlists of ads media sources using
ImaAdsLoader.

Existing ways of passing ad tags should still function but are deprecated (and
won't be supported with playlists).

Issue: #3750
PiperOrigin-RevId: 335618364
2020-10-06 14:31:50 +01:00
Oliver Woodman
19a0258bac Merge pull request #7798 from yoobi:trackSelectionView
PiperOrigin-RevId: 333751261
2020-09-25 17:49:12 +01:00
ibaker
d3639a2b20 Add Japanese subtitle examples to the demo app
These are from https://medium.com/google-exoplayer/improved-japanese-subtitle-support-7598fee12cf4

PiperOrigin-RevId: 333296789
2020-09-25 16:31:11 +01:00
christosts
7b5b8b2d79 Fix bug in offline DRM downloads
PiperOrigin-RevId: 331955966
2020-09-16 13:34:16 +01:00
olly
bff7ac0dbe Clean up some lint warnings
PiperOrigin-RevId: 331162350
2020-09-11 17:31:03 +01:00
olly
cdcb30ed21 Exclude Guava transitive annotation dependencies
PiperOrigin-RevId: 331148067
2020-09-11 16:01:15 +01:00
olly
b2b08ade99 Make User-Agent optional
PiperOrigin-RevId: 330593247
2020-09-09 09:41:51 +01:00
olly
04f67e4adc Simplify DefaultMediaSourceFactory ad configuration
- Use a setter, which is consistent with how other optional
  components are passed.
- Remove nesting where a provider provides another provider.
  Since AdSupportProvider then only provides one thing, it
  can be renamed to AdsLoaderProvider, which more clearly
  expresses what it provides.

PiperOrigin-RevId: 330396334
2020-09-07 20:43:41 +01:00
olly
fe2fc8b73f Add useful DownloadRequest to MediaItem conversion method
PiperOrigin-RevId: 329722775
2020-09-07 20:42:14 +01:00
insun
3ab9bc8e7f Fix internal demo app crash
Internal demo app crashed when device does not support required DRM scheme.
This CL fixes it.

PiperOrigin-RevId: 329653841
2020-09-07 20:40:41 +01:00
olly
440fd1cf62 Some minor tweaks
1. Add EventLogger right away in PlayerActivity, else it doesn't log
   playWhenReady being initially set to true.
2. Remove EventLogger logging for the audio position advancing. It's
   redundant with isPlaying logging unless you're very specifically
   interested in the timing difference.
3. Remove unnecessary comment in Player.
4. Fix Timeline Javadoc.

PiperOrigin-RevId: 328983944
2020-09-07 20:39:36 +01:00
christosts
603dcf4978 Download offline DRM license from non-UI thread
PiperOrigin-RevId: 328904901
2020-09-07 20:38:48 +01:00
Yo Ob
869981a360
Merge branch 'dev-v2' into trackSelectionView 2020-08-28 11:36:59 +02:00
Yoni Obadia
181676d950 dev: adding sorting for TrackSelectionDialog and TrackSelectionDialogBuilder 2020-08-24 15:13:21 +02:00
olly
7588c26b60 Remove support for cbc1 and cens encryptions schemes
PiperOrigin-RevId: 327199833
2020-08-21 12:48:39 +01:00
aquilescanta
fcb263a407 Make DrmSessionManager take a Format instead of DrmInitData
Skipping acquirePlaceholderSession which will be removed
in a following change.

PiperOrigin-RevId: 326402746
2020-08-17 16:11:17 +01:00
olly
6f7524521b Demo app: Update concatenation terminology to use "playlist"
PiperOrigin-RevId: 326401528
2020-08-17 16:11:08 +01:00
olly
5220c70c5e Demo app: Rename drm_license_url to drm_license_uri
It's quite hard to document drm_force_default_license_uri when the
actual license URI uses "url" terminology. This brings the two in
line.

PiperOrigin-RevId: 326283162
2020-08-17 16:10:22 +01:00
olly
a7b1b56064 Demo app: Remove is_live from exolist.json
It's not used in the public exolist.json file. It's only use is to
disable the download icon for live content, but it's quite easy to
forget (there are live samples in our internal exolist.json files
that omit this property!).

It's better just to show a clear error message toast when the
download actually fails for this reason.

PiperOrigin-RevId: 326281649
2020-08-17 16:10:13 +01:00
olly
a8a32d6bec Demo app: Minor simplifications
- Simplify the ability to use placeholder DRM sessions to a boolean
- Remove unused IS_LIVE entry in the intent

PiperOrigin-RevId: 326280149
2020-08-17 16:10:03 +01:00
andrewlewis
a7a364d567 Remove unused local intent
PiperOrigin-RevId: 326216921
2020-08-17 16:09:28 +01:00
olly
361e5d9326 Demo app: Fix DRM support check for ClearKey
Issue: Issue: #7735
PiperOrigin-RevId: 325900705
2020-08-17 16:08:15 +01:00
olly
805cfb0259 Revert spurious sample update
PiperOrigin-RevId: 325419476
2020-08-07 19:04:28 +01:00
christosts
a5e6e3054d Offline DRM in main demo app
PiperOrigin-RevId: 325413035
2020-08-07 19:04:09 +01:00
olly
b9612bc338 Fix codec initialization data for Opus in MP4
PiperOrigin-RevId: 325327466
2020-08-07 19:03:40 +01:00
olly
be88143fcd Remove deprecated parts of demo app IntentUtil
PiperOrigin-RevId: 324604419
2020-08-07 18:59:11 +01:00
christosts
33fe3a47e3 Remove references to Downloads from IntentUtil
PiperOrigin-RevId: 324599130
2020-08-07 18:59:01 +01:00
christosts
abfe7a2314 Support clip start/end points in demo app
Demo app supports clip start/end points and demonstrates manual
ad insertions.

PiperOrigin-RevId: 324574358
2020-08-07 18:58:41 +01:00
ibaker
132cff1e47 Add an example of tx3g subtitles in an MP4 container
Issue: #7677
PiperOrigin-RevId: 324180797
2020-08-01 12:56:48 +01:00
christosts
6054bda028 Statically import assertions
PiperOrigin-RevId: 323769467
2020-08-01 12:55:27 +01:00
olly
4b3463ab45 Simplify internal demo app
- Enable cleartext by default for the internal demo app
- Remove "external" variant of the internal demo app

PiperOrigin-RevId: 322987978
2020-07-27 23:58:49 +01:00
aquilescanta
0f346c8c2f Fix withDecoderExtensions flavor detection in internal demo app
PiperOrigin-RevId: 322781213
2020-07-24 10:47:58 +01:00
olly
d77ce9eda0 Remove deprecated calls to external APIs
PiperOrigin-RevId: 322346067
2020-07-24 10:43:44 +01:00
claincly
73df8e4a26 Removes spherical stereo play back mode
- Removed corresponding playback examples in the resouce JSON files.
- Removed the spherical style declaration.
- Removed spherical stereo mode related Intent settings, and
- Removed code to play back media in spherical stereo mode

BUG=160460714
(grafted from 595fe17a480d5bc64d0198130150d8e8a5daa679)
PiperOrigin-RevId: 322206314
2020-07-24 10:42:03 +01:00
claincly
811921e618 Removes random ABR support in demo app
- Removed random ABR option from popup menu
- Remvoed intent parameter regarding random abr, default to
   AdaptiveTrackSelection. Removed logic for getting track selection
   mode from an intent
- Remvoed string definition regarding random ABR

PiperOrigin-RevId: 322167816
2020-07-24 10:41:45 +01:00
andrewlewis
9594aa45ff Move functionality from DemoApplication to DemoUtil
https://developer.android.com/reference/android/app/Application recommends
against subclassing application.

PiperOrigin-RevId: 322163812
2020-07-24 10:41:27 +01:00
olly
0cd15d9158 Proactively check listener arguments are non-null
PiperOrigin-RevId: 322143359
2020-07-24 10:40:24 +01:00
claincly
72728ba054 Remove Media Tunneling support in demo app
- Removed Tunneling option from popup menu
- Removed intent parameter regarding tunneling
- Removed string definition regarding tunneling

PiperOrigin-RevId: 322123578
2020-07-24 10:39:48 +01:00
andrewlewis
7fce04a67f Depend on the IMA extension in noExtensions variant
Also use the cronet extension in the demo app.

PiperOrigin-RevId: 322108530
2020-07-24 10:39:03 +01:00
andrewlewis
a8b64f9530 Remove extra MediaItem in demo app
PiperOrigin-RevId: 322094331
2020-07-24 10:38:53 +01:00
tonihei
3b26c218e1 Deduplicate clear playlist code for stop(true) calls.
The logic to clear the playlist is currently duplicated in various
reset methods so that calls to player.stop(true) can clear the playlist.

This can be deduplicated by clearing the playlist as a seperate
operation that reuses the existing code.

PiperOrigin-RevId: 321578759
2020-07-24 10:37:50 +01:00
insun
79c14cb801 Renamed PlayerActivity2 to InternalPlayerActivity and refactored
- Rename PlayerActivity2 to InternalPlayerActivity.
- Reduced code duplications.

PiperOrigin-RevId: 321515231
2020-07-24 10:36:56 +01:00
insun
aa67685071 Apply StyledPlayerView into default demo app
PiperOrigin-RevId: 321280295
2020-07-24 10:35:06 +01:00
ibaker
2f19b63ca0 Add package-info files to packages that only exist in tests
This doesn't affect the nullness checker or Kotlin, but it does make
weird warnings appear in Android Studio. It seems mildly preferable to
have the same spurious warnings in these files that we have in other
tests, rather than different spurious warnings.

PiperOrigin-RevId: 321173760
2020-07-24 10:34:12 +01:00
ibaker
e9a8335381 Migrate callers to pass MediaItem to createMediaSource()
createMediaSource(Uri) is deprecated.

PiperOrigin-RevId: 321121383
2020-07-24 10:31:22 +01:00
olly
21e56f571d Misc analysis fixes
PiperOrigin-RevId: 320921457
2020-07-13 14:04:29 +01:00
aquilescanta
968a0baa8d Fix handling of intents with no license server URI
PiperOrigin-RevId: 319497156
2020-07-03 15:31:20 +01:00
olly
5be6eaa88c Make GL demo easier to understand
PiperOrigin-RevId: 319007693
2020-07-03 09:00:28 +01:00