121 Commits

Author SHA1 Message Date
olly
ef0bfa487f Remove previously deprecated DefaultHttpDataSourceFactory
NO_EXTERNAL

PiperOrigin-RevId: 391054962
2021-08-17 15:42:49 +01:00
kimvde
01613a2e55 Remove usages of deprecated SimpleExoPlayer.Builder
PiperOrigin-RevId: 390130681
2021-08-11 17:34:19 +01:00
olly
dea52048cb Bump dependency versions
PiperOrigin-RevId: 382277352
2021-06-30 13:53:01 +01:00
olly
7aaba1ffe5 Migrate usage of Player.EventListener to Player.Listener
PiperOrigin-RevId: 381837274
2021-06-30 13:43:51 +01:00
olly
d68dba6e34 Use relative naming for demo app components
PiperOrigin-RevId: 379506322
2021-06-15 18:46:45 +01:00
olly
6d3e9fc251 Include MediaSource deps in all demo apps
This is mainly so that developers can try out RTSP with
the main demo app without having to change the build.gradle
file.

The change also aligns what media can be played across the
different demo apps.

#minor-release

PiperOrigin-RevId: 373591974
2021-05-13 17:26:08 +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
bachinger
4c1a294b2e Format Java source files
PiperOrigin-RevId: 372127633
2021-05-06 13:32:25 +01:00
samrobinson
3f3d1fb5f2 Change String MediaMetadata.title to CharSequence trackTitle.
PiperOrigin-RevId: 370439509
2021-04-26 18:29:01 +01:00
aquilescanta
1c40c75433 Use a debug signature config for demo apps' release variant
PiperOrigin-RevId: 359724874
2021-03-02 17:02:55 +00:00
bachinger
36cbcb30b6 Set explicit export attributes in all demo apps
Starting with Android 12 all components of an app that have an intent filter need to have an explicit attribute android:export that is set to either true or false. If a component filters for the MAIN or a VIEW action it needs the attribute explicitly set to true. Prior to Android 12 these were exported implicitly.

See https://medium.com/androiddevelopers/lets-be-explicit-about-our-intent-filters-c5dbe2dbdce0

PiperOrigin-RevId: 358368785
2021-02-22 10:34:58 +00:00
andrewlewis
456622a275 Deprecate stop(boolean)
`stop(true)` is almost the same as `clearMediaItems(); stop();`, except that
any player error isn't cleared. Clearing media items more clearly expresses the
intent.

PiperOrigin-RevId: 350516748
2021-01-07 10:45:02 +00:00
olly
bff7ac0dbe Clean up some lint warnings
PiperOrigin-RevId: 331162350
2020-09-11 17:31:03 +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
olly
21e56f571d Misc analysis fixes
PiperOrigin-RevId: 320921457
2020-07-13 14:04:29 +01:00
andrewlewis
eddc2b0b33 Enable multidex for demos
This is necessary now we have Guava in debug (no-minified) apps.

Also switch to AndroidX multidex to remove the support library dependency.
Temporarily we need to add an Application class, as internal jetification
doesn't seem to handle declaring MultiDexApplication in AndroidManifest.xml.

issue:#7421
PiperOrigin-RevId: 313145023
2020-05-27 18:59:43 +01:00
olly
f38a1015ae Adding instructions on how to build and run ExoPlayer demo apps
Issue:#7338
PiperOrigin-RevId: 312470913
2020-05-21 17:08:53 +01:00
bachinger
b22783f895 Rename sourceUri to uri
PiperOrigin-RevId: 308918151
2020-05-01 19:46:04 +01:00
olly
2e51182f53 Update misc dependencies
PiperOrigin-RevId: 305503804
2020-04-08 21:49:03 +01:00
olly
376d02ac3f Upgrade cast dependency
Issue: #7191
PiperOrigin-RevId: 305502293
2020-04-08 21:48:45 +01:00
bachinger
777d99da8a simplify PlayerManager
PiperOrigin-RevId: 303170259
2020-03-27 23:31:29 +00:00
bachinger
d0fc83ed8a Playlist API: move media item based API to Player
This moves the playlist API methods to the Player interface. Implementation is moved from ExoPlayerImpl to BasePlayer where possible.

Further the CastPlayer is changed to implement the Player interface. Proper migration of the Playermanager to not use the ConcatenatingMediaSource anymore follows in a separate, future CL.

PiperOrigin-RevId: 302937779
2020-03-27 23:30:46 +00:00
bachinger
510f5edd1d Remove cast media item
PiperOrigin-RevId: 301224632
2020-03-19 00:48:22 +00:00
olly
7e6a1418e3 Demo apps: Annotate @NonNull where necessary
Because we now annotate not-null by default in ExoPlayer
library modules, we're seeing warnings in the demo apps where
we override a method and don't explicitly specify an equivalent
@NotNull annotation.

It's probably confusing to use not-null by default for the
demo apps, so this change uses @NonNull where necessary to fix
the warnings.

PiperOrigin-RevId: 296000044
2020-02-25 21:21:54 +00:00
bachinger
4bb6036cf6 add playback state changed listener
This change deprecates Player.onPlayerStateChanged(boolean pwr, int state). It removes deprecation for trivial cases. I'll remove other deprecated usages (mostly in ui module) in follow-up CLs to not bloat this CL.

PiperOrigin-RevId: 292917872
2020-02-11 17:07:03 +00:00
olly
d12c7235f9 Bump targetSdkVersion to 29 for demo apps only
PiperOrigin-RevId: 283324612
2019-12-04 09:58:47 +00:00
olly
0a27d7b482 Don't use DRM prior to API level 18
PiperOrigin-RevId: 278660557
2019-11-15 05:11:26 +00:00
andrewlewis
a3d1ab6900 Add explicit dependency on appcompat for demo app
The demo app was using this via its dependency on the material library,
but it's preferable to list dependencies explicitly (otherwise the build
would break if we removed the material dependency).

PiperOrigin-RevId: 277316175
2019-10-30 08:51:50 +00:00
aquilescanta
9f78187678 Migrate Cast demo app to use DefaultDrmSessionManager.Builder
PiperOrigin-RevId: 272444896
2019-10-02 21:30:00 +01:00
olly
a564c8011f Remove seemingly unused dependency
PiperOrigin-RevId: 266802447
2019-09-05 10:45:16 +01:00
olly
a02237de20 Fix imports
PiperOrigin-RevId: 266676413
2019-09-01 22:03:52 +01:00
tonihei
cd4571161a Add builders for SimpleExoPlayer and ExoPlayer.
The current ExoPlayerFactory is growing too big and usage becomes increasingly
complicated because it's not possible to set individual components without
specifying many other defaults.

Adding new builder classes makes building easier and more future-proof.

PiperOrigin-RevId: 263339078
2019-08-15 14:41:51 +01:00
olly
90ab05c574 Add DRM samples to Cast demo app
PiperOrigin-RevId: 261312509
2019-08-02 17:15:08 +01:00
aquilescanta
79b86de619 Use per-media source DRM in the Cast demo app
PiperOrigin-RevId: 261125341
2019-08-01 20:39:14 +01:00
aquilescanta
46855884f5 Fix samples' text in Cast demo app
PiperOrigin-RevId: 260553467
2019-07-29 21:29:04 +01:00
olly
961adb7e36 Cast: Add MediaItemConverter
For now this just moves some code from the demo app to the extension.
Eventually the goal would be to have CastPlayer playlist methods take
MediaItem, have CastPlayer convert them internally to MediaQueueItem
for sending to the Cast SDK, and also allow reverse conversion so we
can reconstruct MediaItems from the Cast SDK's queue.

PiperOrigin-RevId: 260548020
2019-07-29 21:28:45 +01:00
olly
d77d661e52 Default viewport constraints to match primary display
PiperOrigin-RevId: 260479923
2019-07-29 21:27:46 +01:00
olly
596be3b71b Cast: Simplify MediaItem/Sample to a single MediaItem class
PiperOrigin-RevId: 260021990
2019-07-26 16:34:20 +01:00
olly
223cc5f179 Cast extension: Remove unused parts of MediaItem
PiperOrigin-RevId: 259586520
2019-07-23 23:18:08 +01:00
olly
2c318d7b84 Cast: Remove obsolete flavor dimension
PiperOrigin-RevId: 259582498
2019-07-23 23:17:50 +01:00
bachinger
49a2e5a5cb add manifest to Timeline.Window
- Remove manifest argument from callbacks of Player.EventListener and
  SourceInfoRefreshListener. Instead make it accessible through
  Player.getCurrentManifest() and Timeline.Window.manifest.
- Fix all MediaSource implementation to include the manifest in the
  Timeline instead of passing it to the SourceInfoRefreshListener.
- Refactor ExoPlayerTestRunner, FakeTimeline, FakeMediaSource to
  reflect these changes and make tests pass.

PiperOrigin-RevId: 257359662
2019-07-14 16:20:45 +01:00
olly
7798c07f64 Remove ExoCast
PiperOrigin-RevId: 255964199
2019-07-02 17:48:22 +01:00
aquilescanta
0ddd3c2bd0 Implement DecryptableSampleQueueReader.isReady
PiperOrigin-RevId: 254746146
2019-07-02 17:43:00 +01:00
aquilescanta
3490bea339 Simplify re-creation of the CastPlayer queue in the Cast demo app
PiperOrigin-RevId: 251617354
2019-06-06 17:35:44 +01:00
aquilescanta
3314391932 Add basic DRM support to CastPlayer's demo app
PiperOrigin-RevId: 249624829
2019-05-30 15:09:52 +01:00
tonihei
0bb32a8f09 Add IntDef for Player states.
PiperOrigin-RevId: 245925254
2019-04-30 22:07:47 +01:00
aquilescanta
be61715517 Fix Cast demo app
Broken in 399aa706a7

PiperOrigin-RevId: 242112068
2019-04-05 21:14:28 +01:00
olly
399aa706a7 Remove usages of the widget package and migrate to new packages.
PiperOrigin-RevId: 241656157
2019-04-05 20:54:09 +01:00
olly
07702cecdd Allow exoplayer/v2/ mockito2
PiperOrigin-RevId: 238625384
2019-03-20 23:26:10 +00:00
olly
0622afe170 Migrate to androidx
Issue: #5489
PiperOrigin-RevId: 234507428

Add missing annotation dependency

Issue: #5489
PiperOrigin-RevId: 234566177
2019-02-19 13:22:54 +00:00