103 Commits

Author SHA1 Message Date
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
andrewlewis
f3bd93394b Fix copybara stripping
PiperOrigin-RevId: 234496529
2019-02-18 18:45:55 +00:00
aquilescanta
73d9b2d21a Hide ExoCastPlayer components again
This CL is effectively a rollback of cr/233072247.

PiperOrigin-RevId: 233793032
2019-02-18 17:40:48 +00:00
aquilescanta
5c2aa4bd9e Automated g4 rollback of changelist 233073011.
*** Reason for rollback ***

Pending discussions about cast

*** Original change description ***

Remove default-receiver-related classes from Cast demo app

***

PiperOrigin-RevId: 233790699
2019-02-18 17:40:48 +00:00
aquilescanta
cc153cfca3 Use floating action button in the cast demo app
PiperOrigin-RevId: 233723028
2019-02-18 17:40:48 +00:00
olly
c7788c18db Fix / cleanup some layout in the Cast demo
PiperOrigin-RevId: 233587404
2019-02-18 15:59:22 +00:00
aquilescanta
00c31265cd Move depended below dependant as per usual
PiperOrigin-RevId: 233578341
2019-02-18 15:59:02 +00:00
aquilescanta
55e6d1d708 Prevent concurrent queue modifications from breaking the cast demo app UI
PiperOrigin-RevId: 233577854
2019-02-18 15:58:57 +00:00
olly
a21572f0dd Fix minor issues and lint errors
PiperOrigin-RevId: 233428556
2019-02-18 15:58:37 +00:00
olly
8401097ead Upgrade gradle plugin and friends
PiperOrigin-RevId: 233390513
2019-02-18 15:57:55 +00:00
aquilescanta
905927554a Fix Cast demo app's blaze build and enable proguarding
PiperOrigin-RevId: 233372668
2019-02-18 15:57:49 +00:00
aquilescanta
fc2710498a Handle player errors more gracefully in the Cast demo app
PiperOrigin-RevId: 233090773
2019-02-18 15:57:39 +00:00
aquilescanta
3d822bd228 Rename ExoCastPlayerManager to PlayerManager
PiperOrigin-RevId: 233089799
2019-02-18 15:57:34 +00:00
aquilescanta
a263fb1631 Remove default-receiver-related classes from Cast demo app
PiperOrigin-RevId: 233073011
2019-02-18 15:57:24 +00:00
aquilescanta
6f1daff3f1 Remove copybara scrubbing of ExoCast components
PiperOrigin-RevId: 233072247
2019-02-18 15:57:19 +00:00
aquilescanta
c61c0bd1ac Cast demo: Fix a few miscellaneous bugs
PiperOrigin-RevId: 231801562
2019-02-04 19:38:49 +00:00
olly
45433869e5 Rename ExtractorMediaSource to ProgressiveMediaSource
It better describes what the class does. More importantly, we've had
inconsistent class names since we added offline support, for which we
added ProgressiveDownloader ("ExtractorDownloader" doesn't make any
sense). We could really do with aligning the names for clarity.

(Sorry)

PiperOrigin-RevId: 231387268
2019-01-29 16:45:42 +00:00
olly
355b3d6334 Increase minSdkVersion to 16
The combination of pre-16 API levels accounting for ~0.5% of the device
population, and that the most important components in ExoPlayer (e.g.
the MediaCodec renderers) have always required API level 16, mean it's
very unlikely this will negatively impact on anyone.

PiperOrigin-RevId: 230701808
2019-01-29 16:41:45 +00:00
aquilescanta
fd081d49c7 Make the Cast demo app absorb remote queue changes
Necessary in two scenarios:
+ When the demo app starts casting to a receiver app that already
  had a queue.
+ When two demo apps are connected to the same receiver app and
  both make modifications.

PiperOrigin-RevId: 230546851
2019-01-29 16:41:02 +00:00